{
  "openapi": "3.1.0",
  "info": {
    "title": "NodPulse public API",
    "version": "1.0.0",
    "description": "Public actions an agent can take for NodPulse. Pricing lookup is a live static file (/pricing.json). Lead submit and checkout route through the account flow at nodpulse.com/app; per-SKU Stripe Checkout is created there."
  },
  "servers": [
    {
      "url": "https://enterprise.nodpulse.com"
    }
  ],
  "paths": {
    "/pricing.json": {
      "get": {
        "operationId": "getPricing",
        "summary": "Pricing lookup for every SKU (live static file)",
        "responses": {
          "200": {
            "description": "Pricing for every SKU",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/api/lead": {
      "post": {
        "operationId": "createLead",
        "summary": "Submit a contact/lead",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "email": {
                    "type": "string",
                    "format": "email"
                  },
                  "subject": {
                    "type": "string"
                  },
                  "message": {
                    "type": "string"
                  }
                },
                "required": [
                  "email",
                  "message"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Lead accepted; returns a ticket id",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ticket_id": {
                      "type": "string"
                    },
                    "status": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/checkout": {
      "post": {
        "operationId": "createCheckout",
        "summary": "Create a Stripe Checkout link for a SKU (via the account at nodpulse.com/app)",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sku": {
                    "type": "string"
                  }
                },
                "required": [
                  "sku"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "A checkout URL for the SKU",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "checkout_url": {
                      "type": "string",
                      "format": "uri"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}
