NRS documentation version 1.1

NRS API Implementation Reference

This reference specifies the Nigeria Revenue Service (NRS) Access Point Provider (APP) invoice contract for Veridex. It covers reference resources, invoice validation, signing, status confirmation, and payment updates.

<NRS_BASE_URL>/api/v1/invoiceapplication/jsonHTTPS required
Introduction

Veridex NRS API Reference

This reference specifies the Nigeria Revenue Service (NRS) Access Point Provider (APP) invoice contract for Veridex. Validation and signing use a shared invoice schema. Subsequent requests identify the invoice by its invoice reference number (IRN). All examples use fictional data.

Version
NRS documentation 1.1

Aligned with the NRS Access Point Provider documentation, version 1.1.

Scope
Invoice contract

Reference resources, validation, signing, status confirmation, and payment updates.

Format
application/json

Request and response bodies use UTF-8 JSON over HTTPS.

01

Base URL, Authentication & Conventions

<NRS_BASE_URL> represents the NRS API host assigned to the environment. Append the endpoint paths in this reference to that base URL, and use the registrations and credentials issued for the selected environment.

Request headers

Include the following headers with each request.

http
Accept: application/json
Content-Type: application/json
x-api-key: <NRS_API_KEY>
x-api-secret: <NRS_API_SECRET>

Store API credentials securely on the server.

Conventions

  • • Use UTF-8 JSON, YYYY-MM-DD dates, and HH:MM:SS times.
  • • Currency values use ISO 4217 codes; country values use ISO 3166-1 alpha-2 codes.
  • • Monetary values are JSON numbers.
  • • Obtain classification, tax category, unit, state, and local government area (LGA) codes from the reference resource endpoints.

Identifiers

IdentifierMeaning
business_idUUID assigned to the supplier's business on NRS
invoice_referenceInvoice reference assigned by the business and supplied for IRN validation
irnInvoice reference number generated using the business's registered NRS template

Generate the IRN before submitting the invoice for validation or signing. Use the same IRN for subsequent signing, confirmation, and payment-update requests. Record the signing outcome separately from IRN generation.

02

Endpoints & Processing Sequence

Prepare the invoice and generate its IRN. Validate the IRN and invoice data before submitting the invoice for signing. Retrieve the invoice status through the confirmation endpoint and submit payment changes through the update endpoint.

POST
/api/v1/invoice/irn/validate

Validate IRN. Body: invoice_reference, business_id, irn.

POST
/api/v1/invoice/validate

Validate invoice data. Body: the full invoice schema.

POST
/api/v1/invoice/sign

Sign invoice. Body: the same full invoice body with validated values.

GET
/api/v1/invoice/confirm/{IRN}

Confirm invoice status. No body; IRN supplied in the path.

PATCH
/api/v1/invoice/update/{IRN}

Update invoice payment status. Body: payment status; amount for partial payments; optional reference.

Confirmation retrieves status information only. Invoice exchange and transmission require separate operations and are outside the scope of this reference.

03

Reference Resources

Retrieve reference data before preparing an invoice. These endpoints provide the codes used for invoice types, currencies, taxes, payment methods, item classifications, units, and addresses. All resource endpoints use GET and the authentication headers above, and accept no JSON request body.

EndpointResourceInvoice useNRS reference
/api/v1/invoice/resources/invoice-typesInvoice typesSelect invoice_type_codeInvoice types
/api/v1/invoice/resources/payment_meansPayment meansSelect payment_means[].payment_means_codePayment means
/api/v1/invoice/resources/tax-categoriesTax categoriesSelect tax_total[].tax_subtotal[].tax_category.id and the applicable percentTax categories
/api/v1/invoice/resources/currenciesCurrenciesSelect document_currency_code and tax_currency_codeCurrencies
/api/v1/invoice/resources/invoice-quantity-codesInvoice quantity codesSelect invoice_line[].price.price_unitQuantity codes
/api/v1/invoice/resources/hs-codesProduct codes (HSN)Select the goods classification for invoice_line[].hsn_code and its corresponding product_categoryProduct codes
/api/v1/invoice/resources/services-codesService codesSelect the applicable service classification when preparing a service invoiceService codes
/api/v1/invoice/resources/lgasLocal government areasSelect postal_address.lga for each accounting party; match its state_code to the selected stateLGAs
/api/v1/invoice/resources/statesStatesSelect postal_address.state for each accounting partyStates
/api/v1/invoice/resources/countriesCountriesSelect the alpha-2 code for each party's postal_address.countryCountries
/api/v1/invoice/resources/vat-exemptionsVAT exemptionsLook up VAT exemption classifications and apply the relevant NRS invoice requirementsVAT exemptions

