Invoices · Retrieve invoice
Retrieve an invoice
Retrieve an invoice by its ID, together with its related customer record, supplier party, and line items.
/api/v1/organizations/{organizationReference}/invoices/pos/{invoiceId}Bearer token · X-Client-IdAuthentication and headers
Authenticate with the bearer token from POST /api/v1/organizations/pos/authenticate (see Access token) and send the X-Client-Id header on every request. Define the host once, for example EINV_BASE_URL=https://api.uat.einvoicing.avetiumtechnologies.com/api/v1.
| Field | Type | Description |
|---|---|---|
| X-Client-Id * | string | The organization's client identifier. |
| Authorization * | string | Bearer <access_token> from POST /api/v1/organizations/pos/authenticate. |
Server-side only
Never expose bearer tokens in browser code or logs. Request a new token if the current token has expired.
Path parameters
| Field | Type | Description |
|---|---|---|
| organizationReference * | string | Reference of the organization that owns the invoice. |
| invoiceId * | string | Invoice ID, as returned by create or list (the id field). |
Success response
A successful lookup returns 200 and the envelope { statusCode, message, timestamp, data, successful }. The invoice is in data, with the fields below.
Identity and status
| Field | Type | Description |
|---|---|---|
| id, reference | string | Invoice ID and reference. |
| invoiceNumber, irn | string | Invoice number and invoice reference number. |
| title, note, footer, invoiceFooter | string | Descriptive text on the invoice. |
| status | enum | DRAFT, INPUT_VALIDATED, INPUT_REJECTED, NRS_VALIDATED, FAILED_NRS_VALIDATION, VALIDATED, SUBMITTED, REJECTED, NRS_APPROVED, or NRS_REJECTED. |
| paymentStatus | enum | PENDING, PAID, or REJECTED. |
| creationSource | enum | WEB, POS, or ERP. |
| qrCodeData | string | Data encoded in the invoice QR code. |
| organizationId, organizationReference | string | Owning organization. |
| invoiceTemplateId | string | Template used to render the invoice. |
Dates, currency, and references
| Field | Type | Description |
|---|---|---|
| invoiceDate, dueDate, taxPointDate, actualDeliveryDate | date | Dates formatted yyyy-MM-dd. |
| invoiceTime | string | Time of issue. |
| invoiceKind, invoiceTypeCode | string | Kind and type code of the invoice. |
| documentCurrencyCode, taxCurrencyCode | string | Currency codes, for example NGN. |
| accountingCost, buyerReference, orderReference, paymentTermsNote | string | Optional commercial references. |
| deliveryPeriod | object | { startDate, endDate }. |
Parties
| Field | Type | Description |
|---|---|---|
| accountingSupplierParty | object | Supplier: supplierName, supplierAddress, supplierTin, email, telephone, businessDescription, postalAddress. |
| customerRecord | object | Customer: id, customerName, customerAddress, customerEmail, customerPhone, customerTin, vatNumber, customerType (BUSINESS, INDIVIDUAL, GOVERNMENT), status (ACTIVE, INACTIVE), postalAddress, audit fields. |
| postalAddress | object | streetName, cityName, postalZone, country, state, lga. |
Lines, totals, and tax
| Field | Type | Description |
|---|---|---|
| lineItems | array | Each line: id, quantity, invoicedQuantity, unitPrice, lineExtensionAmount, discountRate, discountAmount, feeRate, feeAmount, hsnCode, isicCode, productCategory, serviceCategory, item { name, description, sellerItemIdentification }, price { priceAmount, priceBaseQuantity, currencyUnit, priceUnit }. |
| legalMonetaryTotal | object | lineExtensionAmount, taxExclusiveAmount, taxInclusiveAmount, payableAmount. |
| taxTotals | array | taxAmount and taxSubtotals (taxableAmount, taxAmount, taxCategory { categoryId, percent }). |
| allowance_charges | array | amount and charge_indicator (snake_case in the API). |
| paymentMeans | array | paymentMeansCode and paymentDueDate. |
Document references and audit
| Field | Type | Description |
|---|---|---|
| dispatchDocumentReference, receiptDocumentReference, originatorDocumentReference, contractDocumentReference | object | { irn, issueDate }. |
| billingReferences, additionalDocumentReferences | array | Lists of { irn, issueDate }. |
| createdBy, dateCreated, updatedBy, dateUpdated | string | Audit fields; the dates are date-time values. |
Status and payment are separate
An invoice can be approved by NRS while its payment is still pending.
Update and delete
To change or remove an invoice, see Update and delete in the invoices overview.
Retrieval errors
| Field | Type | Description |
|---|---|---|
| 400 | Bad Request | The request could not be processed. |
| 401 | Unauthorized | Token missing, expired, or invalid. |
| 403 | Forbidden | The caller may not access this invoice. |
| 404 | Not Found | No invoice with this ID in the organization. |
| 409 | Conflict | The request conflicts with the current state. |
| 500 | Internal Server Error | Unexpected server error. |
Error bodies use the same envelope with successful: false. See Errors.