Address Book


Endpoint

The base url is:

@bulk_base/api/v1

Add Contact

Method URI
POST /address-book/contacts

Request Params

Param Type Description
phone string(required) Contact Phone Number
name string(optional) Contact Names
email string(optional) Contact Email Address

Sample Request

{
    "name": "Test Contact",
    "email": "example@example.com",
    "phone": "0716XXXXXX"
}

Sample Success Response

StatusCode 200

Content

{
    "status": true,
    "data": {
        "id": 1,
        "name": "Test Contact",
        "email": "example@example.com",
        "phone": "0716XXXXXX"
        "client_id": 1,
        "created_by": 2,
        "unique_trace": "Unique_trace",
        "updated_at": "2020-01-16 11:05:12",
        "created_at": "2020-01-16 11:05:12",
    }
}

Delete Contact

Method URI
DELETE /address-book/contacts/{contact_id}

{info} Replace {contact_id} with the id that was received when creating the contact

Sample Success Response

StatusCode 200

Content

{
    "status": true,
    "message": "Contact Successfully Deleted!"
}

Add Group

Method URI
POST /address-book/groups

Request Params

Param Type Description
name string(required) Name of the Group

Sample Request

{
    "name": "Group 1",
}

Sample Success Response

StatusCode 200

Content

{
    "status": true,
    "data": {
        "id": 1,
        "client_id": 1,
        "created_by": 2,
        "updated_at": "2020-01-16 10:15:22",
        "created_at": "2020-01-16 10:15:22",
        "date_created": "16 Jan, 2020",
        "contacts_count": 0,
        "first_contact": null
    }
}

Delete Group

Method URI
DELETE /address-book/groups/{group_id}

{info} Replace {group_id} with the id that was received when creating the group

Sample Success Response

StatusCode 200

Content

{
    "status": true,
    "message": "Group and all associated contacts Successfully deleted!"
}