{"openapi":"3.1.0","info":{"title":"Okwan API","description":"Okwan reads the order ledgers and payment rails of the merchants you serve and tells you, order by\norder, what was **collected twice**, what **doesn't add up** and what was **never paid**. Every route is\nread-only.\n\n## Quickstart\n\n1. **Issue a key.** In the dashboard, open **Agents** or **Settings → API keys**, choose a merchant and issue a\n   key. It starts with `okw_` and is shown once.\n2. **Run the check.** `OKWAN_URL` is this API's address.\n\n   ```bash\n   curl \"$OKWAN_URL/v1/reconciliations/across/rails?outcome=collected_twice\" \\\n     -H \"Authorization: Bearer $OKWAN_KEY\"\n   ```\n\n3. **Read the answer.** `summary` holds the counts and amounts; `data` is a page of orders, worst first.\n\n## Authentication\n\nSend the key as `Authorization: Bearer okw_…` (or `X-Okwan-Key: okw_…`). A key belongs to one merchant, or to\nyour workspace, and reads only what that tenant has connected. Routes under **Merchants & keys** also take a\ndashboard session. Okwan stores a key's hash only; revoke a key by its id.\n\n## One declaration, three surfaces\n\nEach connector is declared once. Its REST routes (below), its SQL tables (`POST /v1/query`) and its MCP tools\n(the hosted server at `/mcp/`, with the same key) all come from that declaration, so every surface reads the\nsame rails the same way.\n\n## Read-only by design\n\nNo route can refund, charge or move money. The only operations that write are `whatsapp.messages.send_template`, `whatsapp.messages.send_text`; they are marked **Writes** below.\n\n## The check\n\n`GET /v1/reconciliations/across/rails` reads the merchant's Shopify orders, then PayPal and Stripe, and gives one\nverdict per order: `collected_twice`, `split_tender`, `collected_inconsistent`, `collected`, `unverifiable`, `uncollected`. Filter with `outcome`; page with `limit` (up to 1,000) and the `cursor`\nfrom the previous page. Every run is saved, and reading saved runs under `/v1/tenants/{id}/runs` is free.\n\n## Requests and plans\n\nA successful call that reads a provider (a connector route, a SQL statement, a check) counts as one request\nagainst your plan. Reading the catalog, saved runs and usage is free. Past the monthly limit, calls answer `402`.\n\n## Errors\n\nErrors are JSON: `{\"detail\": …}`. `401` the key is missing or invalid, or the provider rejected the stored\ncredentials · `402` the plan's limit is reached · `404` unknown, or not yours (never `403`) · `409` a cursor from a\ndifferent result · `422` the request is invalid (your input is never echoed back) · `502` a provider failed. A\nprovider's own error keeps its status code.\n","version":"0.1.0","x-logo":{"altText":"Okwan"}},"paths":{"/v1/connectors":{"get":{"tags":["catalog"],"summary":"List connectors","operationId":"list_connectors_v1_connectors_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ConnectorInfo"},"type":"array","title":"Response List Connectors V1 Connectors Get"}}}}}}},"/v1/paystack/transactions/list":{"post":{"tags":["paystack"],"summary":"List transactions","operationId":"paystack_transactions_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paystack__schemas__ListTransactionsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Transaction_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List transactions, newest first. Sum `amount` where status=success for gross volume; `reference` is the key to match against merchant order records.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paystack/transactions/get":{"post":{"tags":["paystack"],"summary":"Get transaction","operationId":"paystack_transactions_get","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetTransactionIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paystack__schemas__Transaction"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Fetch one transaction by its Paystack numeric ID.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paystack/settlements/list":{"post":{"tags":["paystack"],"summary":"List settlements","operationId":"paystack_settlements_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSettlementsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Settlement_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List settlements (payouts to the merchant bank account). `effective_amount` is net of fees; compare against the sum of the settlement's transactions to detect shortfalls.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paystack/settlement_transactions/list":{"post":{"tags":["paystack"],"summary":"List settlement transactions","operationId":"paystack_settlement_transactions_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSettlementTransactionsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Transaction_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List the transactions that make up one settlement — the payout-to-transaction breakdown used for reconciliation.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paystack/customers/list":{"post":{"tags":["paystack"],"summary":"List customers","operationId":"paystack_customers_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paystack__schemas__ListCustomersIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_core__pagination__CursorPage_Customer___1"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List customers, newest first.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paystack/customers/get":{"post":{"tags":["paystack"],"summary":"Get customer","operationId":"paystack_customers_get","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paystack__schemas__GetCustomerIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paystack__schemas__Customer"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Fetch one customer by customer code or email address.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paystack/balance/get":{"post":{"tags":["paystack"],"summary":"Get balance","operationId":"paystack_balance_get","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetBalanceIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paystack__schemas__Balance"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Current available balance, one entry per currency.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/paypal/transactions/list":{"post":{"tags":["paypal"],"summary":"List transactions","operationId":"paypal_transactions_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_paypal__schemas__ListTransactionsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionPage"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List ledger rows over a date window, oldest window first. Filter `is_payment` to exclude adjustments and transfers. `invoice_id` and `custom_field` carry merchant references and are the join keys for reconciling against an order ledger.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/postgres/tables/list":{"post":{"tags":["postgres"],"summary":"List tables","operationId":"postgres_tables_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTablesIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TableList"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List tables in a schema.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/postgres/tables/get_schema":{"post":{"tags":["postgres"],"summary":"Get table schema","operationId":"postgres_tables_get_schema","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetSchemaIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TableSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Get column names, types, and nullability for a table.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/postgres/rows/search":{"post":{"tags":["postgres"],"summary":"Search rows","operationId":"postgres_rows_search","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchRowsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RowSet"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Read rows from a table with optional column projection and equality filters. Identifiers are validated; values are bind parameters — injection-safe by construction.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/postgres/sql/query":{"post":{"tags":["postgres"],"summary":"Query SQL","operationId":"postgres_sql_query","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_postgres__schemas__QueryIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RowSet"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Run a single read-only SQL statement (SELECT/WITH). Executed inside a READ ONLY transaction: any write is rejected by Postgres itself.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/shopify/orders/list":{"post":{"tags":["shopify"],"summary":"List orders","operationId":"shopify_orders_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListOrdersIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Order_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List orders oldest first. `name` (#1001) is the merchant-facing reference to match against a payment rail. Reconcile on `net_payment_minor`, not `total_received_minor`: a refunded order matched on gross looks like an over-collection.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/shopify/orders/get":{"post":{"tags":["shopify"],"summary":"Get order","operationId":"shopify_orders_get","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetOrderIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Order"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Fetch one order by GID or numeric ID.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/shopify/products/list":{"post":{"tags":["shopify"],"summary":"List products","operationId":"shopify_products_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListProductsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Product_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List products in the store catalog.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/stripe/customers/list":{"post":{"tags":["stripe"],"summary":"List customers","operationId":"stripe_customers_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_stripe__schemas__ListCustomersIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_core__pagination__CursorPage_Customer___2"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List customers, newest first, with cursor pagination.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/stripe/customers/get":{"post":{"tags":["stripe"],"summary":"Get customer","operationId":"stripe_customers_get","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_stripe__schemas__GetCustomerIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_stripe__schemas__Customer"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Fetch one customer by ID.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/stripe/charges/list":{"post":{"tags":["stripe"],"summary":"List charges","operationId":"stripe_charges_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListChargesIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Charge_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List charges, newest first. Filter by customer to compute per-customer revenue; sum `amount` where status=succeeded and refunded=false.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/stripe/subscriptions/list":{"post":{"tags":["stripe"],"summary":"List subscriptions","operationId":"stripe_subscriptions_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListSubscriptionsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CursorPage_Subscription_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List subscriptions; status=all includes canceled.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/stripe/balance/get":{"post":{"tags":["stripe"],"summary":"Get balance","operationId":"stripe_balance_get","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetBalanceIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_stripe__schemas__Balance"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"Current account balance: available and pending funds.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/whatsapp/messages/send_text":{"post":{"tags":["whatsapp"],"summary":"Send text message","operationId":"whatsapp_messages_send_text","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendTextIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Message"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"**Writes.** This operation sends data to the provider.\n\nSend a plain text WhatsApp message to one recipient.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}],"x-okwan-writes":true}},"/v1/whatsapp/messages/send_template":{"post":{"tags":["whatsapp"],"summary":"Send template message","operationId":"whatsapp_messages_send_template","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendTemplateIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Message"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"**Writes.** This operation sends data to the provider.\n\nSend a pre-approved template message. Required for business-initiated conversations outside the 24-hour customer window.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}],"x-okwan-writes":true}},"/v1/whatsapp/templates/list":{"post":{"tags":["whatsapp"],"summary":"List templates","operationId":"whatsapp_templates_list","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTemplatesIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateList"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"description":"List message templates for a WhatsApp Business Account.","security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/reconciliations":{"get":{"tags":["reconciliations"],"summary":"List checks","operationId":"list_reconciliations_v1_reconciliations_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Reconciliations V1 Reconciliations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/reconciliations/across/{name}":{"get":{"tags":["reconciliations"],"summary":"Run the check","operationId":"read_across_v1_reconciliations_across__name__get","parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}},{"name":"outcome","in":"query","required":false,"schema":{"type":"string","pattern":"^(all|collected_twice|split_tender|collected_inconsistent|collected|unverifiable|uncollected)$","default":"all","title":"Outcome"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Read Across V1 Reconciliations Across  Name  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/reconciliations/{name}":{"get":{"tags":["reconciliations"],"summary":"Run a two-sided reconciliation","operationId":"read_reconciliation_v1_reconciliations__name__get","parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","pattern":"^(all|matched|matched_explained|matched_discrepant|unmatched_left|unmatched_right|ambiguous|unverifiable_left|unverifiable_right)$","default":"all","title":"Status"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Read Reconciliation V1 Reconciliations  Name  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/query/tables":{"get":{"tags":["query"],"summary":"List SQL tables","operationId":"list_tables_v1_query_tables_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Tables V1 Query Tables Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/query":{"post":{"tags":["query"],"summary":"Run a SQL query","operationId":"run_query_v1_query_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/okwan_query__rest__QueryIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Run Query V1 Query Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants":{"get":{"tags":["tenants"],"summary":"List merchants","description":"The caller's own record and the tenants it has provisioned.","operationId":"list_tenants_v1_tenants_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Tenants V1 Tenants Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]},"post":{"tags":["tenants"],"summary":"Add a merchant","description":"Provision a tenant beneath the caller.","operationId":"create_tenant_v1_tenants_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTenantIn"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Create Tenant V1 Tenants Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/keys":{"post":{"tags":["tenants"],"summary":"Issue a key","description":"Issue an API key for a tenant in the caller's subtree.\n\nThe secret is returned exactly once; only its hash is stored.","operationId":"issue_key_v1_tenants__tenant_id__keys_post","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Issue Key V1 Tenants  Tenant Id  Keys Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/keys/{key_id}":{"delete":{"tags":["tenants"],"summary":"Revoke a key","description":"Revoke a key. Effective immediately on the next request.","operationId":"revoke_key_v1_tenants_keys__key_id__delete","parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/credentials":{"put":{"tags":["tenants"],"summary":"Save credentials","description":"Store an upstream credential for a tenant in the caller's subtree.\n\nValidated against the connector's declared fields, so a typo fails\nhere rather than surfacing later as an unexplained auth error.","operationId":"put_credential_v1_tenants__tenant_id__credentials_put","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CredentialIn"}}}},"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]},"get":{"tags":["tenants"],"summary":"List stored credential fields","description":"Which connectors are configured. Names only — never values.","operationId":"list_credentials_v1_tenants__tenant_id__credentials_get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Credentials V1 Tenants  Tenant Id  Credentials Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/usage":{"get":{"tags":["tenants"],"summary":"Read usage","description":"Where a tenant's requests went: the plan it is held to, the month\nso far, and the counters behind that total for the window.\n\nThe plan and the month's total belong to the paying account, so a\nmerchant sees the allowance it shares (the 402 it would get already\nsays as much). The buckets are the target's own subtree only: a\nmerchant never sees a sibling's traffic. Not metered: reading the\nmeter must not move it.\n\n`days` is calendar days ending today, UTC, so a 7-day window is\nseven dates and a chart of seven columns, not 168 hours ending\nnow. `granularity=day` sums each day's hours into one bucket per\ntenant and surface, which is all a chart needs and bounds the\nresponse for a long window over many merchants.","operationId":"usage_v1_tenants__tenant_id__usage_get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":92,"minimum":1,"default":30,"title":"Days"}},{"name":"granularity","in":"query","required":false,"schema":{"type":"string","pattern":"^(hour|day)$","default":"hour","title":"Granularity"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Usage V1 Tenants  Tenant Id  Usage Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/connectors/{connector_name}/test":{"post":{"tags":["tenants"],"summary":"Test a connection","description":"Prove the stored credentials work: one real list call, limit=1.\n\nReads from the vault, not the request, so a pass also proves the\nwrite landed and the round trip opens. The result says whether\nrows came back and never carries a credential, even inside an\nupstream error message.","operationId":"test_connector_v1_tenants__tenant_id__connectors__connector_name__test_post","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"connector_name","in":"path","required":true,"schema":{"type":"string","title":"Connector Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Test Connector V1 Tenants  Tenant Id  Connectors  Connector Name  Test Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/runs/latest":{"get":{"tags":["tenants"],"summary":"Latest saved checks","description":"The newest stored run per tenant, for the target and its direct\nchildren, with rows: what Overview and Findings read instead of\nrunning anything. Not metered.","operationId":"latest_runs_v1_tenants__tenant_id__runs_latest_get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"kind","in":"query","required":false,"schema":{"type":"string","pattern":"^(across|pair)$","default":"across","title":"Kind"}},{"name":"name","in":"query","required":false,"schema":{"type":"string","default":"rails","title":"Name"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Latest Runs V1 Tenants  Tenant Id  Runs Latest Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/runs":{"get":{"tags":["tenants"],"summary":"List saved checks","description":"Run history, newest first, without rows. Not metered.","operationId":"list_runs_v1_tenants__tenant_id__runs_get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"name","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":20,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response List Runs V1 Tenants  Tenant Id  Runs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/runs/{run_id}":{"get":{"tags":["tenants"],"summary":"Read a saved check","description":"One stored run with its rows. A run outside the subtree, like a\ntenant outside it, does not exist. Not metered.","operationId":"get_run_v1_tenants__tenant_id__runs__run_id__get","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"run_id","in":"path","required":true,"schema":{"type":"string","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Get Run V1 Tenants  Tenant Id  Runs  Run Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/reconciliations/across/{name}":{"post":{"tags":["tenants"],"summary":"Run the check for a merchant","description":"Run an across-rails fold as a tenant in the caller's subtree.\n\nSame result and errors as `GET /v1/reconciliations/across/{name}`\nwith that tenant's key. POST because it runs, and is metered.","operationId":"reconcile_across_as_v1_tenants__tenant_id__reconciliations_across__name__post","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}},{"name":"outcome","in":"query","required":false,"schema":{"type":"string","pattern":"^(all|collected_twice|split_tender|collected_inconsistent|collected|unverifiable|uncollected)$","default":"all","title":"Outcome"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Reconcile Across As V1 Tenants  Tenant Id  Reconciliations Across  Name  Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/tenants/{tenant_id}/reconciliations/{name}":{"post":{"tags":["tenants"],"summary":"Run a reconciliation for a merchant","description":"Run a two-sided reconciliation as a tenant in the caller's\nsubtree. Same result and errors as `GET /v1/reconciliations/{name}`.","operationId":"reconcile_as_v1_tenants__tenant_id__reconciliations__name__post","parameters":[{"name":"tenant_id","in":"path","required":true,"schema":{"type":"string","title":"Tenant Id"}},{"name":"name","in":"path","required":true,"schema":{"type":"string","title":"Name"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"default":100,"title":"Limit"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","pattern":"^(all|matched|matched_explained|matched_discrepant|unmatched_left|unmatched_right|ambiguous|unverifiable_left|unverifiable_right)$","default":"all","title":"Status"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Reconcile As V1 Tenants  Tenant Id  Reconciliations  Name  Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/v1/signup":{"post":{"tags":["accounts"],"summary":"Sign up","description":"Start a signup. The account exists only once the email is verified.","operationId":"signup_v1_signup_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignupIn"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Signup V1 Signup Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/signup/verify":{"post":{"tags":["accounts"],"summary":"Verify an email address","description":"Create the root tenant and open a session.\n\nThe password must be the one this signup was made with, so a link\nfrom a signup someone else started for this address does not\nproduce an account they can sign into.","operationId":"verify_v1_signup_verify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyIn"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Verify V1 Signup Verify Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sessions":{"post":{"tags":["accounts"],"summary":"Sign in","operationId":"sign_in_v1_sessions_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionIn"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Sign In V1 Sessions Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/sessions/current":{"delete":{"tags":["accounts"],"summary":"Sign out","operationId":"sign_out_v1_sessions_current_delete","responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"OkwanKey":[]},{"OkwanKeyHeader":[]}]}},"/healthz":{"get":{"tags":["system"],"summary":"Health","description":"Liveness plus vault reachability.\n\nReturns 503 when the credential store cannot be reached, so an\ninstance that cannot serve any authenticated request is replaced\nrather than left answering 401 to everything.","operationId":"healthz_healthz_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Healthz Healthz Get"}}}}}}}},"components":{"schemas":{"Charge":{"properties":{"id":{"type":"string","title":"Id"},"amount":{"type":"integer","title":"Amount","description":"Amount in minor units"},"currency":{"type":"string","title":"Currency"},"status":{"type":"string","title":"Status","description":"succeeded, pending, or failed"},"customer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer","description":"Customer ID"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"created":{"type":"integer","title":"Created"},"refunded":{"type":"boolean","title":"Refunded","default":false},"amount_refunded":{"type":"integer","title":"Amount Refunded","description":"Amount refunded in minor units","default":0},"order_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Order Ref","description":"Merchant order reference from charge metadata. The join key for reconciling against an order ledger; Shopify Payments writes the order name here."},"fee_minor":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fee Minor","description":"Stripe's fee in minor units, positive as Stripe reports it. Lives on the balance transaction, not the charge, so the list operation expands it."},"amount_major":{"type":"number","title":"Amount Major","description":"Amount in major units, subunit-correct for zero-decimal currencies.","readOnly":true},"net_minor":{"type":"integer","title":"Net Minor","description":"What the merchant receives: amount less refunds less Stripe's fee.\nStripe reports the fee positive, so this subtracts where PayPal adds.","readOnly":true},"net_major":{"type":"number","title":"Net Major","readOnly":true}},"type":"object","required":["id","amount","currency","status","created","amount_major","net_minor","net_major"],"title":"Charge"},"Column":{"properties":{"name":{"type":"string","title":"Name"},"data_type":{"type":"string","title":"Data Type"},"is_nullable":{"type":"boolean","title":"Is Nullable"},"default":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default"}},"type":"object","required":["name","data_type","is_nullable"],"title":"Column"},"ConnectorInfo":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"},"description":{"type":"string","title":"Description"},"resources":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Resources"},"credential_fields":{"items":{"type":"string"},"type":"array","title":"Credential Fields"},"probe":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Probe"},"sql_tables":{"items":{"type":"string"},"type":"array","title":"Sql Tables"},"writes":{"items":{"type":"string"},"type":"array","title":"Writes"}},"type":"object","required":["name","version","description","resources","credential_fields","probe","sql_tables","writes"],"title":"ConnectorInfo"},"CreateTenantIn":{"properties":{"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name","description":"Merchant or workspace name"}},"type":"object","required":["name"],"title":"CreateTenantIn"},"CredentialIn":{"properties":{"connector":{"type":"string","title":"Connector","description":"Connector name, e.g. 'stripe'"},"field":{"type":"string","title":"Field","description":"Credential field, e.g. 'secret_key'"},"value":{"type":"string","minLength":1,"title":"Value","description":"Written to the vault, never returned"}},"type":"object","required":["connector","field","value"],"title":"CredentialIn"},"CursorPage_Charge_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Charge"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Charge]"},"CursorPage_Order_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Order"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Order]"},"CursorPage_Product_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Product"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Product]"},"CursorPage_Settlement_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Settlement"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Settlement]"},"CursorPage_Subscription_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Subscription"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Subscription]"},"CursorPage_Transaction_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/okwan_paystack__schemas__Transaction"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Transaction]"},"GetBalanceIn":{"properties":{},"type":"object","title":"GetBalanceIn","description":"Balance requires no parameters."},"GetOrderIn":{"properties":{"order_id":{"type":"string","title":"Order Id","description":"Shopify order GID (gid://shopify/Order/123) or bare numeric ID"}},"type":"object","required":["order_id"],"title":"GetOrderIn"},"GetSchemaIn":{"properties":{"table":{"type":"string","title":"Table","description":"Table name"},"schema":{"type":"string","title":"Schema","default":"public"}},"type":"object","required":["table"],"title":"GetSchemaIn"},"GetTransactionIn":{"properties":{"transaction_id":{"type":"integer","title":"Transaction Id","description":"Paystack numeric transaction ID"}},"type":"object","required":["transaction_id"],"title":"GetTransactionIn"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ListChargesIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"customer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id","description":"Only charges for this customer"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Only charges with this status: succeeded, pending or failed. Stripe's list takes no status filter, so this is applied to each page after fetching; a page may hold fewer than `limit` items."}},"type":"object","title":"ListChargesIn"},"ListOrdersIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"financial_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Financial Status","description":"Filter by payment state: paid, partially_refunded, refunded, pending"},"created_at_min":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At Min","description":"Only orders created at or after this time"}},"type":"object","title":"ListOrdersIn"},"ListProductsIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"}},"type":"object","title":"ListProductsIn"},"ListSettlementTransactionsIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"settlement_id":{"type":"integer","title":"Settlement Id","description":"Settlement whose constituent transactions to list"}},"type":"object","required":["settlement_id"],"title":"ListSettlementTransactionsIn"},"ListSettlementsIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Filter: pending, processing, success, failed"}},"type":"object","title":"ListSettlementsIn"},"ListSubscriptionsIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"status":{"type":"string","title":"Status","description":"Filter: active, canceled, trialing, past_due, all...","default":"all"}},"type":"object","title":"ListSubscriptionsIn"},"ListTablesIn":{"properties":{"schema":{"type":"string","title":"Schema","description":"Schema to list tables from","default":"public"}},"type":"object","title":"ListTablesIn"},"ListTemplatesIn":{"properties":{"waba_id":{"type":"string","title":"Waba Id","description":"WhatsApp Business Account ID"},"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","default":25}},"type":"object","required":["waba_id"],"title":"ListTemplatesIn"},"Message":{"properties":{"message_id":{"type":"string","title":"Message Id","description":"WhatsApp message ID (wamid)"},"to":{"type":"string","title":"To","description":"Recipient phone number in E.164 format"},"status":{"type":"string","title":"Status","description":"Send status","default":"accepted"}},"type":"object","required":["message_id","to"],"title":"Message","description":"One outbound message acknowledgment from the Cloud API."},"Order":{"properties":{"id":{"type":"string","title":"Id","description":"Shopify GID, e.g. gid://shopify/Order/123"},"name":{"type":"string","title":"Name","description":"Merchant-facing order number (#1001); the reconciliation join key"},"currency":{"type":"string","title":"Currency"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"financial_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Financial Status","description":"PAID, PARTIALLY_REFUNDED, REFUNDED, PENDING..."},"fulfillment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fulfillment Status","description":"Shipping state. Independent of payment — an unfulfilled order can be fully reconciled, and a fulfilled one can be unpaid."},"total_price_minor":{"type":"integer","title":"Total Price Minor","description":"Current order value in minor units, after any edits"},"total_received_minor":{"type":"integer","title":"Total Received Minor","description":"Gross amount collected, before refunds"},"total_refunded_minor":{"type":"integer","title":"Total Refunded Minor","description":"Refunded, minor units","default":0},"net_payment_minor":{"type":"integer","title":"Net Payment Minor","description":"Received less refunded — what the merchant actually kept.\n\nThe default figure to reconcile against: it is what a rail's\nsettlement will eventually reflect. Matching gross instead makes\na legitimately refunded order look like an over-collection.","readOnly":true},"net_payment_major":{"type":"number","title":"Net Payment Major","readOnly":true},"total_price_major":{"type":"number","title":"Total Price Major","readOnly":true},"is_reconcilable":{"type":"boolean","title":"Is Reconcilable","description":"False when nothing was collected — nothing for a rail to match.","readOnly":true}},"type":"object","required":["id","name","currency","total_price_minor","total_received_minor","net_payment_minor","net_payment_major","total_price_major","is_reconcilable"],"title":"Order"},"Product":{"properties":{"id":{"type":"string","title":"Id"},"title":{"type":"string","title":"Title"},"handle":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Handle"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"ACTIVE, ARCHIVED, DRAFT"},"total_inventory":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Inventory"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["id","title"],"title":"Product"},"RowSet":{"properties":{"columns":{"items":{"type":"string"},"type":"array","title":"Columns"},"rows":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Rows"},"row_count":{"type":"integer","title":"Row Count"}},"type":"object","required":["columns","rows","row_count"],"title":"RowSet"},"SearchRowsIn":{"properties":{"table":{"type":"string","title":"Table","description":"Table to read from"},"schema":{"type":"string","title":"Schema","default":"public"},"columns":{"items":{"type":"string"},"type":"array","title":"Columns","description":"Columns to return; empty = all"},"equals":{"additionalProperties":true,"type":"object","title":"Equals","description":"Equality filters, e.g. {\"country\": \"GH\"}"},"limit":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Limit","default":100},"offset":{"type":"integer","minimum":0.0,"title":"Offset","default":0}},"type":"object","required":["table"],"title":"SearchRowsIn"},"SendTemplateIn":{"properties":{"phone_number_id":{"type":"string","title":"Phone Number Id","description":"Sender phone number ID from Meta"},"to":{"type":"string","title":"To","description":"Recipient phone number in E.164 format"},"template_name":{"type":"string","title":"Template Name","description":"Approved template name"},"language_code":{"type":"string","title":"Language Code","description":"Template language, e.g. en_US","default":"en_US"},"body_parameters":{"items":{"$ref":"#/components/schemas/TemplateParameter"},"type":"array","title":"Body Parameters","description":"Ordered values for template body placeholders"}},"type":"object","required":["phone_number_id","to","template_name"],"title":"SendTemplateIn"},"SendTextIn":{"properties":{"phone_number_id":{"type":"string","title":"Phone Number Id","description":"Sender phone number ID from Meta"},"to":{"type":"string","title":"To","description":"Recipient phone number in E.164 format, e.g. +14155551234"},"body":{"type":"string","maxLength":4096,"title":"Body","description":"Message text"},"preview_url":{"type":"boolean","title":"Preview Url","description":"Render URL previews","default":false}},"type":"object","required":["phone_number_id","to","body"],"title":"SendTextIn"},"SessionIn":{"properties":{"email":{"type":"string","maxLength":254,"title":"Email"},"password":{"type":"string","maxLength":256,"minLength":1,"title":"Password"}},"type":"object","required":["email","password"],"title":"SessionIn"},"Settlement":{"properties":{"id":{"type":"integer","title":"Id"},"status":{"type":"string","title":"Status","description":"pending, processing, success, failed"},"currency":{"type":"string","title":"Currency"},"total_amount":{"type":"integer","title":"Total Amount","description":"Gross settled amount, minor units"},"effective_amount":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Effective Amount","description":"Net of fees and deductions, minor units"},"total_fees":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Fees"},"total_processed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Processed"},"settlement_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Settlement Date"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"total_amount_major":{"type":"number","title":"Total Amount Major","readOnly":true}},"type":"object","required":["id","status","currency","total_amount","total_amount_major"],"title":"Settlement"},"SignupIn":{"properties":{"email":{"type":"string","maxLength":254,"pattern":"^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$","title":"Email"},"password":{"type":"string","maxLength":256,"minLength":12,"title":"Password"}},"type":"object","required":["email","password"],"title":"SignupIn"},"Subscription":{"properties":{"id":{"type":"string","title":"Id"},"customer":{"type":"string","title":"Customer"},"status":{"type":"string","title":"Status","description":"active, trialing, past_due, canceled, unpaid..."},"current_period_end":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Current Period End"},"cancel_at_period_end":{"type":"boolean","title":"Cancel At Period End","default":false}},"type":"object","required":["id","customer","status"],"title":"Subscription"},"Table":{"properties":{"schema":{"type":"string","title":"Schema","description":"Postgres schema, e.g. public"},"name":{"type":"string","title":"Name"}},"type":"object","required":["schema","name"],"title":"Table"},"TableList":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Table"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"TableList"},"TableSchema":{"properties":{"schema":{"type":"string","title":"Schema"},"name":{"type":"string","title":"Name"},"columns":{"items":{"$ref":"#/components/schemas/Column"},"type":"array","title":"Columns"}},"type":"object","required":["schema","name","columns"],"title":"TableSchema"},"Template":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"status":{"type":"string","title":"Status","description":"APPROVED, PENDING, or REJECTED"},"category":{"type":"string","title":"Category","description":"MARKETING, UTILITY, or AUTHENTICATION"},"language":{"type":"string","title":"Language"}},"type":"object","required":["id","name","status","category","language"],"title":"Template","description":"A pre-approved message template."},"TemplateList":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Template"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},"type":"object","required":["items"],"title":"TemplateList"},"TemplateParameter":{"properties":{"type":{"type":"string","title":"Type","description":"Parameter type: text, currency, date_time","default":"text"},"text":{"type":"string","title":"Text","description":"Substitution value for {{n}} placeholders"}},"type":"object","required":["text"],"title":"TemplateParameter"},"TransactionCustomer":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id"},"customer_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Code"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Customer MSISDN as supplied to Paystack"}},"type":"object","title":"TransactionCustomer"},"TransactionPage":{"properties":{"items":{"items":{"$ref":"#/components/schemas/okwan_paypal__schemas__Transaction"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"TransactionPage"},"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"},"VerifyIn":{"properties":{"token":{"type":"string","maxLength":200,"minLength":1,"title":"Token"},"password":{"type":"string","maxLength":256,"minLength":1,"title":"Password"}},"type":"object","required":["token","password"],"title":"VerifyIn"},"okwan_core__pagination__CursorPage_Customer___1":{"properties":{"items":{"items":{"$ref":"#/components/schemas/okwan_paystack__schemas__Customer"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Customer]"},"okwan_core__pagination__CursorPage_Customer___2":{"properties":{"items":{"items":{"$ref":"#/components/schemas/okwan_stripe__schemas__Customer"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Pass as `cursor` to fetch the next page"},"has_more":{"type":"boolean","title":"Has More","default":false},"span_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span Start","description":"Earliest instant this walk reads from"},"span_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Span End","description":"Latest instant this walk reads to"},"horizon":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Horizon","description":"How current the upstream ledger says it is. Records after this have not landed yet; span_end is clamped to it"}},"type":"object","required":["items"],"title":"CursorPage[Customer]"},"okwan_paypal__schemas__ListTransactionsIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"start_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date","description":"Window start, UTC. Defaults to 30 days ago."},"end_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date","description":"Window end, UTC. Clamped to PayPal's last_refreshed_datetime, which lags real time by up to three hours."},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Filter by transaction status: S, P, V or D"}},"type":"object","title":"ListTransactionsIn","description":"Window is required upstream and capped at 31 days; omitting it\ndefaults to the last 30 days ending at PayPal's last refresh."},"okwan_paypal__schemas__Transaction":{"properties":{"transaction_id":{"type":"string","title":"Transaction Id","description":"PayPal transaction id. Not unique across balance-affecting and non-balance-affecting rows; list operations request balance-affecting rows only so this reads as a key."},"event_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Code","description":"Five-digit PayPal transaction event code"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"S success, P pending, V reversed, D denied"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"},"amount_minor":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Amount Minor","description":"Gross amount in minor units; negative for outflows"},"fee_minor":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fee Minor","description":"PayPal fee in minor units, negative as PayPal reports it"},"initiated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Initiated At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Id","description":"Merchant invoice id; a join key for reconciliation"},"custom_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Field","description":"Merchant-supplied passthrough; the other reconciliation join key"},"reference_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Id","description":"Id of a related pre-existing transaction"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"payer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payer Email"},"payer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payer Name"},"amount_major":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Amount Major","readOnly":true},"net_minor":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Net Minor","description":"Amount after PayPal's fee. The figure a payout settles to.","readOnly":true},"net_major":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Net Major","readOnly":true},"is_payment":{"type":"boolean","title":"Is Payment","description":"True for customer payment movement, false for adjustments and\ntransfers. Sandbox seed funding is T1900 and would otherwise read\nas an unmatched break forever.","readOnly":true}},"type":"object","required":["transaction_id","amount_major","net_minor","net_major","is_payment"],"title":"Transaction","description":"One row of the PayPal transaction ledger."},"okwan_paystack__schemas__Balance":{"properties":{"balances":{"items":{"$ref":"#/components/schemas/okwan_paystack__schemas__BalanceEntry"},"type":"array","title":"Balances","description":"Available balance per currency"}},"type":"object","required":["balances"],"title":"Balance"},"okwan_paystack__schemas__BalanceEntry":{"properties":{"currency":{"type":"string","title":"Currency"},"balance":{"type":"integer","title":"Balance","description":"Balance in minor units"},"balance_major":{"type":"number","title":"Balance Major","readOnly":true}},"type":"object","required":["currency","balance","balance_major"],"title":"BalanceEntry"},"okwan_paystack__schemas__Customer":{"properties":{"id":{"type":"integer","title":"Id"},"customer_code":{"type":"string","title":"Customer Code"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"risk_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Risk Action"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["id","customer_code"],"title":"Customer"},"okwan_paystack__schemas__GetCustomerIn":{"properties":{"customer_code":{"type":"string","title":"Customer Code","description":"Customer code (CUS_...) or email address"}},"type":"object","required":["customer_code"],"title":"GetCustomerIn"},"okwan_paystack__schemas__ListCustomersIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"}},"type":"object","title":"ListCustomersIn"},"okwan_paystack__schemas__ListTransactionsIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Filter: success, failed, abandoned"},"customer_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Customer Id","description":"Only transactions for this Paystack customer ID"}},"type":"object","title":"ListTransactionsIn"},"okwan_paystack__schemas__Transaction":{"properties":{"id":{"type":"integer","title":"Id"},"reference":{"type":"string","title":"Reference","description":"Merchant-supplied reference; the join key for reconciliation"},"amount":{"type":"integer","title":"Amount","description":"Amount in minor units"},"currency":{"type":"string","title":"Currency"},"status":{"type":"string","title":"Status","description":"success, failed, abandoned, reversed..."},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel","description":"card, bank, mobile_money..."},"gateway_response":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gateway Response"},"fees":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fees","description":"Paystack fees in minor units"},"paid_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paid At"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"customer":{"anyOf":[{"$ref":"#/components/schemas/TransactionCustomer"},{"type":"null"}]},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"},{"type":"string"},{"type":"null"}],"title":"Metadata"},"amount_major":{"type":"number","title":"Amount Major","description":"Amount in major units, subunit-correct for zero-decimal currencies.","readOnly":true}},"type":"object","required":["id","reference","amount","currency","status","amount_major"],"title":"Transaction"},"okwan_postgres__schemas__QueryIn":{"properties":{"sql":{"type":"string","title":"Sql","description":"A single read-only SQL statement (SELECT or WITH). Writes are rejected by a read-only transaction."},"limit":{"type":"integer","maximum":5000.0,"minimum":1.0,"title":"Limit","description":"Row cap on results","default":500}},"type":"object","required":["sql"],"title":"QueryIn"},"okwan_query__rest__QueryIn":{"properties":{"sql":{"type":"string","title":"Sql","description":"Read-only SQL over connector.resource tables"},"limit":{"type":"integer","maximum":5000.0,"minimum":1.0,"title":"Limit","default":500}},"type":"object","required":["sql"],"title":"QueryIn"},"okwan_stripe__schemas__Balance":{"properties":{"available":{"items":{"$ref":"#/components/schemas/okwan_stripe__schemas__BalanceEntry"},"type":"array","title":"Available","description":"Available funds per currency"},"pending":{"items":{"$ref":"#/components/schemas/okwan_stripe__schemas__BalanceEntry"},"type":"array","title":"Pending","description":"Pending funds per currency"}},"type":"object","required":["available","pending"],"title":"Balance"},"okwan_stripe__schemas__BalanceEntry":{"properties":{"currency":{"type":"string","title":"Currency"},"amount":{"type":"integer","title":"Amount","description":"Amount in minor units"},"amount_major":{"type":"number","title":"Amount Major","readOnly":true}},"type":"object","required":["currency","amount","amount_major"],"title":"BalanceEntry"},"okwan_stripe__schemas__Customer":{"properties":{"id":{"type":"string","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"created":{"type":"integer","title":"Created","description":"Unix timestamp"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"},"delinquent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Delinquent"}},"type":"object","required":["id","created"],"title":"Customer"},"okwan_stripe__schemas__GetCustomerIn":{"properties":{"customer_id":{"type":"string","title":"Customer Id","description":"Stripe customer ID (cus_...)"}},"type":"object","required":["customer_id"],"title":"GetCustomerIn"},"okwan_stripe__schemas__ListCustomersIn":{"properties":{"limit":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Limit","description":"Page size","default":25},"cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor","description":"Opaque cursor from a previous page's `next_cursor`"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Filter by exact email"}},"type":"object","title":"ListCustomersIn"}},"securitySchemes":{"OkwanKey":{"type":"http","scheme":"bearer","bearerFormat":"okw_…","description":"An Okwan API key, issued in the dashboard (Agents or Settings → API keys)."},"OkwanKeyHeader":{"type":"apiKey","in":"header","name":"X-Okwan-Key","description":"The same key in its own header, for clients that can't set Authorization."}}},"tags":[{"name":"reconciliations","x-displayName":"The check","description":"Run the check over a merchant's orders and payments. Each run is one request and is saved as verdicts and amounts, never raw payment records."},{"name":"shopify","x-displayName":"Shopify","description":"Shopify: read orders and products from a merchant store via the GraphQL Admin API. Orders expose gross, refunded and net amounts separately in integer minor units — net payment is the figure to reconcile a payment rail against."},{"name":"paypal","x-displayName":"PayPal","description":"PayPal: read the transaction ledger via Transaction Search. Amounts are integer minor units converted from PayPal's decimal strings; `net_minor` is gross less PayPal's fee, which is the figure a payout settles to. `is_payment` separates customer payments from account adjustments and transfers."},{"name":"stripe","x-displayName":"Stripe","description":"Stripe: read customers, charges, subscriptions, and account balance. Amounts are minor units (cents)."},{"name":"paystack","x-displayName":"Paystack","description":"Paystack: read transactions, settlements, settlement transactions, customers and balances across NGN, GHS, ZAR, KES, USD and XOF. Amounts are minor units; each amount also exposes an `*_major` field that is subunit-correct for zero-decimal currencies such as XOF."},{"name":"postgres","x-displayName":"PostgreSQL / Neon","description":"PostgreSQL / Neon: introspect schemas, read rows with filters, run read-only SQL. Works with any Postgres DSN."},{"name":"whatsapp","x-displayName":"WhatsApp Cloud API","description":"WhatsApp Cloud API: send text and template messages, manage message templates."},{"name":"query","x-displayName":"SQL","description":"Read-only SQL over the tables the connectors generate. One request per statement."},{"name":"tenants","x-displayName":"Merchants & keys","description":"Your merchants, their keys, connections, usage and saved checks. Takes a key or a dashboard session. Reading is free."},{"name":"accounts","x-displayName":"Accounts","description":"Sign-up, email verification and dashboard sessions."},{"name":"catalog","x-displayName":"Catalog","description":"Every connector and what its one declaration generates. Public."},{"name":"system","x-displayName":"System","description":"Health of this API and its vault. Public."}],"x-tagGroups":[{"name":"Start here","tags":["reconciliations"]},{"name":"Connectors","tags":["shopify","paypal","stripe","paystack","postgres","whatsapp"]},{"name":"SQL","tags":["query"]},{"name":"Your workspace","tags":["tenants","accounts"]},{"name":"Reference","tags":["catalog","system"]}]}