{"openapi":"3.1.0","info":{"title":"NexusLink Console · API","version":"1.0.0","description":"Auto-generated docs for the **NexusLink Console** tenant on Webomata.\n\n### Authenticating\nMost endpoints need an API key, sent as a bearer token:\n\n```\nAuthorization: Bearer wpa_<env>_<token>\n```\n\nPublic endpoints (no lock icon) need no key. A signed-in browser session cookie also works.\n\n### API keys\n- **Who can create them:** any signed-in user — via the Console, or `POST /api/plugins/auth-api-keys/keys`.\n- **Scopes:** each key holds a list of scopes (e.g. `read`, `write`, `admin`). An operation that says *“Requires scopes: …”* needs a key holding **all** of them, else `403 insufficient_scope`. New keys default to `[\"read\"]`.\n- **Expiry:** set per key (this tenant may default to never-expire). The token is shown **once** at creation — store it.\n- Manage keys under the **Webomata · api-keys** group below.\n\n### Endpoint groups\n- **Webomata · …** — platform-provided plumbing (auth sign-in, API keys, billing). Shared across tenants.\n- Everything else — this tenant's own API."},"servers":[{"url":"https://nexuslink.dev","description":"Tenant host"}],"paths":{"/api/plugins/auth-api-keys/keys":{"post":{"summary":"Create a new API key","tags":["Webomata · api-keys"],"responses":{"201":{"description":"Created (token shown once)"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-api-keys"},"get":{"summary":"List API keys (prefixes only)","tags":["Webomata · api-keys"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-api-keys"}},"/api/plugins/auth-api-keys/keys/:id":{"delete":{"summary":"Hard-delete an API key (also revokes by definition)","tags":["Webomata · api-keys"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-api-keys"},"patch":{"summary":"Update an API key (name and/or expiration)","tags":["Webomata · api-keys"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-api-keys"}},"/api/plugins/auth-api-keys/keys/:id/revoke":{"post":{"summary":"Soft-revoke an API key (keeps the row but renders the key invalid)","tags":["Webomata · api-keys"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-api-keys"}},"/api/plugins/auth-flow-magic-link/request":{"post":{"summary":"Request a magic sign-in link by email","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-magic-link"}},"/api/plugins/auth-flow-magic-link/verify":{"get":{"summary":"Redeem a magic-link token","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-magic-link"}},"/api/plugins/auth-flow-oauth/start/:provider":{"get":{"summary":"Begin OAuth authorization redirect","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-oauth"}},"/api/plugins/auth-flow-oauth/callback/:provider":{"get":{"summary":"OAuth provider callback","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-oauth"}},"/api/plugins/auth-flow-siwe/nonce":{"post":{"summary":"Issue a SIWE nonce","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-siwe"}},"/api/plugins/auth-flow-siwe/verify":{"post":{"summary":"Verify a SIWE message + signature","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-siwe"}},"/api/plugins/auth-flow-ssh/nonce":{"post":{"summary":"Issue an SSH-sign nonce","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-ssh"}},"/api/plugins/auth-flow-ssh/verify":{"post":{"summary":"Verify an SSHSIG signature over a nonce","tags":["Webomata · auth"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"auth-flow-ssh"}},"/api/plugins/auth-users/me":{"get":{"summary":"Get the current authenticated user","tags":["Webomata · auth"],"responses":{"200":{"description":"Current user"},"401":{"description":"Not authenticated"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]},{}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-users"}},"/api/plugins/auth-users/logout":{"post":{"summary":"Invalidate the current session","tags":["Webomata · auth"],"responses":{"204":{"description":"Logged out"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-users"}},"/api/plugins/auth-users/profile":{"post":{"summary":"Update the current user's profile","tags":["Webomata · auth"],"responses":{"200":{"description":"Updated user"},"400":{"description":"Invalid input"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-users"}},"/api/plugins/auth-users/identities/unlink":{"post":{"summary":"Unlink a sign-in identity from the current user","tags":["Webomata · auth"],"responses":{"200":{"description":"Unlinked"},"400":{"description":"Cannot unlink the only remaining identity"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"auth-users"}},"/api/plugins/billing-stripe/checkout":{"post":{"summary":"Create a Stripe Checkout session for a subscription tier","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/portal":{"post":{"summary":"Create a Stripe Billing Portal session (manage / cancel / update card)","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/change-tier":{"post":{"summary":"Change subscription tier [Option A] (proration handled by Stripe)","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/checkout-b":{"post":{"summary":"Create a Stripe Checkout session [Option B] — slot quantity + optional add-ons, one subscription/invoice","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/update-subscription":{"post":{"summary":"Update slot quantity and/or add-ons on an existing Option B subscription","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/cancel":{"post":{"summary":"Cancel subscription at period end","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/resume":{"post":{"summary":"Resume a subscription that was set to cancel at period end","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/billing-details":{"get":{"summary":"Recent invoices + the default card on file for the current user","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/billing-stripe/webhook":{"post":{"summary":"Stripe webhook receiver","tags":["Webomata · billing"],"responses":{"200":{"description":"OK"}},"x-webomata-source":"plugin","x-webomata-plugin":"billing-stripe"}},"/api/plugins/messaging/conversations":{"get":{"summary":"List my conversations","tags":["Webomata · messaging"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"messaging"},"post":{"summary":"Start a conversation with another user","tags":["Webomata · messaging"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"messaging"}},"/api/plugins/messaging/conversations/:id/messages":{"get":{"summary":"List messages in a conversation (cursor-paginated)","tags":["Webomata · messaging"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"messaging"},"post":{"summary":"Send a text message","tags":["Webomata · messaging"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"messaging"}},"/api/plugins/messaging/conversations/:id/read":{"post":{"summary":"Mark conversation as read","tags":["Webomata · messaging"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"messaging"}},"/api/plugins/messaging/conversations/:id/block":{"post":{"summary":"Block or unblock another member","tags":["Webomata · messaging"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"messaging"}},"/api/plugins/webomata-payments/invoices":{"post":{"summary":"Create a payment invoice with a fresh deposit address","tags":["Webomata · payments"],"responses":{"201":{"description":"Invoice created with deposit address + quote"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"webomata-payments"},"get":{"summary":"List invoices","tags":["Webomata · payments"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"webomata-payments"}},"/api/plugins/webomata-payments/invoices/:id":{"get":{"summary":"Get one invoice by id","tags":["Webomata · payments"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"webomata-payments"}},"/api/plugins/webomata-payments/invoices/:id/process":{"post":{"summary":"Advance an invoice through the settlement state machine","tags":["Webomata · payments"],"responses":{"200":{"description":"OK"}},"security":[{"bearerAuth":[]},{"cookieAuth":[]}],"x-webomata-source":"plugin","x-webomata-plugin":"webomata-payments"}},"/tenants":{"post":{"summary":"Provision a new tenant from one of the caller’s subscription slots","responses":{"201":{"description":"Tenant created"},"400":{"description":"Invalid input"},"401":{"description":"Not authenticated"},"402":{"description":"No subscription or no free slot — payment required"}},"tags":["tenant"],"x-webomata-source":"tenant","x-webomata-file":"endpoints/POST/POST/tenants.ts"}},"/ping":{"get":{"summary":"Health probe served from Webomata-Admin","responses":{"200":{"description":"pong"}},"tags":["tenant"],"x-webomata-source":"tenant","x-webomata-file":"endpoints/GET/GET/ping.ts"}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"wpa_<env>_<token>","description":"Tenant API key issued via auth-api-keys. Mint on /tenants/manage."},"cookieAuth":{"type":"apiKey","in":"cookie","name":"webomata_session","description":"Session cookie from a NexusLink sign-in."}}}}