curl --request POST \
--url https://api.altera.co/sales/invoice \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"modelType": "INVOICE",
"override": false,
"basicInformation": {
"invoiceId": 2069,
"invoiceType": "SALES",
"invoiceFormat": "%N/%M/%Y",
"saleDate": "2022-10-11T00:00:00.000Z",
"issueDate": "2022-10-11T00:00:00.000Z",
"isReceipt": false,
"relatedInvoicesIds": [],
"priceTypeId": "NET"
},
"contractor": {
"contractorRegion": "POLAND",
"country": "PL",
"contractorType": "COMPANY",
"contractorName": "Test działania",
"street": "Testowa",
"houseNumber": "10",
"flatNumber": "10",
"city": "Bydgoszcz",
"postCode": "62-156",
"defaultCurrency": "PLN",
"taxIdentificationNumber": "1589651654",
"email": "[email protected]",
"areaNumber": "+58",
"phoneNumber": "518 961 516"
},
"invoicePosition": [
{
"productPosition": 0,
"productName": "A",
"positionType": "PRODUCT",
"productCategory": "Health",
"quantity": 10,
"unit": "szt.",
"priceType": null,
"unitNetPrice": 150,
"unitGrossPrice": 184.5,
"vat": "23%",
"pkwiu": "",
"discount": "0",
"deductions": false,
"netPrice": "1500",
"grossPrice": "1845",
"invoiceProductId": 179
}
],
"additionalDetails": "",
"correctionReason": "",
"payments": {
"isPaid": false,
"paymentMethod": "TRANSFER",
"dueDate": "2022-10-25T00:00:00.000Z",
"bankAccountNumber": "10 1010 1062 5565 1561 5615 1516",
"isSplitPayment": false
},
"projects": []
}
'{
"result": "OK",
"data": {
"invoiceId": 12413
}
}curl --request POST \
--url https://api.altera.co/sales/invoice \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"modelType": "INVOICE",
"override": false,
"basicInformation": {
"invoiceId": 2069,
"invoiceType": "SALES",
"invoiceFormat": "%N/%M/%Y",
"saleDate": "2022-10-11T00:00:00.000Z",
"issueDate": "2022-10-11T00:00:00.000Z",
"isReceipt": false,
"relatedInvoicesIds": [],
"priceTypeId": "NET"
},
"contractor": {
"contractorRegion": "POLAND",
"country": "PL",
"contractorType": "COMPANY",
"contractorName": "Test działania",
"street": "Testowa",
"houseNumber": "10",
"flatNumber": "10",
"city": "Bydgoszcz",
"postCode": "62-156",
"defaultCurrency": "PLN",
"taxIdentificationNumber": "1589651654",
"email": "[email protected]",
"areaNumber": "+58",
"phoneNumber": "518 961 516"
},
"invoicePosition": [
{
"productPosition": 0,
"productName": "A",
"positionType": "PRODUCT",
"productCategory": "Health",
"quantity": 10,
"unit": "szt.",
"priceType": null,
"unitNetPrice": 150,
"unitGrossPrice": 184.5,
"vat": "23%",
"pkwiu": "",
"discount": "0",
"deductions": false,
"netPrice": "1500",
"grossPrice": "1845",
"invoiceProductId": 179
}
],
"additionalDetails": "",
"correctionReason": "",
"payments": {
"isPaid": false,
"paymentMethod": "TRANSFER",
"dueDate": "2022-10-25T00:00:00.000Z",
"bankAccountNumber": "10 1010 1062 5565 1561 5615 1516",
"isSplitPayment": false
},
"projects": []
}
'{
"result": "OK",
"data": {
"invoiceId": 12413
}
}OpenApi Key created within Altera.app for a certain company
Defines whether we wish to override split payments warning, in Machine-machine integrations should be set to true
Show child attributes
The type of invoice we wish to create
SALES, PRO_FORMA, INTERIM, INTERIM_FINAL, CORRECTION "SALES"
Defines the Invoice numbering format that will be used; Altera providesa set of pre-defined formats right after company creation. They can be reviewed in the UI
"%N/%M/%Y"
NET, GROSS "NET"
Invoice identificator, used for updating documents
Defines whether we are creating an invoice to an already issued receipt
Optional array of invoiceIds that should be related to the document we are creating; Rule of thumb if you wish to work with relatedInvoices (CORRECTION, INTERIM_FINAL) it is best to start from th pre-populated object retrieved via GET /sales/invoice with parameter related in use
DRAFT, ISSUED "ISSUED"
Show child attributes
EU, OUTSIDE_OF_EU, POLAND "POLAND"
ISO 3166-1 alfa-2 two letter country code
2"PL"
COMPANY, PRIVATE_PERSON "COMPANY"
45Comma delimited list of contractor e-mails
200545Show child attributes
Zero based position number in invoice
0
200PRODUCT, SERVICE "SERVICE"
Allows grouping of similar products
"Personalized"
14
"pcs."
Defines the net price per item
100
Defines the gross price per item
123
Defines the vat rate used for this product
23%, 8%, 5%, 0%, np, zw "23%"
Defines % discount on given product
"10%"
Describes extra information that we wish to present on the invoice
Additional information regarding the reason behing correcting your invoice
Was this page helpful?