POST api/v1/CustomerCreate
Create a new customer account
Request Information
URI Parameters
None.
Body Parameters
CustomerCreateParamsName | Description | Type | Additional information |
---|---|---|---|
apiKey |
Please contact Caliq support to get your key |
string |
Required |
ChannelID |
List of channels can be retrieved via API |
integer |
Required |
AccountNo |
User entered unique customer account number. If auto numbering in Caliq is live leave blank |
string |
Required Max length: 10 |
CompanyName |
Company name. If this is a person leave blank otherwise account will be created as a company |
string |
Max length: 40 |
Line1 | string |
Required Max length: 50 |
|
Line2 | string |
Max length: 50 |
|
Line3 | string |
Max length: 50 |
|
Town | string |
Max length: 50 |
|
County | string |
Max length: 25 |
|
Postcode | string |
Max length: 15 |
|
Country |
Currency code from the currency list in ISO3 format |
string |
Required Max length: 3 |
AllowDeliveries |
Can orders be delivered to this address? |
boolean |
Required |
AllowInvoices |
Can invoices be sent to this address? |
boolean |
Required |
Title |
Mr, Mrs etc Can be blank |
string |
Max length: 6 |
Firstname | string |
Required Max length: 20 |
|
Surname | string |
Required Max length: 30 |
|
TelephoneNo | string |
Max length: 20 |
|
MobileNo | string |
Max length: 20 |
|
Must correspond to the email used to identify this customer on the web site |
string |
Required Max length: 70 |
|
VATNumber |
VAT registration number |
string |
Max length: 30 |
EORI |
Customer EORI number |
string |
Max length: 20 |
Currency |
Currency that the order values are in |
string |
Required Max length: 3 |
CustomerServiceLevel |
From customer service level API call - leave null/0 to use default else specify ID |
integer |
None. |
CustomerCategory |
Customer category can be set if required. List can be retrieved via API call |
string |
Max length: 4 |
Request Formats
application/json, text/json
{ "apiKey": "sample string 1", "ChannelID": 2, "AccountNo": "sample string 3", "CompanyName": "sample string 4", "Line1": "sample string 5", "Line2": "sample string 6", "Line3": "sample string 7", "Town": "sample string 8", "County": "sample string 9", "Postcode": "sample string 10", "Country": "sample string 11", "AllowDeliveries": true, "AllowInvoices": true, "Title": "sample string 14", "Firstname": "sample string 15", "Surname": "sample string 16", "TelephoneNo": "sample string 17", "MobileNo": "sample string 18", "Email": "sample string 19", "VATNumber": "sample string 20", "EORI": "sample string 21", "Currency": "sample string 22", "CustomerServiceLevel": 23, "CustomerCategory": "sample string 24" }
application/xml, text/xml
<CustomerCreateParams xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <apiKey>sample string 1</apiKey> <ChannelID>2</ChannelID> <AccountNo>sample string 3</AccountNo> <CompanyName>sample string 4</CompanyName> <Line1>sample string 5</Line1> <Line2>sample string 6</Line2> <Line3>sample string 7</Line3> <Town>sample string 8</Town> <County>sample string 9</County> <Postcode>sample string 10</Postcode> <Country>sample string 11</Country> <AllowDeliveries>true</AllowDeliveries> <AllowInvoices>true</AllowInvoices> <Title>sample string 14</Title> <Firstname>sample string 15</Firstname> <Surname>sample string 16</Surname> <TelephoneNo>sample string 17</TelephoneNo> <MobileNo>sample string 18</MobileNo> <Email>sample string 19</Email> <VATNumber>sample string 20</VATNumber> <EORI>sample string 21</EORI> <Currency>sample string 22</Currency> <CustomerServiceLevel>23</CustomerServiceLevel> <CustomerCategory>sample string 24</CustomerCategory> </CustomerCreateParams>
Response Information
Resource Description
Returns:
200 OK Returns account id and account number of the customer created and address id, or error list if failed
400 Bad Request - parameters supplied cannot be properly interpreted
401 Not Authorised if supplied api key is not valid
503 Service Unavailable
Messages returned for error: 1,9,29,30,31,32,34,35,37,38,39,40
Name | Description | Type | Additional information |
---|---|---|---|
CustomerCreateData | CustomerCreateData |
None. |
Response Formats
application/json, text/json
{ "CustomerCreateData": { "OK": true, "AccountID": 2, "AccountNo": "sample string 3", "AddressID": 4, "ContactID": 5, "CustomerCreateIssues": [ { "ID": 1, "Message": "sample string 2", "ExtraData": "sample string 3" }, { "ID": 1, "Message": "sample string 2", "ExtraData": "sample string 3" } ] } }
application/xml, text/xml
<CustomerCreateResults xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <CustomerCreateData> <OK>true</OK> <AccountID>2</AccountID> <AccountNo>sample string 3</AccountNo> <AddressID>4</AddressID> <ContactID>5</ContactID> <CustomerCreateIssues> <CustomerCreateIssue> <ID>1</ID> <Message>sample string 2</Message> <ExtraData>sample string 3</ExtraData> </CustomerCreateIssue> <CustomerCreateIssue> <ID>1</ID> <Message>sample string 2</Message> <ExtraData>sample string 3</ExtraData> </CustomerCreateIssue> </CustomerCreateIssues> </CustomerCreateData> </CustomerCreateResults>