Creating a customer with email and password

Please make sure you read the Conventions before continuing with this guide.

Requirements.

You will need an X-API-KEY for all steps.

1) Create a customer.

This endpoint has been updated to allow you to create a customer with an email and password in one step. Once step 1 is completed, the customer will be automatically sent an activation email. When they have clicked on the link in that email, their account will be activated.

You will interact with the /accounts/customer endpoint of the Accounts Bucket to create a customer.

When successful, a customer json object will be returned.

Response :

{
    "customerNumber": "123-123-123",
    "accountId": "55555xx55yy55z000000000",
    "agencyId": "",
    "firstName": "Firstname-Test",
    "lastName": "Lastname-Test",
    "email": "test@betterez.com",
    "phone": "",
    "street": "",
    "city": "",
    "countryId": "",
    "country": "",
    "province": "",
    "zip": "",
    "optIn": false,
    "activeCustomerAccount": false,
    "credentials": {
        "emailAndPwd": {}
    },
    "mergedFrom": [],
    "mergedTo": "",
    "cloutCategory": "Newbie",
    "clout": {
        "p0000_00": {
            "purchases": 0,
            "travels": 0,
            "purchasesValue": 0,
            "travelsValue": 0
        }
    },
    "deleted": false,
    "createdAt": {
        "value": "2017-11-29T16:38:08.533Z",
        "offset": 0
    },
    "updatedAt": {
        "value": "2017-11-29T16:38:08.533Z",
        "offset": 0
    },
    "_id": "5a466f555555df550b555555"
}