Invoice type
An invoice, advance invoice or credit note imported from an accounting system. MAX never issues
invoices: it mirrors them, and your integration keeps the copy current with
syncInvoice.
- Requires the
invoice.readpermission. - A credit note's amounts are negative: its lines, VAT summary, totals and payment amounts.
- Dates are calendar days, returned as midnight UTC.
Fields
id
The invoice's MAX id.
direction
Whether your organisation issued the invoice or received it.
kind
What kind of document it is.
status
Where the document stands in the accounting system.
failureReason
String
Why the document failed. Null unless status is FAILED, which MAX does not return yet.
source
String!
The code of the accounting system's external source.
sourceDocumentType
String
The accounting system's own name for the type of document.
sourceChangedAt
When the document last changed in the accounting system, as your integration sent it.
syncedAt
When MAX last wrote a sync or a removal of the document.
cancelled
Boolean!
Whether the document is cancelled in the accounting system.
number
String
The document's number. Every synced document has one. Null only in a status MAX does not
return yet (PENDING, FAILED).
variableSymbol
String
The variable symbol (the payment reference).
constantSymbol
String
The constant symbol.
specificSymbol
String
The specific symbol.
supplierNumber
String
On a received invoice, the supplier's own number of the document.
orderNumber
String
The number of the order the invoice names.
issueDate
The issue date. Null when the accounting system does not state it.
taxPointDate
The tax point date.
dueDate
The due date.
receivedDate
On a received invoice, the date it was received.
vatClaimDate
The date the VAT is claimed.
legalEntityId
The MAX id of the company (legal entity) the invoice belongs to.
legalEntityMatch
How MAX found the company.
partnerId
The partner's MAX id. Your integration named the partner, or MAX found it by the company registration number (IČO) or e-mail, or created it from the invoice's party.
partnerMatch
How MAX found the partner. Null when there is none.
partnerEditable
Boolean!
Whether a user (or setInvoicePartner) may set or change the partner. true when
MAX found no partner, or a user chose it.
seller
The seller as printed.
buyer
The buyer as printed.
delivery
The delivery address as printed.
paymentMethod
How the invoice is to be paid.
paymentMethodName
String
The accounting system's own label for the payment method.
bankAccountNumber
String
The bank account number for the payment.
bankCode
String
The bank code.
bankName
String
The bank's name.
iban
String
The IBAN for the payment.
swift
String
The SWIFT (BIC) code.
currencyCode
String!
The ISO 4217 code of the document's currency.
exchangeRate
The exchange rate to the home currency.
exchangeRateAmount
Int
The number of units of the document's currency that exchangeRate is quoted for.
homeCurrencyCode
String!
The ISO 4217 code of the home currency.
textBeforeItems
String
The text printed before the lines.
textAfterItems
String
The text printed after the lines.
printedNote
String
The note printed on the document.
vatNote
String
The statutory VAT wording the accounting system printed, for example "Dodanie je oslobodené od dane podľa § 43 zákona o DPH".
reverseCharge
Boolean!
Whether the reverse charge applies.
oss
Boolean!
Whether the invoice falls under the One-Stop Shop (OSS) scheme.
totalNet
The total without VAT.
totalVat
The VAT total.
totalGross
The total including VAT.
rounding
The rounding.
advancesDeducted
The advances deducted.
amountDue
The amount due.
totalNetHome
The total without VAT, in the home currency.
totalVatHome
The VAT total, in the home currency.
totalGrossHome
The total including VAT, in the home currency.
paymentStatus
How much of the invoice is paid, as the accounting system states it.
paidAmount
The amount paid. Null when the accounting system does not state it.
remainingAmount
The amount still to be paid. Null when the accounting system does not state it.
paidAt
The day the invoice was paid. Null when the accounting system does not state it.
correctsInvoiceId
On a credit note, the MAX id of the invoice it corrects. Null when that invoice is not in MAX or your API key cannot see it.
correctedNumber
String
On a credit note, the number of the invoice it corrects.
correctedIssueDate
On a credit note, the issue date of the invoice it corrects.
correctedTaxPointDate
On a credit note, the tax point date of the invoice it corrects.
correctionReason
String
On a credit note, why the invoice is corrected.
internalNote
String
A note for colleagues in MAX. It is never printed, and a sync never changes it. Null in the
result of syncInvoice and removeInvoice when your API key lacks the
invoice.read permission. No error comes with the null.
lines
Arguments:
first:Intafter:Stringlast:Intbefore:String
The lines, by lineNo.
- A connection, paged with
first/afterorlast/before, at most 250 a page. - Null, with an error at its path, when its page cannot be read, for example because of a cursor of another parent. The rest of the response is returned.
- A page costs 2 + first (or last) × the cost of one node.
vatSummary
Arguments:
first:Intafter:Stringlast:Intbefore:String
The VAT summary, the highest rate first.
- A connection, paged with
first/afterorlast/before, at most 250 a page. - Null, with an error at its path, when its page cannot be read, for example because of a cursor of another parent. The rest of the response is returned.
- A page costs 2 + first (or last) × the cost of one node.
settlements
Arguments:
first:Intafter:Stringlast:Intbefore:String
What reduced the amount due: deducted advances and offset credit notes.
- A connection, paged with
first/afterorlast/before, at most 250 a page. - Null, with an error at its path, when its page cannot be read, for example because of a cursor of another parent. The rest of the response is returned.
- A page costs 2 + first (or last) × the cost of one node.
links
Arguments:
first:Intafter:Stringlast:Intbefore:String
The MAX documents the invoice is linked to.
- A connection, paged with
first/afterorlast/before, at most 250 a page. - Null, with an error at its path, when its page cannot be read, for example because of a cursor of another parent. The rest of the response is returned.
- A page costs 2 + first (or last) × the cost of one node.
documents
Arguments:
first:Intafter:Stringlast:Intbefore:String
The invoice's files, such as the accounting system's PDF (attachInvoiceDocument),
oldest first. Removed documents are left out.
- A connection, paged with
first/afterorlast/before, at most 250 a page. Its cursors belong to this invoice's documents; any other connection refuses them. - Requires the
invoice.readpermission. - Null, with an error at its path, when its page cannot be read, for example because of a cursor of another parent. The rest of the response is returned.
- A page costs 2 + first (or last) × the cost of one node.
createdAt
When the invoice was created in MAX.
updatedAt
When the invoice last changed in MAX.
Used by
linkInvoice(mutation)setInvoicePartner(mutation)unlinkInvoice(mutation)updateInvoice(mutation)invoice(query)DocumentInvoiceConnectionInvoiceEdgeInvoiceSyncResultInvoiceTagsResultSalesOrderSalesOrderInvoiceConnection