Endpoint names are case-sensitive. In particular, the documented payment-means path uses payment_means, and the service-code path uses services-codes.

Resource request and response

The following request retrieves the LGA catalogue. The example response is shortened to two entries from the NRS reference.

http
GET <NRS_BASE_URL>/api/v1/invoice/resources/lgas
Accept: application/json
x-api-key: <NRS_API_KEY>
x-api-secret: <NRS_API_SECRET>
json
{
  "code": 200,
  "data": [
    {
      "name": "Aba North",
      "code": "NG-AB-ANO",
      "state_code": "NG-AB"
    },
    {
      "name": "Aba South",
      "code": "NG-AB-ASO",
      "state_code": "NG-AB"
    }
  ]
}

Use an entry's code as the LGA value and its state_code to associate it with the correct state. This response illustrates the LGA endpoint only; use each resource's documented response structure when reading other catalogues.

Using resource values

Preserve codes exactly as returned, including leading zeros, punctuation, and letter case. Store the code used by the invoice separately from its display description. Use the country alpha-2 code for postal_address.country; country records may also contain other identifiers.

04

Shared Invoice Schema

Submit the following structure as the root JSON object for invoice validation and signing. Include supplier and customer details, invoice lines, item and price objects, tax subtotals, and monetary totals at the specified nesting levels.

The business-to-business (B2B) example below contains one taxable goods line and uses fictional parties. Values enclosed in angle brackets are placeholders. Replace them with valid registration details, an IRN, and NRS resource codes before testing in the sandbox. State and LGA codes must match each party's address. Verify the tax category and rate against the applicable NRS resources.

json
{
  "business_id": "<NRS_BUSINESS_UUID>",
  "irn": "<IRN_MATCHING_REGISTERED_BUSINESS_TEMPLATE>",
  "invoice_kind": "B2B",
  "issue_date": "2026-08-04",
  "invoice_type_code": "380",
  "document_currency_code": "NGN",
  "tax_currency_code": "NGN",
  "accounting_supplier_party": {
    "party_name": "Example Supplier Limited",
    "tin": "<SUPPLIER_TIN>",
    "email": "supplier@example.com",
    "postal_address": {
      "street_name": "1 Example Supplier Street",
      "city_name": "Ikeja",
      "postal_zone": "100001",
      "country": "NG",
      "state": "<NRS_STATE_CODE>",
      "lga": "<NRS_LGA_CODE>"
    }
  },
  "accounting_customer_party": {
    "party_name": "Example Buyer Limited",
    "tin": "<CUSTOMER_TIN>",
    "email": "buyer@example.com",
    "postal_address": {
      "street_name": "2 Example Buyer Street",
      "city_name": "Ikeja",
      "postal_zone": "100001",
      "country": "NG",
      "state": "<NRS_STATE_CODE>",
      "lga": "<NRS_LGA_CODE>"
    }
  },
  "legal_monetary_total": {
    "line_extension_amount": 250000,
    "tax_exclusive_amount": 250000,
    "tax_inclusive_amount": 268750,
    "payable_amount": 268750
  },
  "invoice_line": [
    {
      "hsn_code": "844332",
      "product_category": "Printing machinery",
      "invoiced_quantity": 1,
      "line_extension_amount": 250000,
      "item": {
        "name": "Industrial Printer",
        "description": "Network-enabled thermal printer"
      },
      "price": {
        "price_amount": 250000,
        "base_quantity": 1,
        "price_unit": "<NRS_PRICE_UNIT_CODE>"
      }
    }
  ],
  "due_date": "2026-08-18",
  "issue_time": "14:30:00",
  "note": "Payment is due within 14 days.",
  "tax_total": [
    {
      "tax_amount": 18750,
      "tax_subtotal": [
        {
          "taxable_amount": 250000,
          "tax_amount": 18750,
          "tax_category": {
            "id": "STANDARD_VAT",
            "percent": 7.5
          }
        }
      ]
    }
  ]
}

