{
  "openapi": "3.1.0",
  "info": {
    "title": "ProofRevenueNode Public API",
    "version": "0.1.0-public-static",
    "description": "Protected proof-audit API for agent marketplace packaging. Paid public API buyers should use the RapidAPI hub at https://rapidapi.com/sethfoou/api/proofrevenuenode at 0.25 USD per request; chat buyers can use the published Poe bot at https://poe.com/ProofRevenueNode. Current proof-audit requests do not make OpenAI calls. If an OpenAI-backed route is enabled, buyers must supply their own OpenAI key unless the seller price is at least 3x the estimated OpenAI call cost. Direct server auth is private server-side fallback only. No revenue is claimed without a settled external payment receipt."
  },
  "servers": [
    {
      "url": "https://sethfoo1.gamginc.com"
    }
  ],
  "paths": {
    "/public/proofrevenue-node/health.json": {
      "get": {
        "operationId": "proofRevenueNodeStaticHealth",
        "summary": "Read public static readiness metadata.",
        "responses": {
          "200": {
            "description": "Static health payload"
          }
        }
      }
    },
    "/api/proofrevenue-node/tasks/proof-audit": {
      "post": {
        "operationId": "proofRevenueNodeProofAudit",
        "summary": "Score a monetized agent workflow for proof and marketplace readiness.",
        "security": [
          {
            "proofRevenueServerAuth": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "workflow_name",
                  "buyer_agent_intent",
                  "steps"
                ],
                "properties": {
                  "workflow_name": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 160
                  },
                  "buyer_agent_intent": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 700
                  },
                  "seller_agent_role": {
                    "type": "string",
                    "maxLength": 240,
                    "default": "proof and reliability auditor"
                  },
                  "target_network": {
                    "type": "string",
                    "default": "rapidapi_agent_api_marketplace"
                  },
                  "desired_price_usd": {
                    "type": "string",
                    "pattern": "^[0-9]+(\\.[0-9]{1,2})?$",
                    "default": "500.00"
                  },
                  "steps": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 30,
                    "items": {
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Proof audit result"
          },
          "401": {
            "description": "API key required"
          },
          "503": {
            "description": "Route pending service activation"
          }
        }
      }
    },
    "/api/proofrevenue-node/stripe/webhook": {
      "post": {
        "operationId": "proofRevenueNodeStripeWebhook",
        "summary": "Receive signed Stripe checkout events for ProofRevenueNode.",
        "description": "Requires server-only PROOF_REVENUE_NODE_STRIPE_WEBHOOK_SECRET and a valid Stripe-Signature HMAC. Claimable revenue is imported only for the verified $500 ProofRevenueNode Fixed-Scope Audit checkout.",
        "parameters": [
          {
            "name": "Stripe-Signature",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Stripe webhook signature header. The signing secret is never returned by this API."
          }
        ],
        "responses": {
          "200": {
            "description": "Webhook accepted, ignored, or imported after signature verification."
          },
          "400": {
            "description": "Signature, JSON payload, or checkout evidence is invalid."
          },
          "503": {
            "description": "Stripe webhook signing secret is not configured."
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "proofRevenueServerAuth": {
        "type": "http",
        "scheme": "bearer",
        "description": "Private server-side fallback only. Paid public buyers should use the RapidAPI hub, which injects the proxy secret server-to-server."
      }
    }
  }
}

