API version v1
Method reference
POST /projects/{id}/documents
Create a project document
Scope: invoices:write
Authenticate with Authorization: Bearer rv_live_…; see authentication.
Request
curl -X POST "https://api.rentevio.ru/api/public/v1/projects/00000000-0000-0000-0000-000000000000/documents" \
-H "Authorization: Bearer rv_live_…" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: …" \
-d '{
"invoice_id": "00000000-0000-0000-0000-000000000000",
"template_id": "string",
"estimate_tab_id": "00000000-0000-0000-0000-000000000000",
"firm_id": "00000000-0000-0000-0000-000000000000",
"doc_type": "string",
"amount": 0,
"payment_date": "2026-10-01",
"payload": "string"
}'
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | yes | — |
Request body
| Field | Type | Required | Description |
|---|---|---|---|
invoice_id | string | no | — |
template_id | string | yes | — |
estimate_tab_id | string | yes | — |
firm_id | string | yes | — |
doc_type | string | no | — |
amount | number | no | Игнорируется; итог берётся из вкладки сметы |
payment_date | string | no | — |
payload | string | no | JSON-строка; ключи снимка сметы не перезаписываются |
{
"invoice_id": "00000000-0000-0000-0000-000000000000",
"template_id": "string",
"estimate_tab_id": "00000000-0000-0000-0000-000000000000",
"firm_id": "00000000-0000-0000-0000-000000000000",
"doc_type": "string",
"amount": 0,
"payment_date": "2026-10-01",
"payload": "string"
}
Response
{
"success": true,
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"project_id": "00000000-0000-0000-0000-000000000000",
"invoice_id": "00000000-0000-0000-0000-000000000000",
"estimate_tab_id": "00000000-0000-0000-0000-000000000000",
"firm_id": "00000000-0000-0000-0000-000000000000",
"template_id": "string",
"doc_type": "string",
"amount": 0,
"payment_date": "string",
"status": "string",
"file_path": "string",
"created_at": "string",
"updated_at": "string"
}
}
Errors
| Code | HTTP | When |
|---|---|---|
VALIDATION | 400 | Invalid request parameters |
UNAUTHORIZED | 401 | Invalid, missing, revoked, or expired API key |
FORBIDDEN | 403 | The key does not have the required scope |
Was this helpful?