Address

POST /v1/form/update

Below is an example illustrating the consumable format of AddressComponent. The 'NEXT' status indicates that you haven't reached the end of the form yet. Each question is uniquely identified by an ID stored in 'questionId'.

{
    "status": "NEXT",
    "refId": "SLH-4UN2LPTW0W3J",
    "question": {
        "questionId": "26351eb6-3bd1-475c-b897-680825d94127",
        "question": "What is your home address?",
        "kind": "AddressComponent",
        "settings": {
            "requiredFields": [
                "addressline1",
                "state",
                "country"
            ]
        }
    },
    "review": [],
    "message": null,
    "invoice": {
        "title": "Demo Cards API 2",
        "quantity": 1,
        "currency": "XOF",
        "totalCost": 1000.0
    }
}

Response to the question

Address format requires that only fields names present in the requiredField array be part of the values object

Headers

Name
Value

Content-Type

application/json

CLIENT_ID

<client id>

Body

In addition to the API keys specified in the Headers, ensure to include the eServiceId, refId, questionId, from and to. Upon a successful request, you will receive the next question. You'll recognize reaching the end of the form when the status is 'COMPLETED'.

Field
Format

addressline1

string

addressline2

string

area

string

attentionto

string

block

string

building

string

city

string

country

string

door

string

floor

string

lot

string

municipality

string

neighborhood

string

pobox

string

plot

string

state

string

street

string

what3words

string

zipcode

string

Example

{
    "eServiceId": "6646403efc0445aabb9e9b6d",
    "refId": "SLH-4UN2LPTW0W3J",
    "questionId": "26351eb6-3bd1-475c-b897-680825d94127",
    "values": {
        "addressline1": "1234 Cocody st",
        "state":"Abidjan",
        "country":"Cote D'Ivoire"
    }
}

Last updated