{"openapi": "3.0.3", "info": {"title": "Good-neighbor passport: agent traffic governor", "version": "1.0.0"}, "components": {"securitySchemes": {"BearerAuth": {"type": "http", "scheme": "bearer"}}}, "paths": {"/": {"get": {"summary": "Public product descriptor", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"product": {"type": "string"}}}}}}}}}, "/health": {"get": {"summary": "Health", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"status": {"type": "string"}}}}}}}}}, "/openapi.json": {"get": {"summary": "This spec", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"openapi": {"type": "string"}}}}}}}}}, "/llms.txt": {"get": {"summary": "Product llms.txt", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "string"}}}}}}}, "/.well-known/x402": {"get": {"summary": "x402 payment terms", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"payTo": {"type": "string"}}}}}}}}}, "/package": {"get": {"summary": "Download good_neighbor_passport 1.0.0 wheel", "responses": {"200": {"description": "wheel file"}}}}, "/register": {"post": {"summary": "Create account + claim token (unauthenticated, rate-limited)", "requestBody": {"content": {"application/json": {"schema": {"type": "object", "properties": {"account_name": {"type": "string"}, "payer_wallet": {"type": "string"}}}}}}, "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"account_id": {"type": "string"}, "claim_token": {"type": "string"}}}}}}}}}, "/trial": {"post": {"summary": "Claim one-time Solo trial (once per account AND once per payer wallet)", "requestBody": {"content": {"application/json": {"schema": {"type": "object", "properties": {"account_id": {"type": "string"}, "claim_token": {"type": "string"}}}}}}, "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"token": {"type": "string"}, "tier": {"type": "string"}, "trial": {"type": "boolean"}}}}}}, "403": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}}, "/subscribe": {"post": {"summary": "Subscribe/renew a tier via x402 X-PAYMENT (402 challenge without a verified payment; bogus/replayed payments rejected with a named error)", "parameters": [{"name": "X-PAYMENT", "in": "header", "schema": {"type": "string"}}], "requestBody": {"content": {"application/json": {"schema": {"type": "object", "properties": {"account_id": {"type": "string"}, "tier": {"type": "string"}}}}}}, "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"token": {"type": "string"}, "tier": {"type": "string"}}}}}}, "402": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}, "accepts": {"type": "array"}}}}}}}}}, "/tokens/revoke": {"post": {"security": [{"BearerAuth": []}], "summary": "Revoke the caller's token", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"revoked": {"type": "boolean"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}}, "/operators": {"get": {"security": [{"BearerAuth": []}], "summary": "List this account's registered operators", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"operators": {"type": "array"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}, "post": {"security": [{"BearerAuth": []}], "summary": "Register an operator key + published ceilings for this host property", "requestBody": {"content": {"application/json": {"schema": {"type": "object", "properties": {"operator": {"type": "string"}, "keyid": {"type": "string"}, "public_key_b64": {"type": "string"}, "ceilings": {"type": "object", "properties": {"max_requests": {"type": "integer"}, "window_s": {"type": "integer"}, "max_spend_microusd": {"type": "integer"}}}}}}}}, "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"operator": {"type": "string"}}}}}}, "400": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}}, "/verify": {"post": {"security": [{"BearerAuth": []}], "summary": "Verify a signed passport and meter it: graduated allow/throttle/charge/block", "requestBody": {"content": {"application/json": {"schema": {"type": "object", "properties": {"method": {"type": "string"}, "authority": {"type": "string"}, "path": {"type": "string"}, "headers": {"type": "object", "properties": {}}, "quote": {"type": "object", "properties": {}}, "shape": {"type": "object", "properties": {}}}}}}}, "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"decision": {"type": "string"}, "operator": {"type": "string"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}, "402": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"decision": {"type": "string"}}}}}}, "403": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"decision": {"type": "string"}}}}}}, "429": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"decision": {"type": "string"}}}}}}}}}, "/log": {"get": {"security": [{"BearerAuth": []}], "summary": "This account's hash-chained compliance log segment + retention anchor", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"entries": {"type": "array"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}}, "/log/checkpoint": {"get": {"security": [{"BearerAuth": []}], "summary": "Signed checkpoint over this account's log head", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"head": {"type": "string"}, "seq": {"type": "integer"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}}, "/account": {"get": {"security": [{"BearerAuth": []}], "summary": "Caller's account state (identity from token only)", "responses": {"200": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"account_id": {"type": "string"}, "tier": {"type": "string"}}}}}}, "401": {"description": "ok", "content": {"application/json": {"schema": {"type": "object", "properties": {"error": {"type": "string"}}}}}}}}}}}