1 / Your own key
Create a revocable key under Issuer → API keys. Keep it as a server secret, never in public JavaScript.
RAPIDPAY / INTEGRATIONS
Automate invoice creation and connect RapidPay to your applications through our API.
API v1 depends on your environment and keys. This page contains a quickstart; it does not grant a plan or production tax submission.
POST /api/v1/invoices
Authorization: Bearer rp_v1_...
Idempotency-Key: order-001
Content-Type: application/json
201 Created / 202 Accepted
GET /api/v1/invoice-operations/{operationId}
GET /api/v1/invoices/{invoiceId}/pdfAn authenticated REST request creates an invoice for the issuer who owns the key. Then check the operation and download the PDF with the same application identity.
Create a revocable key under Issuer → API keys. Keep it as a server secret, never in public JavaScript.
Bearer identifies your app; Content-Type says JSON. Idempotency-Key is a unique reference per invoice so a retry does not issue another.
201 means a completed local operation with VERI*FACTU off. 202 means a pending TEST operation, not AEAT acceptance. Check statusUrl before using pdfUrl.
Ordinary invoice: existing customer (companyId) or full inline buyer. Simplified invoice: no full buyer; EUR 3,000 gross limit.
EUR needs no exchange object. Other currencies require a matching bank account and exchange.mode: ecb (latest observation by issueDate) or custom with a validated rate.
Before sending: issuer profile, active EUR account, key with invoices:create and an API v1 environment. Replace the domain, fake key, sample data and date; the base URL varies by environment.
POST https://YOUR_API_ORIGIN/api/v1/invoices
Authorization: Bearer rp_v1_EXAMPLE_NOT_A_REAL_KEY
Idempotency-Key: demo-20261022-001
Content-Type: application/json{
"invoiceKind": "ordinary",
"issueDate": "2026-10-22",
"currency": "EUR",
"recipientEmail": "delivery@example.test",
"invoiceDescription": "Servicio para el proyecto Álamo.\nFase 1",
"buyer": {
"legalName": "Empresa de ejemplo S.L.",
"taxId": "00000000T",
"email": "facturacion@example.test",
"addressLine1": "Calle Ejemplo 1",
"postalCode": "28001",
"city": "Madrid",
"community": "Madrid",
"country": "ES"
},
"paymentMethod": "bank_transfer",
"lines": [
{
"description": "Servicio de ejemplo",
"quantity": 1,
"unitNetCents": 10000,
"discountRate": 0,
"taxRate": 21,
"taxOperation": "S1"
}
]
}{
"invoiceKind": "simplified",
"issueDate": "2026-10-22",
"currency": "EUR",
"simplifiedCustomerReference": "Counter sale 001",
"recipientEmail": "delivery@example.test",
"paymentMethod": "card",
"lines": [
{
"description": "Service example",
"quantity": 1,
"unitNetCents": 1000,
"discountRate": 0,
"taxRate": 21,
"taxOperation": "S1"
}
]
}Omit buyer and due date; EUR 3,000 gross maximum. Optional recipientEmail works for both invoice kinds: it overrides buyer email for delivery only, without changing the PDF. If omitted, buyer email is used; for simplified invoices, a reference consisting entirely of one valid email also works for compatibility.
invoiceDescription is an optional plain-text field for ordinary F1 and replacement F3 invoices, not rectificative or simplified invoices. It is stored and immutable after issue, and appears in the PDF. It allows 150 Unicode code points and 5 entered lines after CRLF-to-LF and NFC normalization. Automatic PDF wrapping does not count as an entered line. Over-limit values return 422.
Same key and same body return the same invoice. Change the body with that key and you get 409. Use a new idempotency key (8–128 URL-safe characters) for a new invoice.
201 includes invoice.pdfUrl after local completion. For 202, GET statusUrl with the same application identity and invoices:read scope; only a final status includes invoice.pdfUrl. Download the PDF with Bearer too. There is no v1 webhook.
Install Bruno, a free, open-source API client for Mac and Windows.
POST {{baseUrl}}/api/v1/invoices.{{apiKey}}Idempotency-Key · Content-Type: application/jsonSubscribe to receive RapidPay updates by email, including launch news.
Subscription saved. You will receive RapidPay updates by email.