{"openapi":"3.1.0","info":{"title":"SendRegistered API","version":"1.0.0","summary":"Send registered letters to 10 countries from your software.","description":"Upload a PDF or Word document, create and pay a registered letter from prepaid business credit, follow tracking with signed webhooks and download the proof certificate. All amounts in API responses are in cents of the stated currency.","contact":{"name":"SendRegistered Support","url":"https://sendregistered.com/contact","email":"support@sendregistered.com"}},"servers":[{"url":"https://api.sendregistered.com/v1","description":"Production & test API host (mode determined by API key prefix sr_live_ or sr_test_)"},{"url":"https://sendregistered.com/v1","description":"Primary web origin"}],"security":[{"bearerAuth":[]}],"tags":[{"name":"Documents","description":"Upload a PDF or Word document (.docx, .doc, .odt, .rtf) and check envelope address window fit."},{"name":"Letters","description":"Create, pay, inspect, cancel and download proof for registered letters."},{"name":"Account","description":"The organisation's details, team members, invoices, receipts and address book."},{"name":"Help","description":"Answers from the SendRegistered help centre and website FAQs."},{"name":"Pricing & Balance","description":"List destinations, calculate quotes and inspect credit balance."},{"name":"Webhooks","description":"Signed event notifications for letter status transitions and low credit."}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"API key (sr_live_... or sr_test_...)","description":"Authenticate with `Authorization: Bearer sr_live_...` for real letters or `Authorization: Bearer sr_test_...` for free sandbox test letters."}},"parameters":{"IdempotencyKey":{"name":"Idempotency-Key","in":"header","required":true,"description":"Unique string (8–200 characters) per write operation to safely retry without duplicate charges.","schema":{"type":"string","minLength":8,"maxLength":200}},"LetterId":{"name":"id","in":"path","required":true,"description":"Letter identifier (e.g. `SR-2026-00042` or `SR-TEST-2026-00001`).","schema":{"type":"string"}}},"schemas":{"DestinationCode":{"type":"string","enum":["DE","FR","BE","ES","CH","LI","IT","NL","GB","US"]},"Address":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"street":{"type":"string","minLength":1,"maxLength":160},"zip":{"type":"string","minLength":1,"maxLength":20},"city":{"type":"string","minLength":1,"maxLength":100},"country":{"type":"string","minLength":2,"maxLength":60},"state":{"type":"string","maxLength":2},"attn":{"type":"string","maxLength":100}},"required":["name","street","zip","city","country"]},"QuoteRequest":{"type":"object","properties":{"destination":{"type":"string","enum":["DE","FR","BE","ES","CH","LI","IT","NL","GB","US"]},"product_id":{"type":"string","maxLength":100},"color":{"default":false,"type":"boolean"},"duplex":{"default":false,"type":"boolean"},"acknowledgement":{"default":false,"type":"boolean"},"pages":{"type":"integer","minimum":1,"maximum":20},"sender_country":{"type":"string"}},"required":["destination","pages"]},"DocumentUploadRequest":{"type":"object","properties":{"filename":{"default":"letter.pdf","description":"Original filename with its extension: .pdf, .docx, .doc, .odt or .rtf.","type":"string","maxLength":100},"content_base64":{"type":"string","minLength":1,"maxLength":12000000,"description":"The file, base64-encoded. At most 8 MB before encoding (a Word document at most 4 MB)."}},"required":["content_base64"]},"DocumentUpload":{"type":"object","required":["id","pages","size_bytes","sha256","source"],"properties":{"id":{"type":"string","description":"Document ID for `POST /letters`."},"pages":{"type":"integer","minimum":1,"maximum":20,"description":"Pages of the PDF we print."},"size_bytes":{"type":"integer"},"sha256":{"type":"string","description":"SHA-256 of the PDF we print (after conversion and the print checks)."},"source":{"type":"object","description":"The file as you sent it. Both fingerprints appear in the proof.","required":["type","filename","sha256","converted"],"properties":{"type":{"type":"string","enum":["pdf","docx","doc","odt","rtf"]},"filename":{"type":"string"},"sha256":{"type":"string","description":"SHA-256 of the file as you sent it."},"converted":{"type":"boolean","description":"True when a Word document was converted to PDF."}}},"fit":{"type":["object","null"]},"fit_confirmation_required":{"type":"boolean"},"print_note":{"type":["string","null"]},"fit_note":{"type":["string","null"]},"address_page_required":{"type":"boolean"}}},"LetterCreateRequest":{"type":"object","properties":{"destination":{"type":"string","enum":["DE","FR","BE","ES","CH","LI","IT","NL","GB","US"]},"product_id":{"type":"string","maxLength":100},"color":{"default":false,"type":"boolean"},"duplex":{"default":false,"type":"boolean"},"acknowledgement":{"default":false,"type":"boolean"},"document_id":{"type":"string","minLength":1,"maxLength":100},"sender":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"street":{"type":"string","minLength":1,"maxLength":160},"zip":{"default":"","type":"string","maxLength":20},"city":{"type":"string","minLength":1,"maxLength":100},"country":{"type":"string"},"state":{"type":"string","maxLength":2},"attn":{"type":"string","maxLength":100}},"required":["name","street","city","country"]},"recipient":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"street":{"type":"string","minLength":1,"maxLength":160},"zip":{"type":"string","minLength":1,"maxLength":20},"city":{"type":"string","minLength":1,"maxLength":100},"country":{"type":"string","minLength":2,"maxLength":60},"state":{"type":"string","maxLength":2},"attn":{"type":"string","maxLength":100}},"required":["name","street","zip","city","country"]},"cover":{"default":true,"type":"boolean"},"fit_approved":{"default":false,"type":"boolean"},"terms":{"default":false,"type":"boolean"},"topic":{"type":"string","maxLength":80},"handwritten_ack":{"default":false,"type":"boolean"},"pay":{"default":true,"type":"boolean"}},"required":["destination","document_id","sender","recipient"]},"LetterPayRequest":{"type":"object","properties":{"terms":{"type":"boolean","const":true}},"required":["terms"],"additionalProperties":false},"LetterSummary":{"type":"object","required":["id","test","status","destination","product_id","pages","currency","amount","credit_amount","created_at","paid_at","tracking_number","times","cancelled"],"properties":{"id":{"type":"string","description":"Unique letter ID."},"test":{"type":"boolean","description":"True when created with an `sr_test_` key."},"status_group":{"type":"string","enum":["needs_action","awaiting_pickup","on_its_way","returned","delivered","cancelled"],"description":"How the customer thinks about the letter: needs_action, awaiting_pickup (waiting at the post office), on_its_way, returned, delivered or cancelled."},"status_text":{"type":"string","description":"The status in plain English, as the letter page shows it."},"origin":{"type":"string","enum":["website","api","ai_assistant"],"description":"Where the letter was made: on the website, with an API key, or by the customer's AI assistant (such as ChatGPT or Claude)."},"recipient":{"type":"object","description":"Recipient name and city only. The full address is never returned.","properties":{"name":{"type":"string"},"city":{"type":"string"},"country":{"type":"string"}}},"last_event_at":{"type":"string","format":"date-time","description":"Time of the latest step the letter reached."},"pickup":{"type":["object","null"],"description":"Set while the letter waits at the post office: where, and until which date.","properties":{"location":{"type":["string","null"]},"until":{"type":["string","null"]}}},"status":{"type":"string","enum":["awaiting_confirmation","awaiting_payment","received","printed","posted","transit","delivered","returned","refunded","failed","closed"]},"destination":{"$ref":"#/components/schemas/DestinationCode"},"product_id":{"type":"string","description":"Catalogue product ID such as `de-einwurf` or `fr-lrar`."},"pages":{"type":"integer","minimum":1,"maximum":20},"currency":{"type":"string","enum":["EUR","CHF"]},"amount":{"type":"integer","description":"Total amount in cents."},"credit_amount":{"type":"integer","description":"Amount debited from prepaid credit in EUR cents."},"created_at":{"type":"string","format":"date-time"},"paid_at":{"type":["string","null"],"format":"date-time"},"tracking_number":{"type":["string","null"]},"times":{"type":"object","additionalProperties":{"type":"string"}},"cancelled":{"type":"boolean"},"key_id":{"type":"string"}}},"WebhookEvent":{"type":"object","required":["id","type","created_at","livemode","data"],"properties":{"id":{"type":"string"},"type":{"type":"string","enum":["letter.paid","letter.printed","letter.posted","letter.awaiting_pickup","letter.delivered","letter.failed","letter.cancelled","balance.low"]},"created_at":{"type":"string","format":"date-time"},"livemode":{"type":"boolean"},"data":{"type":"object"}}},"ErrorResponse":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","doc_url"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"doc_url":{"type":"string","format":"uri"}}}}}}},"paths":{"/openapi.json":{"get":{"operationId":"getOpenApiSpec","summary":"OpenAPI 3.1 specification","description":"Returns this OpenAPI 3.1 specification generated directly from the handler schemas.","security":[],"tags":["Pricing & Balance"],"responses":{"200":{"description":"OpenAPI 3.1 JSON document","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/destinations":{"get":{"operationId":"listDestinations","summary":"List destinations and products","description":"Returns the destination countries on sale, their postal products, carrier names, prices in cents. A product with sender_country only takes a sender address in that country (raccomandata: IT).","tags":["Pricing & Balance"],"responses":{"200":{"description":"Destinations and products on sale","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/quotes":{"post":{"operationId":"createQuote","summary":"Calculate a letter quote","description":"Quotes a letter in cents for the authenticated business account, applying EU reverse charge or non-EU VAT rules when configured on the account.","tags":["Pricing & Balance"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteRequest"}}}},"responses":{"200":{"description":"Price quote in cents","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid quote parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/balance":{"get":{"operationId":"getBalance","summary":"Get prepaid credit balance","description":"Returns the account's prepaid credit balance in EUR cents (`paid`, `bonus`, `subscription`, `total` and active `lots`).","tags":["Pricing & Balance"],"responses":{"200":{"description":"Current credit balance and active credit lots","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/documents":{"post":{"operationId":"uploadDocument","summary":"Upload a document","description":"Uploads a base64-encoded PDF or Word document (up to 8 MB, a Word document up to 4 MB; 1–20 pages) and checks whether the pages fit the printable area and envelope window. A Word document (.docx, .doc, .odt, .rtf) is converted to PDF first; `pages`, `sha256` and `fit` then describe the PDF we will print, and `source` describes the file as you sent it. We detect the type from the file's bytes. Tracked changes and comments are not printed; date fields show the date of the upload.","tags":["Documents"],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentUploadRequest"}}}},"responses":{"201":{"description":"Uploaded document metadata and fit check result","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DocumentUpload"}}}},"400":{"description":"`pdf_invalid`: the file is not a readable PDF or one of the accepted Word types, or the request body is invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"413":{"description":"`pdf_too_large`: keep the file at 8 MB or less before encoding (a Word document 4 MB or less)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"`document_conversion_failed`: we could not convert the Word document; `document_password_protected`: the Word document has a password","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/letters":{"post":{"operationId":"createLetter","summary":"Create (and optionally pay) a registered letter","description":"Creates a registered letter from an uploaded document. Pass `pay: true` and `terms: true` to pay immediately from prepaid credit and queue for printing.","tags":["Letters"],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterCreateRequest"}}}},"responses":{"201":{"description":"Created letter summary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterSummary"}}}},"409":{"description":"Insufficient credit, spending limit exceeded, or product not on sale","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"get":{"operationId":"listLetters","summary":"List and filter the account's letters","description":"Returns the organisation's letters, newest first: letters sent by every team member on the website, with an API key and by the customer's AI assistant (such as ChatGPT or Claude). A team member's key also sees letters their colleagues sent for the same business account. A test key sees only test letters. Filter by status group, recipient name or city, dates, destination and origin.","tags":["Letters"],"parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["not_delivered","awaiting_pickup","returned","needs_action","delivered","cancelled"]},"description":"not_delivered (on its way or waiting for pickup), awaiting_pickup, returned, needs_action, delivered or cancelled."},{"name":"recipient","in":"query","required":false,"schema":{"type":"string","maxLength":100},"description":"Words in the recipient's name or city, or a letter ID. Case and accents are ignored."},{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date"},"description":"Created on or after this date."},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date"},"description":"Created on or before this date."},{"name":"destination","in":"query","required":false,"schema":{"$ref":"#/components/schemas/DestinationCode"}},{"name":"origin","in":"query","required":false,"schema":{"type":"string","enum":["website","api","ai_assistant"]}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":20}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"next_cursor from the previous page."}],"responses":{"200":{"description":"List of letters","content":{"application/json":{"schema":{"type":"object","required":["data","next_cursor"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LetterSummary"}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/help":{"get":{"operationId":"searchHelp","summary":"Answer a question from the help centre","description":"Answers general questions about SendRegistered (delivery times, proof, withdrawal, files, security) from the help centre and website FAQs in six languages. Each answer links its page and carries the date it was last reviewed. Answers about one country include current prices from the live price list. When `no_good_match` is true there is no good answer: do not guess.","tags":["Help"],"parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":300},"description":"The question in the customer's own words."},{"name":"lang","in":"query","required":false,"schema":{"type":"string","enum":["en","de","fr","es","nl","it"],"default":"en"}},{"name":"country","in":"query","required":false,"schema":{"$ref":"#/components/schemas/DestinationCode"},"description":"Destination country, when the question is about one country."}],"responses":{"200":{"description":"Up to three answers","content":{"application/json":{"schema":{"type":"object","required":["question","language","content_version","answers","no_good_match"],"properties":{"question":{"type":"string"},"language":{"type":"string"},"content_version":{"type":"string","description":"Changes whenever the help content changes."},"no_good_match":{"type":"boolean"},"note":{"type":"string"},"answers":{"type":"array","items":{"type":"object","properties":{"question":{"type":"string"},"answer":{"type":"string"},"url":{"type":"string","format":"uri"},"language":{"type":"string"},"reviewed_on":{"type":"string","format":"date"},"country":{"type":["string","null"]},"current_prices":{"type":["array","null"],"items":{"type":"object","properties":{"product":{"type":"string"},"price":{"type":"number"},"currency":{"type":"string"}}}}}}}}}}}}}}},"/account":{"get":{"operationId":"getAccount","summary":"Account and organisation","description":"The organisation of the key (name, country, registration and VAT number), its team members and roles, and its prepaid credit in euros. Every team member's key reads the whole organisation.","tags":["Account"],"responses":{"200":{"description":"Account details","content":{"application/json":{"schema":{"type":"object","properties":{"your_email":{"type":"string"},"your_role":{"type":"string","enum":["owner","member","personal"]},"organisation":{"type":["object","null"]},"members":{"type":"array","items":{"type":"object","properties":{"email":{"type":"string"},"name":{"type":["string","null"]},"role":{"type":"string"},"status":{"type":"string"}}}},"credit":{"type":["object","null"]}}}}}}}}},"/invoices":{"get":{"operationId":"listInvoices","summary":"Invoices and receipts of the organisation","description":"Paid letters of every team member and the account's credit payments, newest first.","tags":["Account"],"parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":120},"description":"Words to search for: letter id, date, amount."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":20}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"next_cursor from the previous page."}],"responses":{"200":{"description":"One page","content":{"application/json":{"schema":{"type":"object","required":["data","next_cursor"],"properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["letter","credit","recurring"],"description":"letter, credit (a payment for prepaid credit) or recurring (a recurring credit payment)."},"date":{"type":"string","format":"date-time"},"amount":{"type":"number","description":"In the currency, not in cents."},"currency":{"type":"string"},"description":{"type":"string"},"letter_id":{"type":["string","null"]}}}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/invoices/{id}/receipt":{"get":{"operationId":"getInvoiceReceipt","summary":"Download a receipt","description":"The payment receipt PDF of one of the organisation's invoices.","tags":["Account"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Receipt PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"Not an invoice of this organisation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/addresses":{"get":{"operationId":"listAddresses","summary":"The organisation's address book","description":"Saved recipients (default) or senders of every team member, with who saved each one.","tags":["Account"],"parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":120},"description":"Words from the name, street, postcode, city or country."},{"name":"role","in":"query","required":false,"schema":{"type":"string","enum":["recipient","sender"],"default":"recipient"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":20}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"next_cursor from the previous page."}],"responses":{"200":{"description":"One page","content":{"application/json":{"schema":{"type":"object","required":["data","next_cursor"],"properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"role":{"type":"string","enum":["recipient","sender"]},"name":{"type":"string"},"attn":{"type":"string"},"street":{"type":"string"},"zip":{"type":"string"},"city":{"type":"string"},"state":{"type":["string","null"]},"country":{"type":"string"},"is_default":{"type":"boolean"},"saved_by":{"type":"string"},"updated_at":{"type":"string","format":"date-time"}}}},"next_cursor":{"type":["string","null"]}}}}}}}}},"/letters/summary":{"get":{"operationId":"lettersSummary","summary":"Summary of the account's letters","description":"How many letters are on their way, waiting for pickup, returned, delivered or need the customer's action, plus up to 10 letters to look at first.","tags":["Letters"],"responses":{"200":{"description":"Counts per status group and the letters that need attention","content":{"application/json":{"schema":{"type":"object","required":["total","not_delivered","counts","attention"],"properties":{"total":{"type":"integer"},"not_delivered":{"type":"integer"},"counts":{"type":"object","properties":{"needs_action":{"type":"integer"},"awaiting_pickup":{"type":"integer"},"on_its_way":{"type":"integer"},"returned":{"type":"integer"},"delivered":{"type":"integer"},"cancelled":{"type":"integer"}}},"attention":{"type":"array","items":{"$ref":"#/components/schemas/LetterSummary"}}}}}}}}}},"/letters/{id}":{"get":{"operationId":"getLetter","summary":"Get a letter","description":"Returns status, price, timestamps and tracking number for one letter.","tags":["Letters"],"parameters":[{"$ref":"#/components/parameters/LetterId"}],"responses":{"200":{"description":"Letter summary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterSummary"}}}},"404":{"description":"Letter not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/letters/{id}/pay":{"post":{"operationId":"payLetter","summary":"Pay an unpaid letter from credit","description":"Pays an existing `awaiting_confirmation` or `awaiting_payment` letter from prepaid credit within the API key's spending limit.","tags":["Letters"],"parameters":[{"$ref":"#/components/parameters/LetterId"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterPayRequest"}}}},"responses":{"200":{"description":"Paid letter summary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterSummary"}}}}}}},"/letters/{id}/cancel":{"post":{"operationId":"cancelLetter","summary":"Cancel a letter before printing","description":"Cancels an unpaid draft or withdraws a paid letter before it has been printed, returning credit to the balance.","tags":["Letters"],"parameters":[{"$ref":"#/components/parameters/LetterId"},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"200":{"description":"Cancelled letter summary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LetterSummary"}}}}}}},"/letters/{id}/proof":{"get":{"operationId":"getLetterProof","summary":"Get proof certificate facts or PDF","description":"Returns proof hashes, timestamps and tracking JSON, or streams the proof certificate PDF when `?format=pdf` or `Accept: application/pdf` is passed.","tags":["Letters"],"parameters":[{"$ref":"#/components/parameters/LetterId"},{"name":"format","in":"query","required":false,"schema":{"type":"string","enum":["json","pdf"]},"description":"Pass `pdf` to download the proof certificate PDF."}],"responses":{"200":{"description":"Proof certificate JSON or PDF","content":{"application/json":{"schema":{"type":"object"}},"application/pdf":{"schema":{"type":"string","format":"binary"}}}}}}}}}