This page exists in one language only. Some pages here are English, some Swedish.
Connect an AI assistant
Use MCP to let an AI assistant read the Stockisto data your signed-in role can access. Start with a read-only connection. Add write access only for a task that needs it.
Choose an endpoint
| Endpoint | Use it for | Sign-in |
|---|---|---|
https://api.test.stockisto.com/mcp | Public where-to-buy search | None |
https://api.test.stockisto.com/mcp/me | Your supplier, retailer, or installer tools | OAuth sign-in |
/mcp serves only find_where_to_buy. /mcp/me shows tools for your signed-in role and consent scope. A read-only grant never shows write tools.
Use a public API origin
Outside local Development, Stockisto must advertise its configured public API origin. This keeps sign-in, consent, and discovery URLs reachable by your assistant. Ask your Stockisto administrator if the connection opens an internal hostname or a URL that returns 403.
First connection: supplier read
- Add
https://api.test.stockisto.com/mcp/mein your assistant's connector settings. - Sign in with a
SupplierAdminorSupplierVieweraccount. - Choose the default read-only consent.
- List tools, then call
supplier_list_retailers.
This first call reads your supplier network. It does not change retailer stock or any other data.
Tools for each role
| Session | Read tools | Write tools after read + write consent |
|---|---|---|
| Supplier admin or viewer | supplier_search_products, supplier_list_stock, supplier_list_retailers, supplier_get_retailer, supplier_get_funnel, supplier_get_attribution_baseline, supplier_get_outreach_draft | supplier_save_outreach_draft for supplier admins with the ai-recommendations feature enabled; supplier_enable_stock_scraping for supplier admins |
| Retailer admin | retailer_list_store_questions, retailer_get_store_question, retailer_list_store_reviews, retailer_get_store_review, retailer_list_locations | retailer_update_stock, retailer_confirm_stock |
| Approved installer | installer_list_leads, installer_get_my_company, installer_list_reviews, installer_list_job_requests, installer_get_lead_responsiveness | installer_submit_quote |
Stockisto operator tools are not part of customer setup. A supplier, retailer, or installer session cannot list another role's tools.
Optional writes need separate consent
Complete the read-only check first. If you need a write tool, reconnect and choose read + write consent. Review the tool, target record, and expected change before your assistant calls it.
For supplier admins with the ai-recommendations feature enabled, supplier_save_outreach_draft saves a draft. It does not send outreach. supplier_enable_stock_scraping switches the daily stock check on or off for one of your brands; switching it on works only for accounts the daily check serves. retailer_update_stock, retailer_confirm_stock, and installer_submit_quote act only for the signed-in role.
Remove access and recover
Open Settings → Connected AI assistants in your portal and remove the assistant's grant. The portal calls DELETE /api/v1/me/oauth-grants/{id} for your own grant.
Grant removal, protocol token revocation, session invalidation, and token expiry are different:
- Removing a grant makes its stored refresh token fail on the next
POST /oauth/tokenrequest. POST /oauth/revokeis the OAuth protocol route for revoking a token.- A logout, password change, inactive account, or failed admin MFA check invalidates an issued MCP token through business-session validation.
- An access token also stops working at its issued expiry. Use the
expires_invalue from the token response.
If a connection no longer works, sign in again and reconnect. If the assistant still receives a role refusal, check that you chose the correct portal account and consent scope.
If saving an outreach draft reports that ai-recommendations is not enabled, ask your Stockisto administrator about feature access. Reconnecting or granting write consent does not enable the feature.
Related guides
- Integrations and embed: install the widget or use public locator APIs.
- Settings: portal settings, including connected assistants.