Top-level fields

The example includes both accounting parties and the tax breakdown for the B2B transaction shown. Optional fields remain subject to the requirements of the transaction.

FieldJSON typeDescription and requirements
business_idString (UUID)Required. Supplier business registration identifier
irnStringRequired. Invoice identifier generated before validation and signing
issue_dateString (date)Required. Invoice issue date
invoice_type_codeStringRequired. Supported invoice type code
invoice_kindStringRequired in version 1.1. Transaction category; B2B in this example
document_currency_codeStringRequired. Invoice currency code
tax_currency_codeStringRequired. Tax currency code
accounting_supplier_partyObjectRequired. Supplier details
accounting_customer_partyObjectBuyer details. Included in this B2B example; the general NRS schema lists the object as optional
invoice_lineArray of objectsInvoice lines; supply at least one
tax_totalArray of objectsTax breakdown. Included in this taxable example; the general NRS schema lists the array as optional
legal_monetary_totalObjectInvoice monetary totals
due_dateString (date)Optional payment due date
issue_timeString (time)Optional invoice issue time
noteStringOptional invoice note
payment_statusStringOptional. Initial payment status; defaults to PENDING in the NRS reference
allowance_chargeArray of objectsOptional. Allowances or charges, each with a boolean charge_indicator and numeric amount
payment_meansArray of objectsOptional payment instructions with payment_means_code and payment_due_date

For additional fields, including delivery periods, document references, and other parties, consult the NRS schema linked in the references below.

Supplier and customer party schema

Apply the following structure to both accounting_supplier_party and accounting_customer_party. Place tin and email directly on the party object, and address fields within postal_address.

FieldJSON typeDescription and requirements
party_nameStringRegistered name of the party
tinStringTax identification number (TIN)
emailStringContact email address
telephoneStringOptional. Telephone number beginning with + followed by the country code
business_descriptionStringOptional business description
postal_addressObjectPostal address details applicable to the transaction
postal_address.street_nameStringStreet address
postal_address.city_nameStringCity
postal_address.postal_zoneStringPostal code
postal_address.countryStringISO 3166-1 alpha-2 country code
postal_address.stateStringState code from NRS reference resources; introduced in version 1.1
postal_address.lgaStringLGA code from NRS reference resources; introduced in version 1.1

Supply the party details required for the invoice kind. When a party object is included, validate its fields against the applicable NRS requirements.

Invoice line schema

The following fields belong to each object in the invoice_line array.

FieldJSON typeDescription and requirements
hsn_codeStringGoods classification in this example
product_categoryStringProduct category corresponding to the goods classification code
invoiced_quantityNumberQuantity invoiced
line_extension_amountNumberNet line amount
itemObjectNested item information
item.nameStringItem name
item.descriptionStringItem description
item.sellers_item_identificationStringOptional seller item identifier; omitted when absent
priceObjectNested pricing information
price.price_amountNumberPrice for the stated base quantity
price.base_quantityNumberQuantity basis for the price
price.price_unitStringApplicable price-unit code

For service invoices, verify the classification fields and codes against the applicable NRS schema and reference resources.

Tax schema

Field pathJSON typeDescription and requirements
tax_total[]ObjectTax total entry
tax_total[].tax_amountNumberTotal tax for the entry
tax_total[].tax_subtotalArray of objectsNested breakdown
tax_total[].tax_subtotal[].taxable_amountNumberTaxable base
tax_total[].tax_subtotal[].tax_amountNumberTax computed for the subtotal
tax_total[].tax_subtotal[].tax_categoryObjectNested category information
tax_total[].tax_subtotal[].tax_category.idStringApplicable NRS tax category code
tax_total[].tax_subtotal[].tax_category.percentNumberApplicable category percentage

