openapi: 3.2.0 info: title: HiveMorph v0.1 R7 Spectral API description: 'Polymorphic agent runtime — single shape (Merchant), single supermodel (W2 MERCHANT). Three gates: NEED + YIELD + CLEAN-MONEY.' version: 0.1.0 tags: - name: r7-spectral paths: /v1/spectral/policy: get: tags: - r7-spectral summary: Spectral Policy operationId: spectral_policy_v1_spectral_policy_get responses: '200': description: Successful Response content: application/json: schema: {} /v1/spectral/stats: get: tags: - r7-spectral summary: Spectral Stats operationId: spectral_stats_v1_spectral_stats_get responses: '200': description: Successful Response content: application/json: schema: {} /v1/spectral/observe: post: tags: - r7-spectral summary: Spectral Observe operationId: spectral_observe_v1_spectral_observe_post requestBody: content: application/json: schema: $ref: '#/components/schemas/ObserveReq' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/spectral/evaluate: post: tags: - r7-spectral summary: Spectral Evaluate operationId: spectral_evaluate_v1_spectral_evaluate_post requestBody: content: application/json: schema: $ref: '#/components/schemas/EvaluateReq' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/spectral/{agent_did}/observations: get: tags: - r7-spectral summary: Spectral Observations operationId: spectral_observations_v1_spectral__agent_did__observations_get parameters: - name: agent_did in: path required: true schema: type: string minLength: 3 maxLength: 200 title: Agent Did - name: limit in: query required: false schema: type: integer maximum: 500 minimum: 1 default: 50 title: Limit responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/spectral/{agent_did}/alerts: get: tags: - r7-spectral summary: Spectral Alerts operationId: spectral_alerts_v1_spectral__agent_did__alerts_get parameters: - name: agent_did in: path required: true schema: type: string minLength: 3 maxLength: 200 title: Agent Did - name: limit in: query required: false schema: type: integer maximum: 500 minimum: 1 default: 50 title: Limit responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/spectral/{agent_did}: get: tags: - r7-spectral summary: Spectral Fingerprint operationId: spectral_fingerprint_v1_spectral__agent_did__get parameters: - name: agent_did in: path required: true schema: type: string minLength: 3 maxLength: 200 title: Agent Did responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' 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 ObserveReq: properties: agent_did: type: string maxLength: 200 minLength: 3 title: Agent Did endpoint: anyOf: - type: string maxLength: 300 - type: 'null' title: Endpoint spend_usd: anyOf: - type: number maximum: 1000000000.0 minimum: 0.0 - type: 'null' title: Spend Usd counterparty_did: anyOf: - type: string maxLength: 200 - type: 'null' title: Counterparty Did size_bytes: anyOf: - type: integer maximum: 1000000000.0 minimum: 0.0 - type: 'null' title: Size Bytes proof_tier: anyOf: - type: string maxLength: 40 - type: 'null' title: Proof Tier jurisdiction: anyOf: - type: string maxLength: 40 - type: 'null' title: Jurisdiction latency_ms: anyOf: - type: number maximum: 600000.0 minimum: 0.0 - type: 'null' title: Latency Ms decision: anyOf: - type: string maxLength: 40 - type: 'null' title: Decision context: additionalProperties: true type: object title: Context type: object required: - agent_did title: ObserveReq EvaluateReq: properties: agent_did: type: string maxLength: 200 minLength: 3 title: Agent Did endpoint: anyOf: - type: string maxLength: 300 - type: 'null' title: Endpoint spend_usd: anyOf: - type: number maximum: 1000000000.0 minimum: 0.0 - type: 'null' title: Spend Usd counterparty_did: anyOf: - type: string maxLength: 200 - type: 'null' title: Counterparty Did size_bytes: anyOf: - type: integer maximum: 1000000000.0 minimum: 0.0 - type: 'null' title: Size Bytes proof_tier: anyOf: - type: string maxLength: 40 - type: 'null' title: Proof Tier jurisdiction: anyOf: - type: string maxLength: 40 - type: 'null' title: Jurisdiction latency_ms: anyOf: - type: number maximum: 600000.0 minimum: 0.0 - type: 'null' title: Latency Ms persist_observation: type: boolean title: Persist Observation default: false decision: anyOf: - type: string maxLength: 40 - type: 'null' title: Decision type: object required: - agent_did title: EvaluateReq