Skip to content

Customer Management

This section describes all the API endpoints related to customer management.

Customer Creation

To create a new customer, the customers endpoint is used.

POST https://stage.provider-service.dev.aex.systems/customers

Request Parameters:

  • first_name (string, required): The customer first name.
  • last_name (string, required): The customer last name.
  • email (string, required): The customer email address.
  • mobile_number (string, required): The customer mobile phone number.
  • fno_opt_in (datetime, optional): Date set when the customer opts-in to receiving FNO communications.
  • isp_opt_in (datetime, optional): Date set when the customer opts-in to receiving ISP communications.

file_type_swagger Create Customer

Example Payload
1
2
3
4
5
6
{
  "first_name": "Joe",
  "last_name": "Hobbit",
  "email": "joeh@mail.com",
  "mobile_number": "0612345789"
}
On successful creation, HTTP response Status Code 201 is returned, with the Location header indicating the API route to accessing the new customer.

Customer Update

The API provides a PUT endpoint that allows the ISP to update the details of an individual customer linked to an ISP.

PUT https://stage.provider-service.dev.aex.systems/customers/{customer_id}

file_type_swagger Update Customer

Example Payload
1
2
3
4
{
  "first_name": "Bongani",
  "last_name": "Madolo"
}
Example Response
1
2
3
4
5
6
7
8
9
{
  "id": "5a58c622-2365-469d-a8ec-000128be194e",
  "first_name": "Bongani",
  "last_name": "Madolo",
  "email": "Imathada@gmail.com",
  "mobile_number": "0681464774",
  "fno_opt_in": null,
  "isp_opt_in": null
}

The API provides two customer filter endpoints, one to filter by email address, and another to filter by the customer unique identifier (ID) on the system.

List Customers

To get a paged list of customers, the endpoint below can be used. Only customers that are not currently linked to any ISP or those linked to the ISP associated with the security token shall be returned.

GET https://stage.provider-service.dev.aex.systems/customers?emailAddress={email_address}

Request Parameters

  • email_address (string, optional): The email address to filter by. When this parameter is provided, only customers with a matching email address will be returned.
  • page (int, optional): The page number want to display. If a value is not provided, the default value is 1.
  • page_size (int, optional): The maximum number of records to include per page.

file_type_swagger List Customers

Get Single Customer

To get a single customer using its unique system identifier, the endpoint below can be used. The customer record will only be returned if it is not linked to a service or if it's linked to a service provided by the ISP associated with the security token.

GET https://stage.provider-service.dev.aex.systems/customers/{customer_id}

Request Parameters

  • customer_id (uuid, required): The customer unique identifier

file_type_swagger Get Customer

Example Response
{
  "id": "5a58c622-2365-469d-a8ec-000128be194e",
  "first_name": "Solomon",
  "last_name": "Mathada",
  "email": "Imathada@gmail.com",
  "mobile_number": "0681464774",
  "fno_opt_in": null,
  "isp_opt_in": null,
  "physical_address": null,
  "billing_address": null
}