Skip to content

API keys, Webhooks and MCP

Three tabs of Settings → Integrations connect SmVend to your own software and to AI assistants:

  • API: keys for the SmVend API. Your software asks for data and sends commands.
  • Webhooks: SmVend calls your server when a sale or an event happens.
  • MCP: an AI assistant works with your machines in plain language.

All three are for the Administrator, on the Pro plan.

The API tab with the list of keys

The link at the top of the card, SmVend API Spec, opens the developer documentation: api.smvend.io.

  1. Click Create API key. The New API keys dialog opens on the API key tab.
  2. Enter a Name that says what the key is for, for example the name of the system that uses it.
  3. Under Permissions leave only what the system needs:
    • Read: machine state, sales, events, stock, catalogue, collections.
    • Write: prices and planograms, catalogue, refills, collections.
    • Deposit: crediting a machine, free dispense, remote payments.
  4. If the system also checks the signature of webhooks, tick Also create a webhook signing secret. Only one active key of a company can have it.
  5. Click Generate.
  6. Your new API key shows the key. Copy it and store it in a safe place now.

Your software sends the key in the Authorization: Bearer header to the /v1.2 API.

Column What it shows
Name The name you gave
Permissions Read, Write, Deposit
Key The start and the end of the key. The whole key is never shown again
Type API key, Revoked, or Legacy with the date it stops working
Created The day the key was made
Valid until The day the key ends, if it has one
Last used The last day the key was used

Click the bin icon in the key’s row and confirm. Integrations that use the key stop working at once. A revoked key stays in the list as Revoked.

Keys made before API keys appeared are marked Legacy. They stop working on the date shown in the yellow note and in the Type column. Create an API key and move your integration to the /v1.2 API before that date.

A webhook sends data to your server when something happens, so your software does not have to ask.

The Webhooks tab: the public key and the list of webhooks

SmVend signs every webhook, so your server can check that the request really comes from us.

  1. Click Issue key pair.
  2. Save both keys. The private key is shown only once.

After that the card shows the start of the Public key with a copy icon.

  1. Click Create.
  2. In Endpoint enter the address of your server that takes the requests.
  3. In Trigger choose what to send: Sales or Events.
  4. Leave Active on.
  5. Click Create.
The Creating webhook form

In the list, a green tick in Status marks an active webhook. The pencil opens it: change the address or the trigger, or untick Active to pause it. The bin deletes it.

The format of the requests and the way to check the signature are in the developer documentation: the SmVend API Spec link in the card.

MCP (Model Context Protocol) lets an AI assistant, for example Claude or Cursor, read your machines’ data and, where its key allows, act on them. You ask in plain language.

The MCP server tab with its four steps

The tab leads you through four steps:

  1. Create an API key. MCP uses the same key as the API, with the same permissions. Go to API keys opens the API tab.
  2. Connect your assistant. Choose your client: Claude Code, Claude Desktop, Cursor or Other client. Copy the snippet and put your key in place of smvd_.... The line under the snippet says where to paste it.
  3. What it can do. The assistant gets exactly the permissions of the key: Read, Write, Deposit.
  4. More detail. The full list of tools is in the developer documentation.

The three sections are in Settings → Integrations too: you create and revoke API keys, manage webhooks and open the MCP steps there.