{"openapi":"3.1.0","info":{"title":"SesApp Agent API","version":"1.1.0","description":"Create and manage housing access sheets. Agents pay on Base via HTTP 402 (x402): Agent 15 USDC / 20 fiches, Fleet 79 USDC / 200, Platform 250 USDC fair-use. Extra fiches: 0.50 USDC (Agent) or 0.25 (Fleet). After payment, send `Authorization: Bearer`."},"servers":[{"url":"https://sesapp.fr"}],"paths":{"/api/agent/subscribe":{"post":{"summary":"Subscribe or renew (x402)","description":"Without PAYMENT-SIGNATURE returns 402 + PAYMENT-REQUIRED. Query `plan=fleet` or `plan=platform` for higher SKUs. Default: Agent 15 USDC.","parameters":[{"name":"plan","in":"query","schema":{"type":"string","enum":["agent","fleet","platform"],"default":"agent"}}],"responses":{"200":{"description":"JWT and planExpiry"},"402":{"description":"Payment required (x402)"},"503":{"description":"X402_PAY_TO not configured"}}}},"/api/agent/fiches":{"get":{"summary":"List owned fiches","security":[{"bearerAuth":[]}],"responses":{"200":{"description":"List"},"401":{"description":"Auth"},"402":{"description":"Expired plan"}}},"post":{"summary":"Create a fiche","description":"Beyond plan quota, returns 402 for overage (0.50 USDC Agent / 0.25 Fleet). Retry with PAYMENT-SIGNATURE.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name","formattedAddress"],"properties":{"name":{"type":"string"},"formattedAddress":{"type":"string"},"instructions":{"type":"string"},"lat":{"type":"number"},"lon":{"type":"number"},"wifiName":{"type":"string"},"wifiPassword":{"type":"string"},"accessCode":{"type":"string"},"phoneNumber":{"type":"string"}}}}}},"responses":{"200":{"description":"Created"},"402":{"description":"Overage payment required"}}}},"/api/agent/fiches/{id}":{"patch":{"summary":"Update a fiche","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Updated"}}},"delete":{"summary":"Delete a fiche","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Deleted"}}}},"/api/agent/fiches/{id}/share":{"post":{"summary":"Create a revocable guest link","security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Share URL"}}}},"/api/agent/share/{token}":{"delete":{"summary":"Revoke a guest link","security":[{"bearerAuth":[]}],"parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Revoked"}}}},"/mcp":{"post":{"summary":"MCP Streamable HTTP","description":"JSON-RPC tools wrapping the same agent API."}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}}},"x-x402":{"network":"eip155:8453","asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","periodDays":30,"plans":{"agent":{"amount":"15000000","usdc":15,"maxFiches":20,"overageAmount":"500000","path":"/api/agent/subscribe"},"fleet":{"amount":"79000000","usdc":79,"maxFiches":200,"overageAmount":"250000","path":"/api/agent/subscribe?plan=fleet"},"platform":{"amount":"250000000","usdc":250,"maxFiches":"fair-use","overageAmount":null,"path":"/api/agent/subscribe?plan=platform"}}}}