# Generate Payment Endpoint: POST /documents/{document-id}/partial_payments.json Version: 2.0.0 Security: apiKeyAuth ## Path parameters: - `document-id` (integer, required) The ID of the document. Example: 1050 ## Query parameters: - `api_key` (string, required) Your API Key. Example: "YOUR_API_KEY" ## Request fields (application/json): - `partial_payment` (object, required) - `partial_payment.amount` (number, required) Example: 10 - `partial_payment.payment_mechanism` (string) Enum: "TB", "MB", "CC" - `partial_payment.note` (string) Stored in full on the receipt (observations). The copy on the client's treasury movement is truncated to 255 characters. Example: "Transfer" - `partial_payment.serie` (string) - `partial_payment.payment_date` (string) Example: "22/11/2025" ## Response 200 fields (application/json): - `receipt` (object) - `receipt.id` (integer) Example: 2137287 - `receipt.status` (string) Example: "final" - `receipt.archived` (boolean) - `receipt.type` (string) Example: "Invoice" - `receipt.sequence_number` (string) Example: "6/G" - `receipt.inverted_sequence_number` (string) Example: "G/6" - `receipt.atcud` (string) Example: "ABCD1234-6" - `receipt.sequence_id` (integer,null) Example: 12345 - `receipt.tax_exemption` (string) Example: "M01" - `receipt.date` (string) Example: "04/08/2016" - `receipt.due_date` (string) Example: "19/08/2016" - `receipt.reference` (string,null) Example: "ref123" - `receipt.observations` (string,null) No enforced character limit (text column). Example: "Observations" - `receipt.retention` (string,null) - `receipt.cancel_reason` (string,null) Present after the document has been canceled. No enforced character limit (text column). Example: "API test cancellation" - `receipt.permalink` (string) Example: "https://web.invoicexpress.com/documents/..." - `receipt.saft_hash` (string) Server-generated. No enforced character limit (text column). Example: "J4ay" - `receipt.sum` (number) Example: 24.39 - `receipt.discount` (number,null) - `receipt.before_taxes` (number) Example: 24.39 - `receipt.taxes` (number) Example: 5.61 - `receipt.total` (number) Example: 30 - `receipt.currency` (string) Example: "Euro" - `receipt.client` (object) id and name are always present. The other fields are only returned when they have a value. - `receipt.client.name` (string) Example: "John Doe" - `receipt.client.code` (string) Example: "C1" - `receipt.client.country` (string) Example: "Portugal" - `receipt.client.email` (string) Example: "john@example.com" - `receipt.client.address` (string) Example: "Avenida da República" - `receipt.client.postal_code` (string) Example: "1050-555" - `receipt.client.city` (string) Example: "Lisboa" - `receipt.client.fiscal_id` (string) Example: "508025338" - `receipt.client.website` (string) Example: "www.example.com" - `receipt.client.phone` (string) Example: "910000000" - `receipt.client.fax` (string) Example: "210000000" - `receipt.client.observations` (string) Example: "VIP client" - `receipt.items` (array) - `receipt.items.description` (string,null) Example: "Big Product" - `receipt.items.unit_price` (string) Example: "100.0" - `receipt.items.quantity` (string) Example: "1.0" - `receipt.items.unit` (string) Example: "un" - `receipt.items.tax` (object) - `receipt.items.tax.value` (number) Example: 23 - `receipt.items.subtotal` (number) Example: 100 - `receipt.items.tax_amount` (number) Example: 23 - `receipt.items.discount_amount` (number) - `receipt.mb_reference` (object) - `receipt.mb_reference.entity` (string) Example: "10611" ## Response 401 fields (application/json): - `errors` (array) - `errors.error` (string) Example: "Authentication Error"