Skip to content

Invoices · Retrieve invoice

Retrieve an invoice

Retrieve an invoice by its ID, together with its related customer record, supplier party, and line items.

GET
/api/v1/organizations/{organizationReference}/invoices/pos/{invoiceId}Bearer token · X-Client-Id

Authentication 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.

FieldTypeDescription
X-Client-Id *stringThe organization's client identifier.
Authorization *stringBearer <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

FieldTypeDescription
organizationReference *stringReference of the organization that owns the invoice.
invoiceId *stringInvoice 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

FieldTypeDescription
id, referencestringInvoice ID and reference.
invoiceNumber, irnstringInvoice number and invoice reference number.
title, note, footer, invoiceFooterstringDescriptive text on the invoice.
statusenumDRAFT, INPUT_VALIDATED, INPUT_REJECTED, NRS_VALIDATED, FAILED_NRS_VALIDATION, VALIDATED, SUBMITTED, REJECTED, NRS_APPROVED, or NRS_REJECTED.
paymentStatusenumPENDING, PAID, or REJECTED.
creationSourceenumWEB, POS, or ERP.
qrCodeDatastringData encoded in the invoice QR code.
organizationId, organizationReferencestringOwning organization.
invoiceTemplateIdstringTemplate used to render the invoice.

Dates, currency, and references

FieldTypeDescription
invoiceDate, dueDate, taxPointDate, actualDeliveryDatedateDates formatted yyyy-MM-dd.
invoiceTimestringTime of issue.
invoiceKind, invoiceTypeCodestringKind and type code of the invoice.
documentCurrencyCode, taxCurrencyCodestringCurrency codes, for example NGN.
accountingCost, buyerReference, orderReference, paymentTermsNotestringOptional commercial references.
deliveryPeriodobject{ startDate, endDate }.

Parties

FieldTypeDescription
accountingSupplierPartyobjectSupplier: supplierName, supplierAddress, supplierTin, email, telephone, businessDescription, postalAddress.
customerRecordobjectCustomer: id, customerName, customerAddress, customerEmail, customerPhone, customerTin, vatNumber, customerType (BUSINESS, INDIVIDUAL, GOVERNMENT), status (ACTIVE, INACTIVE), postalAddress, audit fields.
postalAddressobjectstreetName, cityName, postalZone, country, state, lga.

Lines, totals, and tax

FieldTypeDescription
lineItemsarrayEach line: id, quantity, invoicedQuantity, unitPrice, lineExtensionAmount, discountRate, discountAmount, feeRate, feeAmount, hsnCode, isicCode, productCategory, serviceCategory, item { name, description, sellerItemIdentification }, price { priceAmount, priceBaseQuantity, currencyUnit, priceUnit }.
legalMonetaryTotalobjectlineExtensionAmount, taxExclusiveAmount, taxInclusiveAmount, payableAmount.
taxTotalsarraytaxAmount and taxSubtotals (taxableAmount, taxAmount, taxCategory { categoryId, percent }).
allowance_chargesarrayamount and charge_indicator (snake_case in the API).
paymentMeansarraypaymentMeansCode and paymentDueDate.

Document references and audit

FieldTypeDescription
dispatchDocumentReference, receiptDocumentReference, originatorDocumentReference, contractDocumentReferenceobject{ irn, issueDate }.
billingReferences, additionalDocumentReferencesarrayLists of { irn, issueDate }.
createdBy, dateCreated, updatedBy, dateUpdatedstringAudit 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

FieldTypeDescription
400Bad RequestThe request could not be processed.
401UnauthorizedToken missing, expired, or invalid.
403ForbiddenThe caller may not access this invoice.
404Not FoundNo invoice with this ID in the organization.
409ConflictThe request conflicts with the current state.
500Internal Server ErrorUnexpected server error.

Error bodies use the same envelope with successful: false. See Errors.

Retrieval notes

Persist invoice IDs exactly as returned
Read status and paymentStatus separately: they are independent
Re-fetch the invoice to see its latest status; dateUpdated shows the last change
Cache only when your workflow tolerates stale status
Amounts are numbers in the invoice currency (documentCurrencyCode)