Developer overview
Connect Komashi to your application, website or AI assistant. You can use the integration methods together: for example, embed a subscription widget, receive subscription changes through webhooks, and read usage from the REST API.
Choose an integration
Section titled “Choose an integration”| You want to… | Use | Start here |
|---|---|---|
| Read and manage customers, subscriptions, invoices and usage from your backend | REST API with a provider API key | REST API integration |
| Let an AI assistant work with your connected businesses | MCP with an OAuth 2.1 user connection | MCP integration |
| Add a ready-made service selection or subscription interface to your website | Embeddable widgets | Embed widgets |
| Receive notifications when selected records change | Outgoing webhooks | Webhooks |
| Measure visits and customer journeys | Google Analytics, Microsoft Clarity or PostHog | Analytics & tracking |
Use Komashi documentation through Context7
Section titled “Use Komashi documentation through Context7”Komashi is also available in Context7. If your coding assistant has Context7 connected, add the relevant source to your task so it can retrieve Komashi documentation while helping you build an integration:
- Komashi documentation on Context7 — guides covering setup, integrations and platform features.
- Komashi OpenAPI reference on Context7 — REST API operations and request/response schemas.
For example, give your assistant this instruction:
Use Context7 to read the Komashi documentation and OpenAPI reference:https://context7.com/llmstxt/komashi_llms-full_txthttps://context7.com/openapi/komashi_api-docs_spec
Use these sources to help me integrate Komashi into my application.Check the documented endpoints and required fields before writing code.Context7 supplies documentation context. To read or change your account’s actual data, connect through the REST API or MCP with the appropriate authentication.
Where to configure integrations
Section titled “Where to configure integrations”Open the provider’s Control Center. The sidebar’s Integration group contains API, Webhooks, Widgets and Analytics.
The provider you have selected determines which keys, webhooks, widget examples and analytics settings you see. Switch to the correct business before configuring an integration.
MCP is an account connection: open your account Settings → MCP to review active connections. It authenticates you as a user and lets you select one of your linked providers. It does not use the provider API keys shown on the API page.
Understand the data model
Section titled “Understand the data model”| Concept | What it represents |
|---|---|
| Provider | The business whose data you manage. |
| Service | A product or service sold by that business. |
| Plan | A package within a service. |
| Period | The billing interval or fixed term associated with a plan. |
| Add-on and option | An extra feature, variant or usage allowance. |
| Customer and contact | The billing customer and its contact people. |
| Subscription | An individual subscribed item with its own status and dates. |
| Subscription group | Related subscription items created through the same checkout. A group ID and subscription ID are different identifiers. |
| Usage | The consumption recorded against an individual subscription. |
Discover IDs through API responses or MCP tools. Names, storefront slugs and identifiers are not interchangeable.
Build your first integration
Section titled “Build your first integration”- Configure the service, plans, billing periods and prices in Komashi.
- Choose how the customer will interact with it: your own frontend, a widget or the Komashi storefront.
- For a backend integration, create a separate API key and make a read-only request first. For an AI assistant, complete the MCP connection instead.
- Read the existing catalog before creating customer or subscription records. Use the returned IDs.
- For a payable subscription flow, send the customer to the returned checkout URL. Determine subscription access from Komashi’s subscription state rather than a browser return URL alone.
- Add webhooks for the events your system needs, and reconcile important records through the API.
- Configure analytics if you need visitor measurement; it serves a different purpose from operational webhooks.
Keep provider API keys on your backend. A widget embed contains public configuration such as a service ID and does not require an API key in the browser.
Common integration patterns
Section titled “Common integration patterns”A subscription website: embed the Service Picker and let Komashi display the configured plans. Handle any business-specific access rules in your application and use API lookups or webhooks to keep them current.
An existing SaaS application: use the REST API to connect your customer records, create subscription checkout flows and record usage. sync-usage sets an absolute total; adjust-usage applies an increase or decrease.
An AI-assisted workflow: connect through https://mcp.komashi.com/, choose the business, and ask the assistant to inspect the catalog, manage records or prepare setup drafts. Review the proposed changes before approving actions.


