POST api/customers
Adds an customer
Request Information
URI Parameters
None.
Body Parameters
CustomerPostRequest| Name | Description | Type | Additional information |
|---|---|---|---|
| CustomerNo | integer |
None. |
|
| CustomerNo | integer |
Required |
|
| BranchId | integer |
None. |
|
| SearchCode | string |
Required Max length: 10 Min length: 1 |
|
| Name | string |
Required Max length: 50 Min length: 1 |
|
| OrgNo | string |
Max length: 30 |
|
| Address1 | string |
Max length: 100 |
|
| Address2 | string |
Max length: 100 |
|
| Address3 | string |
Max length: 100 |
|
| PostalCode | string |
Max length: 10 |
|
| Town | string |
Max length: 50 |
|
| CountryId | string |
Required Max length: 2 |
|
| BoardHome | string |
Max length: 50 |
|
| Phone1 | string |
Max length: 50 |
|
| Phone2 | string |
Max length: 50 |
|
| WebSite | string |
Max length: 100 |
|
| string |
Max length: 50 |
||
| Note | string |
Max length: 4000 |
|
| PreferredCultureId | string |
Max length: 5 |
|
| VatRegistrationNumber | string |
Max length: 50 |
|
| CustomerCategoryId1 | integer |
None. |
|
| CustomerCategoryId2 | integer |
None. |
|
| ReferencePerson | string |
Max length: 50 |
|
| ContactPerson | string |
Max length: 50 |
|
| DistrictId | integer |
None. |
|
| PaysVAT | boolean |
None. |
|
| BreakdownServiceTypeId | integer |
None. |
|
| YourReference | string |
Max length: 20 |
|
| RequisitionOrderNumber | string |
Max length: 40 |
|
| InternalWorkingOrderNumber | string |
Max length: 40 |
|
| ParentCustomerNo | integer |
None. |
|
| SalesPerson | string |
Max length: 128 |
|
| Export | boolean |
Required |
|
| WithinEU | boolean |
Required |
|
| Inactive | boolean |
Required |
|
| TransportationScheduleId | integer |
None. |
|
| IsCompany | boolean |
None. |
|
| GDPRConsentDate | date |
None. |
|
| CustomerType | string |
Max length: 256 |
|
| DocumentPath | string |
Max length: 200 |
|
| ExternalReference | string |
Max length: 50 |
|
| GlobalLocationNumber | string |
Max length: 13 Min length: 13 |
|
| InterestInvoice | boolean |
None. |
|
| IsCashCustomer | boolean |
None. |
|
| RegionId | integer |
None. |
Remarks
None.
Example
None.
Request Formats
application/json, text/json
Sample:
{
"CustomerNo": 1,
"BranchId": 1,
"SearchCode": "sample string 2",
"Name": "sample string 3",
"OrgNo": "sample string 4",
"Address1": "sample string 5",
"Address2": "sample string 6",
"Address3": "sample string 7",
"PostalCode": "sample string 8",
"Town": "sample string 9",
"CountryId": "sample string 10",
"BoardHome": "sample string 11",
"Phone1": "sample string 12",
"Phone2": "sample string 13",
"WebSite": "sample string 14",
"Email": "sample string 15",
"Note": "sample string 16",
"PreferredCultureId": "sample string 17",
"VatRegistrationNumber": "sample string 18",
"CustomerCategoryId1": 1,
"CustomerCategoryId2": 1,
"ReferencePerson": "sample string 19",
"ContactPerson": "sample string 20",
"DistrictId": 1,
"PaysVAT": true,
"BreakdownServiceTypeId": 1,
"YourReference": "sample string 22",
"RequisitionOrderNumber": "sample string 23",
"InternalWorkingOrderNumber": "sample string 24",
"ParentCustomerNo": 1,
"SalesPerson": "sample string 25",
"Export": true,
"WithinEU": true,
"Inactive": true,
"TransportationScheduleId": 1,
"IsCompany": true,
"GDPRConsentDate": "2026-01-21 22:50:35",
"CustomerType": "sample string 29",
"DocumentPath": "sample string 30",
"ExternalReference": "sample string 31",
"GlobalLocationNumber": "sample string 32",
"InterestInvoice": true,
"IsCashCustomer": true,
"RegionId": 1
}
application/xml, text/xml
Sample:
<CustomerPostRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Compilator.DDAPI.DTO.Business"> <Address1>sample string 5</Address1> <Address2>sample string 6</Address2> <Address3>sample string 7</Address3> <BoardHome>sample string 11</BoardHome> <BranchId>1</BranchId> <BreakdownServiceTypeId>1</BreakdownServiceTypeId> <ContactPerson>sample string 20</ContactPerson> <CountryId>sample string 10</CountryId> <CustomerCategoryId1>1</CustomerCategoryId1> <CustomerCategoryId2>1</CustomerCategoryId2> <CustomerNo xmlns:d2p1="http://www.w3.org/2001/XMLSchema" i:type="d2p1:long">1</CustomerNo> <CustomerType>sample string 29</CustomerType> <DistrictId>1</DistrictId> <DocumentPath>sample string 30</DocumentPath> <Email>sample string 15</Email> <Export>true</Export> <ExternalReference>sample string 31</ExternalReference> <GDPRConsentDate>2026-01-21T22:50:35.509569+01:00</GDPRConsentDate> <GlobalLocationNumber>sample string 32</GlobalLocationNumber> <Inactive>true</Inactive> <InterestInvoice>true</InterestInvoice> <InternalWorkingOrderNumber>sample string 24</InternalWorkingOrderNumber> <IsCashCustomer>true</IsCashCustomer> <IsCompany>true</IsCompany> <Name>sample string 3</Name> <Note>sample string 16</Note> <OrgNo>sample string 4</OrgNo> <ParentCustomerNo>1</ParentCustomerNo> <PaysVAT>true</PaysVAT> <Phone1>sample string 12</Phone1> <Phone2>sample string 13</Phone2> <PostalCode>sample string 8</PostalCode> <PreferredCultureId>sample string 17</PreferredCultureId> <ReferencePerson>sample string 19</ReferencePerson> <RegionId>1</RegionId> <RequisitionOrderNumber>sample string 23</RequisitionOrderNumber> <SalesPerson>sample string 25</SalesPerson> <SearchCode>sample string 2</SearchCode> <Town>sample string 9</Town> <TransportationScheduleId>1</TransportationScheduleId> <VatRegistrationNumber>sample string 18</VatRegistrationNumber> <WebSite>sample string 14</WebSite> <WithinEU>true</WithinEU> <YourReference>sample string 22</YourReference> <CustomerNo xmlns:d2p1="http://www.w3.org/2001/XMLSchema" i:type="d2p1:long">1</CustomerNo> </CustomerPostRequest>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
CustomerPostResponse| Name | Description | Type | Additional information |
|---|---|---|---|
| Errors | Collection of PostCustomerError |
None. |
|
| Success | boolean |
None. |
|
| CustomerNumber | integer |
None. |
Response Formats
application/json, text/json
Sample:
{
"Errors": [
{
"ErrorCode": 1,
"ErrorMessage": "sample string 1"
},
{
"ErrorCode": 1,
"ErrorMessage": "sample string 1"
}
],
"Success": true,
"CustomerNumber": 1
}
application/xml, text/xml
Sample:
<CustomerPostResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Compilator.DDAPI.DTO.Business">
<CustomerNumber>1</CustomerNumber>
<Errors>
<PostCustomerError>
<ErrorCode>InternalServerError</ErrorCode>
<ErrorMessage>sample string 1</ErrorMessage>
</PostCustomerError>
<PostCustomerError>
<ErrorCode>InternalServerError</ErrorCode>
<ErrorMessage>sample string 1</ErrorMessage>
</PostCustomerError>
</Errors>
<Success>true</Success>
</CustomerPostResponse>