{"openapi":"3.1.0","info":{"title":"CornerStone Agentic Score – Onboarding","description":"Standalone onboarding site: register agent allowlist and get MCP + env snippet (Arnstein Banking Systems)","version":"0.1.0"},"paths":{"/":{"get":{"summary":"Index","description":"Serve landing page.","operationId":"index__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/flow.html":{"get":{"summary":"Flow","description":"Serve onboarding flow page.","operationId":"flow_flow_html_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/config":{"get":{"summary":"Get Config","description":"Return client config. Bank linking is served by this onboarding site (vendored Plaid). Display prices come from env (LENDER_SUBSCRIPTION_AMOUNT_USD, MCP_PRICE_BANKING_USD / BASE_COST_*).","operationId":"get_config_config_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/plaid/link-token":{"get":{"summary":"Plaid Link Token","description":"Bank link token (served by this onboarding site; vendored Plaid). When borrower entitlement is enforced, app_user_id (query) is required and must have the borrower entitlement.","operationId":"plaid_link_token_plaid_link_token_get","parameters":[{"name":"app_user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"App User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/plaid/exchange":{"post":{"summary":"Plaid Exchange","description":"Bank link exchange (served by this onboarding site). Optional wallet for borrower score. When borrower entitlement is enforced, app_user_id (body) is required.","operationId":"plaid_exchange_plaid_exchange_post","requestBody":{"content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Body"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/attest/evm":{"post":{"summary":"Attest Evm","description":"Verify EVM wallet attestation (personal_sign). Body: { address, message, signature [, message_hex ] }.\nUses same implementation as server.services.attestation (single source of truth).","operationId":"attest_evm_attest_evm_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/attest/aptos":{"post":{"summary":"Attest Aptos","description":"Verify Aptos wallet attestation (Ed25519). Body: { address, message, signature [, public_key_hex ] }.\nUses same implementation as server.services.attestation (single source of truth).","operationId":"attest_aptos_attest_aptos_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/register":{"post":{"summary":"Register","description":"Add agent address(es) to allowlist. At least one EVM or Aptos required. Supports multiple per type with optional testnet/mainnet.","operationId":"register_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/lender/register":{"post":{"summary":"Lender Register","description":"Register or update a lender account (RevenueCat app_user_id + one or more paying wallets + optional usage reason). No signature required.","operationId":"lender_register_lender_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LenderRegisterBody"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/allowlist":{"get":{"summary":"Get Allowlist","description":"Return current agent and pay_to allowlists and optional agent_wallets (evm/aptos with network).","operationId":"get_allowlist_allowlist_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/snippet":{"get":{"summary":"Get Snippet","description":"Return env_snippet and MCP snippets (Cursor-compatible) for current allowlist.","operationId":"get_snippet_snippet_get","parameters":[{"name":"mcp_server_url","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mcp Server Url"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/env-export":{"get":{"summary":"Env Export","description":"Return current allowlist as shell export lines for terminal hydration (eval $(curl -s .../env-export)).","operationId":"env_export_env_export_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health":{"get":{"summary":"Health","operationId":"health_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/for-borrowers":{"get":{"summary":"For Borrowers","operationId":"for_borrowers_for_borrowers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/for-lenders":{"get":{"summary":"For Lenders","operationId":"for_lenders_for_lenders_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/how-it-works":{"get":{"summary":"How It Works","operationId":"how_it_works_how_it_works_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/products":{"get":{"summary":"Products","operationId":"products_products_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/compliance":{"get":{"summary":"Compliance","operationId":"compliance_compliance_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/community":{"get":{"summary":"Community","operationId":"community_community_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/contact":{"get":{"summary":"Contact Page","operationId":"contact_page_contact_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/get-sponsored-gas":{"get":{"summary":"Get Sponsored Gas Page","operationId":"get_sponsored_gas_page_get_sponsored_gas_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/about":{"get":{"summary":"About","operationId":"about_about_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/borrower-score":{"get":{"summary":"Borrower Score","operationId":"borrower_score_borrower_score_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/prices":{"get":{"summary":"Prices Page","operationId":"prices_page_prices_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/network-funding":{"get":{"summary":"Network Funding Page","description":"Serve Network funding page (Coming soon wallets + gauge; supported chains only).","operationId":"network_funding_page_network_funding_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/funding":{"get":{"summary":"Funding","description":"Serve Funding page (same content as network-funding).","operationId":"funding_funding_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"AgentWalletEntry":{"properties":{"address":{"type":"string","title":"Address","description":"Wallet address"},"network":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Network","description":"testnet or mainnet; optional"}},"type":"object","required":["address"],"title":"AgentWalletEntry","description":"Single agent wallet with optional network (testnet/mainnet)."},"BankingApplication":{"properties":{"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"}},"type":"object","title":"BankingApplication"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"LenderAttestationEntry":{"properties":{"address":{"type":"string","title":"Address","description":"Wallet address that was attested"},"chain":{"type":"string","title":"Chain","description":"evm or aptos"},"message":{"type":"string","title":"Message","description":"Message that was signed","default":""},"signature":{"type":"string","title":"Signature","description":"Signature hex"},"public_key_hex":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Key Hex","description":"Required for Aptos attestation"}},"type":"object","required":["address","chain","signature"],"title":"LenderAttestationEntry","description":"One attestation proof for server-side verification (EVM or Aptos)."},"LenderRegisterBody":{"properties":{"revenuecat_app_user_id":{"type":"string","title":"Revenuecat App User Id","description":"RevenueCat app user ID from SDK or demo"},"wallet_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wallet Address","description":"Single paying wallet (use wallet_addresses for multiple)"},"wallet_addresses":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Wallet Addresses","description":"Multiple paying wallet addresses (EVM or Aptos)"},"attestations":{"anyOf":[{"items":{"$ref":"#/components/schemas/LenderAttestationEntry"},"type":"array"},{"type":"null"}],"title":"Attestations","description":"Attestation proof per wallet; required when server verifies attestations"},"notes":{"type":"string","title":"Notes","description":"Why, how, and what the credits will be used for (optional)","default":""},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Optional email for support"},"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name","description":"Optional full name"},"tos_accepted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tos Accepted At","description":"ISO timestamp when user accepted ToS/Privacy (for audit)"}},"type":"object","required":["revenuecat_app_user_id"],"title":"LenderRegisterBody","description":"Lender signup: RevenueCat app_user_id + one or more paying wallets + optional usage reason (why/how/what for). Attestation required when server has attestation module."},"RegisterBody":{"properties":{"agent_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Address","description":"EVM wallet address to allow as agent (payer) for link_bank_account"},"aptos_agent_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aptos Agent Address","description":"Aptos wallet address to allow as agent for run_prediction/run_backtest"},"agent_addresses":{"anyOf":[{"items":{"anyOf":[{"type":"string"},{"$ref":"#/components/schemas/AgentWalletEntry"}]},"type":"array"},{"type":"null"}],"title":"Agent Addresses","description":"Multiple EVM addresses; entries may be strings or { address, network? }"},"aptos_agent_addresses":{"anyOf":[{"items":{"anyOf":[{"type":"string"},{"$ref":"#/components/schemas/AgentWalletEntry"}]},"type":"array"},{"type":"null"}],"title":"Aptos Agent Addresses","description":"Multiple Aptos addresses; entries may be strings or { address, network? }"},"banking_application":{"anyOf":[{"$ref":"#/components/schemas/BankingApplication"},{"type":"null"}],"description":"Optional banking application info for submission"},"tos_accepted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tos Accepted At","description":"ISO timestamp when user accepted ToS/Privacy (for audit)"}},"type":"object","title":"RegisterBody"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}