openapi: 3.2.0 info: title: HiveMorph v0.1 Subscription API description: 'Polymorphic agent runtime — single shape (Merchant), single supermodel (W2 MERCHANT). Three gates: NEED + YIELD + CLEAN-MONEY.' version: 0.1.0 tags: - name: Subscription paths: /v1/subscription/plans: get: tags: - Subscription summary: List Plans description: Public plan catalog. Returns price, features, payment rails. operationId: list_plans_v1_subscription_plans_get responses: '200': description: Successful Response content: application/json: schema: {} /v1/subscription/intent: post: tags: - Subscription summary: Create Intent description: 'Step 1: client picks a plan, gets payment instructions + sub_id memo.' operationId: create_intent_v1_subscription_intent_post requestBody: content: application/json: schema: $ref: '#/components/schemas/IntentRequest' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/subscription/claim: post: tags: - Subscription summary: Claim Subscription description: 'Step 2: client submits tx_hash. v0.1 accepts any well-formed hash and provisions immediately. v0.2 will verify on-chain via Base RPC.' operationId: claim_subscription_v1_subscription_claim_post requestBody: content: application/json: schema: $ref: '#/components/schemas/ClaimRequest' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/subscription/status/{sub_id}: get: tags: - Subscription summary: Subscription Status description: Public status check by sub_id (api_key never returned here). operationId: subscription_status_v1_subscription_status__sub_id__get parameters: - name: sub_id in: path required: true schema: type: string title: Sub Id responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/subscription/health: get: tags: - Subscription summary: Health operationId: health_v1_subscription_health_get responses: '200': description: Successful Response content: application/json: schema: {} components: schemas: HTTPValidationError: properties: detail: items: $ref: '#/components/schemas/ValidationError' type: array title: Detail type: object title: HTTPValidationError ValidationError: properties: loc: items: anyOf: - type: string - type: integer type: array title: Location msg: type: string title: Message type: type: string title: Error Type input: title: Input ctx: type: object title: Context type: object required: - loc - msg - type title: ValidationError IntentRequest: properties: plan: type: string title: Plan description: dev-pack or saas-pro email: anyOf: - type: string - type: 'null' title: Email description: for receipt + provisioning notification type: object required: - plan title: IntentRequest ClaimRequest: properties: sub_id: type: string title: Sub Id tx_hash: type: string minLength: 10 title: Tx Hash type: object required: - sub_id - tx_hash title: ClaimRequest