SendLetter Webhooks API
Where status changes are sent, and how to subscribe.
Where status changes are sent, and how to subscribe.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/sendletter-eu:sendletter-eu-webhooks-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: SendLetter Webhooks API
version: 1.3.0
description: 'Post a real letter from one HTTP call. Text, a document or a finished PDF goes in with an address, a printed and franked letter comes out, and the status arrives on a webhook.
All money is integer cents in euro. Amounts named `priceCents` exclude VAT; `totalCents` includes it and is the amount charged.
**Test mode.** A key beginning `sk_test_` renders, prices and tracks a letter exactly as a live key would, walks it through submitted, printed, posted and delivered, and fires every callback along the way. Nothing is printed, nothing is posted, and the wallet is not touched. Build and demonstrate an integration entirely on a test key.
**Retries.** Send an `idempotencyKey` on anything that creates a letter. A repeated call with the same key returns the original letter instead of posting a second one.
**Tracing.** Every API response carries `X-Request-Id`; API error bodies repeat it as `requestId`. You may supply a safe `X-Request-Id` yourself. Quote that value to support for one request, and the letter `id` to follow an order across later payment and provider webhooks.
**Cost controls.** New keys start with `letters:read letters:quote letters:draft letters:send` and configurable per-letter, UTC-day and UTC-month ceilings. A refused ceiling moves no wallet money and posts nothing. Add `account:read` or `webhooks:write` only when needed.'
contact:
name: Twilper
url: https://sendletter.eu
license:
name: CC0-1.0
identifier: CC0-1.0
termsOfService: https://sendletter.eu/nl/terms
servers:
- url: https://sendletter.eu
security:
- bearerAuth: []
tags:
- name: Webhooks
description: Where status changes are sent, and how to subscribe.
paths:
/api/v1/webhooks:
get:
operationId: listWebhooks
tags:
- Webhooks
summary: The endpoints this credential has subscribed
description: An API key carrying `webhooks:write` sees every endpoint on the account. A connected application sees only the ones it created. Secrets are never returned here; the secret is shown once, when the subscription is made.
responses:
'200':
description: The subscriptions, and every event that can be asked for
content:
application/json:
schema:
type: object
properties:
data:
type: array
items:
$ref: '#/components/schemas/Webhook'
availableEvents:
type: array
items:
type: string
'401':
description: Missing, malformed or revoked API key
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'403':
description: The credential does not carry the permission this operation requires.
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'429':
description: Rate limited. Read Retry-After for the number of seconds to wait. Reads allow 300 and writes 120 requests per minute per key. Paid sends can also be refused when the credential's daily or monthly spending ceiling is reached.
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
post:
operationId: subscribeWebhook
tags:
- Webhooks
summary: Send status changes to an endpoint
description: 'Subscribing the same address twice is the same subscription: the answer is 200 with the original secret rather than a second endpoint, so a workflow that re-subscribes whenever it is edited does not double every delivery. The secret appears in this response and nowhere else. The address must be https and reachable from the internet.'
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- url
properties:
url:
type: string
format: uri
maxLength: 400
events:
type: array
maxItems: 10
items:
type: string
enum:
- letter.submitted
- letter.printed
- letter.posted
- letter.delivered
- letter.failed
- letter.refunded
description: Leave empty for every event.
responses:
'200':
description: Already subscribed to that address. Same secret, events updated.
'201':
description: 'Subscribed. Store the secret: it is not shown again.'
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/Webhook'
- type: object
properties:
secret:
type: string
'401':
description: Missing, malformed or revoked API key
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'403':
description: The credential does not carry the permission this operation requires.
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'409':
description: Another connected application already delivers to that address
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'429':
description: Rate limited. Read Retry-After for the number of seconds to wait. Reads allow 300 and writes 120 requests per minute per key. Paid sends can also be refused when the credential's daily or monthly spending ceiling is reached.
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
/api/v1/webhooks/{id}:
delete:
operationId: unsubscribeWebhook
tags:
- Webhooks
summary: Stop sending to an endpoint
parameters:
- name: id
in: path
required: true
schema:
type: string
responses:
'200':
description: Removed
content:
application/json:
schema:
type: object
properties:
deleted:
type: boolean
id:
type: string
'401':
description: Missing, malformed or revoked API key
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'403':
description: The credential does not carry the permission this operation requires.
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'404':
description: No such subscription, or it belongs to another application
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'429':
description: Rate limited. Read Retry-After for the number of seconds to wait. Reads allow 300 and writes 120 requests per minute per key. Paid sends can also be refused when the credential's daily or monthly spending ceiling is reached.
headers:
X-Request-Id:
description: Identifier for tracing this request in support and operational logs.
schema:
type: string
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
components:
schemas:
Error:
type: object
required:
- error
- requestId
properties:
error:
type: object
properties:
code:
type: string
message:
type: string
details: {}
requestId:
type: string
description: Also returned as X-Request-Id. Include it when reporting a failed API call.
Webhook:
type: object
properties:
id:
type: string
description: Pass this to unsubscribe.
url:
type: string
format: uri
events:
type: array
items:
type: string
description: Empty means every event.
active:
type: boolean
description: False once deliveries have failed enough times to be given up on.
createdAt:
type: string
format: date-time
clientId:
type:
- string
- 'null'
description: The application that subscribed, or null for the account holder.
securitySchemes:
bearerAuth:
type: http
scheme: bearer
description: 'An API key from the account area, sent as `Authorization: Bearer <key>`. Keys beginning `sk_test_` run the whole lifecycle without printing, posting or charging anything; keys beginning `sk_live_` post real letters and spend real credit.'