For the example shown, sum the tax subtotals to obtain the tax total. Calculate each subtotal by multiplying the taxable amount by the applicable percentage and dividing by 100. Use the NRS category definitions to distinguish standard-rated, zero-rated, and exempt transactions.

Monetary totals

Field under legal_monetary_totalJSON typePurpose
line_extension_amountNumberSum of line net amounts
tax_exclusive_amountNumberInvoice total before tax
tax_inclusive_amountNumberInvoice total including tax
payable_amountNumberAmount payable

Reconcile invoice totals with the line amounts, taxes, and any applicable allowances, charges, prepayments, or rounding adjustments. The calculations above apply to the example shown.

05

Validate IRN

Ensure that the invoice reference and IRN correspond to the specified business registration. After IRN validation, validate the full invoice data.

http
POST <NRS_BASE_URL>/api/v1/invoice/irn/validate

{
  "invoice_reference": "EXAMPLE-INV-001",
  "business_id": "<NRS_BUSINESS_UUID>",
  "irn": "<IRN_MATCHING_REGISTERED_BUSINESS_TEMPLATE>"
}

Success response (NRS reference):

json
{"code": 200, "data": {"ok": true}}
06

Validate Invoice Data

Submit the complete invoice object defined in the shared invoice schema as the request body, including the identifiers, accounting parties, invoice lines, tax breakdown, and monetary totals.

http
POST <NRS_BASE_URL>/api/v1/invoice/validate

Success response (NRS reference):

json
{"code": 200, "data": {"ok": true}}

Resolve any validation errors and resubmit the corrected invoice. Proceed to signing after NRS accepts the invoice data.

07

Sign Invoice

Submit the complete invoice object defined in the shared invoice schema, using the IRN and values accepted during validation. If the invoice changes before signing, validate the revised content first.

http
POST <NRS_BASE_URL>/api/v1/invoice/sign

Success response (NRS reference):

json
{"code": 201, "data": {"ok": true}}

Retain the signing result against the existing IRN. The NRS success response shown above contains an acceptance flag and does not return a new IRN.

08

Confirm Invoice Status

Replace {IRN} with the invoice's IRN. This request has no body.

http
GET <NRS_BASE_URL>/api/v1/invoice/confirm/{IRN}

Example response using the NRS response structure:

json
{
  "code": 200,
  "data": {
    "issue_date": "2026-08-04",
    "due_date": "2026-08-18",
    "sync_date": "2026-08-04",
    "payment_status": "PENDING",
    "transmitted": true,
    "delivered": true
  }
}

Use the transmitted and delivered fields to determine transmission and delivery status independently. A successful lookup confirms that status information was retrieved; either field may be false.

09

Update Invoice Payment Status

Replace {IRN} with the existing invoice IRN.

FieldJSON typeRequirement
payment_statusStringRequested status: PENDING, PARTIAL, PAID, or REJECTED
amountNumberRequired when the requested status is PARTIAL
referenceStringOptional payment reference or note

Full-payment request

http
PATCH <NRS_BASE_URL>/api/v1/invoice/update/{IRN}

{
  "payment_status": "PAID",
  "reference": "EXAMPLE-PAYMENT-001"
}

Partial-payment request

json
{
  "payment_status": "PARTIAL",
  "amount": 100000,
  "reference": "EXAMPLE-PARTIAL-001"
}

The examples show alternative payment updates. Submit only transitions permitted by NRS for the invoice's current state.

Success response (NRS reference):

json
{"code": 200, "data": {"ok": true}}

Record the payment status as synchronized after NRS accepts the update. If NRS rejects the request, retain the previously synchronized status.

10

Lifecycle States

These states describe Veridex's processing workflow. The NRS confirmation response provides separate transmission and delivery flags. Temporary processing states may appear while an operation is in progress. Submit only one lifecycle request at a time for a given invoice.

text
draft → validated → signed → transmitted
01
Validate

NRS accepts the invoice data. The IRN was generated before validation and remains associated with the invoice.

state: validated
02
Sign

Fiscal signing and the local signing workflow complete successfully. Veridex then attempts transmission automatically.

state: signed
03
Transmit

Transmission succeeds. Delivery status is determined separately from the NRS confirmation response.

state: transmitted

