POST v1/customers/search
Search for available customers using the search filters.
Request Information
URI Parameters
None.
Body Parameters
CustomerSearchParametersName | Description | Type | Additional information |
---|---|---|---|
Name | string |
None. |
|
Number | string |
None. |
|
ContactName | string |
None. |
|
Phone | string |
None. |
|
Address |
Specifies the address |
string |
None. |
Status |
Searches by the customer status (can be one or more of the following, 1 - Prospect, 2 - Active, 3 - Deleted, 4 - Lost) |
Collection of integer |
None. |
DateCreatedRange |
The date and time (in company time zone) when the customer was created. |
DateRange |
None. |
LastUpdatedDateRange |
The date and time (in company time zone) when the customer was last updated. |
DateRange |
None. |
PageIndex |
zero-based page number |
integer |
None. |
PageSize |
Default value is 100 |
integer |
Range: inclusive between 1 and 1000 |
SortExpression |
Specify the field name to sort the result set by. It can be one of the fields returned by the search. |
string |
None. |
SortOrder |
Specify Sort Order. Ascending=1, Descending=2. Default value is 1 (Ascending) |
integer |
Range: inclusive between 1 and 2 |
Request Formats
application/json, text/json
Sample:
{ "name": "sample string 1", "number": "sample string 2", "contactName": "sample string 3", "phone": "sample string 4", "address": "sample string 5", "status": [ 1, 2 ], "dateCreatedRange": null, "lastUpdatedDateRange": null, "pageIndex": 6, "pageSize": 7, "sortExpression": "sample string 8", "sortOrder": 9 }
application/xml, text/xml
Sample:
<CustomerSearchParameters xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BAPI.Models.CRM"> <PageIndex xmlns="http://schemas.datacontract.org/2004/07/BAPI.Models">6</PageIndex> <PageSize xmlns="http://schemas.datacontract.org/2004/07/BAPI.Models">7</PageSize> <SortExpression xmlns="http://schemas.datacontract.org/2004/07/BAPI.Models">sample string 8</SortExpression> <SortOrder xmlns="http://schemas.datacontract.org/2004/07/BAPI.Models">9</SortOrder> <Address>sample string 5</Address> <ContactName>sample string 3</ContactName> <DateCreatedRange xmlns:d2p1="http://schemas.datacontract.org/2004/07/BAPI.Models" i:nil="true" /> <LastUpdatedDateRange xmlns:d2p1="http://schemas.datacontract.org/2004/07/BAPI.Models" i:nil="true" /> <Name>sample string 1</Name> <Number>sample string 2</Number> <Phone>sample string 4</Phone> <Status xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:int>1</d2p1:int> <d2p1:int>2</d2p1:int> </Status> </CustomerSearchParameters>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
SearchResultOfCustomerSearchResultName | Description | Type | Additional information |
---|---|---|---|
TotalCount | integer |
None. |
|
Data | Collection of CustomerSearchResult |
None. |
Response Formats
application/json, text/json
Sample:
{ "totalCount": 1, "data": [ { "id": 1, "name": "sample string 2", "number": "sample string 3", "status": { "id": 1, "name": "sample string 2" }, "customerSince": "2024-04-20T00:25:35.8852694-04:00", "fullAddress": "sample string 4", "countryDialCode": 5, "phoneNumber": "sample string 6", "phoneExtension": "sample string 7", "phoneNumberTypeId": 64, "paymentTerms": { "id": 1, "name": "sample string 2" }, "dateCreated": "2024-04-20T00:25:35.8852694-04:00", "lastUpdatedDate": "2024-04-20T00:25:35.8852694-04:00" }, { "id": 1, "name": "sample string 2", "number": "sample string 3", "status": { "id": 1, "name": "sample string 2" }, "customerSince": "2024-04-20T00:25:35.8852694-04:00", "fullAddress": "sample string 4", "countryDialCode": 5, "phoneNumber": "sample string 6", "phoneExtension": "sample string 7", "phoneNumberTypeId": 64, "paymentTerms": { "id": 1, "name": "sample string 2" }, "dateCreated": "2024-04-20T00:25:35.8852694-04:00", "lastUpdatedDate": "2024-04-20T00:25:35.8852694-04:00" } ] }
application/xml, text/xml
Sample:
<SearchResultOfCustomerSearchResultJSBqjE6T xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BAPI.Models"> <Data xmlns:d2p1="http://schemas.datacontract.org/2004/07/BAPI.Models.CRM"> <d2p1:CustomerSearchResult> <d2p1:CountryDialCode>5</d2p1:CountryDialCode> <d2p1:CustomerSince>2024-04-20T00:25:35.8852694-04:00</d2p1:CustomerSince> <d2p1:DateCreated>2024-04-20T00:25:35.8852694-04:00</d2p1:DateCreated> <d2p1:FullAddress>sample string 4</d2p1:FullAddress> <d2p1:Id>1</d2p1:Id> <d2p1:LastUpdatedDate>2024-04-20T00:25:35.8852694-04:00</d2p1:LastUpdatedDate> <d2p1:Name>sample string 2</d2p1:Name> <d2p1:Number>sample string 3</d2p1:Number> <d2p1:PaymentTerms xmlns:d4p1="http://schemas.datacontract.org/2004/07/Striven.Common.Models"> <d4p1:_x003C_Id_x003E_k__BackingField>1</d4p1:_x003C_Id_x003E_k__BackingField> <d4p1:_x003C_Name_x003E_k__BackingField>sample string 2</d4p1:_x003C_Name_x003E_k__BackingField> </d2p1:PaymentTerms> <d2p1:PhoneExtension>sample string 7</d2p1:PhoneExtension> <d2p1:PhoneNumber>sample string 6</d2p1:PhoneNumber> <d2p1:PhoneNumberTypeId>64</d2p1:PhoneNumberTypeId> <d2p1:Status xmlns:d4p1="http://schemas.datacontract.org/2004/07/Striven.Common.Models"> <d4p1:_x003C_Id_x003E_k__BackingField>1</d4p1:_x003C_Id_x003E_k__BackingField> <d4p1:_x003C_Name_x003E_k__BackingField>sample string 2</d4p1:_x003C_Name_x003E_k__BackingField> </d2p1:Status> </d2p1:CustomerSearchResult> <d2p1:CustomerSearchResult> <d2p1:CountryDialCode>5</d2p1:CountryDialCode> <d2p1:CustomerSince>2024-04-20T00:25:35.8852694-04:00</d2p1:CustomerSince> <d2p1:DateCreated>2024-04-20T00:25:35.8852694-04:00</d2p1:DateCreated> <d2p1:FullAddress>sample string 4</d2p1:FullAddress> <d2p1:Id>1</d2p1:Id> <d2p1:LastUpdatedDate>2024-04-20T00:25:35.8852694-04:00</d2p1:LastUpdatedDate> <d2p1:Name>sample string 2</d2p1:Name> <d2p1:Number>sample string 3</d2p1:Number> <d2p1:PaymentTerms xmlns:d4p1="http://schemas.datacontract.org/2004/07/Striven.Common.Models"> <d4p1:_x003C_Id_x003E_k__BackingField>1</d4p1:_x003C_Id_x003E_k__BackingField> <d4p1:_x003C_Name_x003E_k__BackingField>sample string 2</d4p1:_x003C_Name_x003E_k__BackingField> </d2p1:PaymentTerms> <d2p1:PhoneExtension>sample string 7</d2p1:PhoneExtension> <d2p1:PhoneNumber>sample string 6</d2p1:PhoneNumber> <d2p1:PhoneNumberTypeId>64</d2p1:PhoneNumberTypeId> <d2p1:Status xmlns:d4p1="http://schemas.datacontract.org/2004/07/Striven.Common.Models"> <d4p1:_x003C_Id_x003E_k__BackingField>1</d4p1:_x003C_Id_x003E_k__BackingField> <d4p1:_x003C_Name_x003E_k__BackingField>sample string 2</d4p1:_x003C_Name_x003E_k__BackingField> </d2p1:Status> </d2p1:CustomerSearchResult> </Data> <TotalCount>1</TotalCount> </SearchResultOfCustomerSearchResultJSBqjE6T>