For the complete documentation index, see llms.txt. This page is also available as Markdown.

Get Document Request

Retrieve a single document request with full context, items, and generation status.

/regulatory-documents/request/:request_id

GET https://api.terminal.africa/v1/regulatory-documents/request/:request_id

Path Parameters

Name
Type
Description

request_id*

String

Document request id. e.g. DRQ-ABC1234567.

Headers

Name
Type
Description

Authorization*

String

Set value to Bearer SECRET_KEY

Content-Type*

String

Set value to application/json

{
    "status": true,
    "message": "Document request retrieved successfully",
    "data": {
        "request_id": "DRQ-ABC1234567",
        "user_id": "USR-1234567890",
        "source": "invoice",
        "status": "completed",
        "file_url": "https://cdn.example.com/invoices/commercial-invoice-001.pdf",
        "currency": "USD",
        "carrier_slug": "dhl-ng",
        "carrier_logo": "https://cdn.terminal.africa/carriers/dhl.png",
        "tracking_number": "1Z999AA10123456784",
        "context": {
            "pickup_address": {
                "first_name": "Ada",
                "last_name": "Obi",
                "line1": "1 Marina",
                "city": "Lagos",
                "state": "Lagos",
                "country": "NG",
                "zip": "100001",
                "phone": "+2348000000000",
                "email": "ada@example.com"
            },
            "delivery_address": {
                "first_name": "John",
                "last_name": "Doe",
                "line1": "123 Main St",
                "city": "New York",
                "state": "NY",
                "country": "US",
                "zip": "10001",
                "phone": "+15550100",
                "email": "john@example.com"
            },
            "items": [
                {
                    "item_id": "DRI-ITEM001",
                    "description": "Roasted coffee",
                    "hs_code": "0901.21",
                    "value": 10,
                    "currency": "USD",
                    "quantity": 1,
                    "weight": 1,
                    "weight_unit": "kg",
                    "manufacturer_country": "NG",
                    "document_types": ["FDA"],
                    "regulatory_profiles": {}
                }
            ]
        },
        "validation": {
            "ok": true,
            "items_missing_hs_codes": []
        },
        "available_documents": [
            {
                "type": "FDA",
                "name": "FDA Prior Notice",
                "amount": 1.67,
                "currency": "USD",
                "free": false,
                "automated": true
            }
        ],
        "purchased_documents": [
            {
                "type": "FDA",
                "name": "FDA Prior Notice",
                "document_url": "https://cdn.terminal.africa/documents/DOC-XYZ789.pdf",
                "document_id": "DOC-XYZ789",
                "status": "completed",
                "paid": true,
                "amount": 1.67,
                "currency": "USD",
                "automated": true,
                "error": ""
            }
        ],
        "payment": {
            "amount": 1.67,
            "currency": "USD",
            "free": false,
            "transaction_id": "TXN-1234567890",
            "charged_at": "2026-09-01T10:05:00.000Z"
        },
        "generation": {
            "generated": [
                {
                    "type": "FDA",
                    "document_id": "DOC-XYZ789",
                    "document_url": "https://cdn.terminal.africa/documents/DOC-XYZ789.pdf",
                    "status": "completed"
                }
            ],
            "skipped": [],
            "pending": []
        },
        "documents": [],
        "created_at": "2026-09-01T10:00:00.000Z",
        "updated_at": "2026-09-01T10:10:00.000Z"
    }
}

Last updated

Was this helpful?