API · v1 · stable
CODEMETA OSDeveloper Center
FR
Ouvrir la console

POST /v1/material-buckets/{id}/bill

POST/v1/material-buckets/{id}/bill

Create a draft invoice from a closed material bucket, or append items to an existing draft invoice

Modèle de données

Cette opération porte sur l'entité Material Bucket (material_bucket). Les 17 champs (type, validation, caractère obligatoire, relations) figurent dans la référence du schéma.

Corps de la requête

NomTypeDescription
partyIdobligatoirestring
unitPricestringDefault unit price per item (decimal string). Omit to use 0.00.
vatRatestring
paymentTermsDaysinteger
titlestring
existingInvoiceIdstringAppend items to this existing DRAFT invoice instead of creating a new one

Paramètres de chemin

NomTypeDescription
idobligatoirestring

Exemple

curl -X POST https://api.codemeta-os.de/v1/material-buckets/{id}/bill \
  -H "X-Tenant-Id: $TENANT" \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
  "partyId": "string",
  "unitPrice": "string",
  "vatRate": "19",
  "paymentTermsDays": 0,
  "title": "string",
  "existingInvoiceId": "string"
}'
const result = await cm.material-buckets.post({
  "partyId": "string",
  "unitPrice": "string",
  "vatRate": "19",
  "paymentTermsDays": 0,
  "title": "string",
  "existingInvoiceId": "string"
});

Codes de réponse

HTTP Signification
201 Default Response

Recherche