The automatic transmission attempt may advance the invoice beyond signed before the signing request returns. If signing succeeds but transmission fails, the invoice remains eligible for a transmission retry; signing must not be repeated solely to retry transmission.

State reference

StateMeaningNext action
draftEditable invoiceComplete the invoice and submit it for validation
pending_validationValidation is in progressWait for the result before submitting another lifecycle request
validatedInvoice validation succeededSubmit the validated invoice for signing
pending_signingSigning is in progressWait for the result
signedFiscal signing and local signing completion succeededProceed with transmission
pending_transmitTransmission is in progressWait for the result
transmittedTransmission succeeded; this is the final state in the current local transition mapUse NRS status information to distinguish transmission from delivery
validation_failedInvoice validation failedCorrect the reported errors and validate again
sign_failedThe local signing workflow did not complete; NRS signing may already have succeeded if a subsequent QR-generation step failedReconcile the signing result before retrying
transmit_failedSigning succeeded, but transmission failedRetry transmission without signing again

An IRN identifies an invoice; its presence does not establish that validation, signing, or transmission succeeded. The current Veridex confirmation workflow remains deferred. Do not treat the local transmitted state as proof of NRS delivery confirmation or payment settlement.

11

Errors & Retries

Check the HTTP status and JSON response body for every request. Use any reported field paths and error details to identify the cause of a failure. Error bodies may differ by operation and between the integration service and NRS; the examples below do not define a universal NRS error response.

HTTP status codes

StatusMeaningHandling
400 Bad RequestThe request could not be processed; inspect the error detailsCorrect the request or resolve the reported upstream error
401 UnauthorizedAuthentication is missing, invalid, or expiredRestore valid authentication before retrying
403 ForbiddenThe authenticated caller is not permitted to perform the operationCheck permissions and business access
404 Not FoundThe resource does not exist or is not accessible to the callerCheck the identifier and access scope
409 ConflictThe requested operation conflicts with the invoice's current stateRetrieve the current state and select a permitted action
422 Unprocessable EntityRequest validation or a business rule failedCorrect the reported fields or resolve the business-rule failure
429 Too Many RequestsThe request rate exceeds the permitted limitDelay the retry; observe Retry-After when supplied
503 Service UnavailableA required service is temporarily unavailableApply backoff and reconcile any uncertain prior result

Validation error

This schema-level illustration identifies a missing goods classification using the NRS invoice field path. Exact validation messages depend on the validating service.

json
{
  "message": "The given data was invalid.",
  "errors": {
    "invoice_line.0.hsn_code": [
      "HSN code is required for goods."
    ]
  }
}

Invalid lifecycle transition

Veridex's application error response when an invoice is submitted for signing before validation. This response does not include a retryable field.

json
{
  "code": "INVOICE_STATE_ERROR",
  "message": "Cannot transition from 'draft' to 'pending_signing'"
}

NRS validation failure

Veridex reports upstream API failures using NRS_API_ERROR. The message and details depend on the NRS response; the field-level details below are illustrative.

json
{
  "code": "NRS_API_ERROR",
  "message": "NRS rejected the invoice payload.",
  "details": {
    "field": "invoice_line.0.hsn_code",
    "reason": "The supplied classification code is invalid."
  },
  "retryable": false
}

Temporary service failure

Veridex's application response when NRS cannot be reached.

json
{
  "code": "NRS_CONNECTION_UNAVAILABLE",
  "message": "NRS is temporarily unavailable.",
  "retryable": true
}
12

Security & Privacy

  • • Use HTTPS for all API requests and validate the server certificate.
  • • Store API keys, secrets, and session credentials securely. Restrict access to authorized services and personnel.
  • • Keep credentials out of URLs, source code, public documentation, browser analytics, and application logs.
  • • Include invoice identifiers in URLs only where required by the documented endpoint. Protect access logs that record those paths.
  • • Treat taxpayer identifiers, contact details, invoice data, and downloaded artifacts as confidential business information.
  • • Store downloaded artifacts securely and limit access to authorized users.
  • • Remove sensitive values before recording request or response bodies in diagnostic logs. Do not send confidential payloads to client-side analytics.
13

References