Get Customers
This method returns the list of customers. By default, it preserves the legacy ordering. If SortByCreatedDescending=true, the newest customers will be shown first.
This method is accessed by https://api.cryptolens.io/api/customer/GetCustomers
Parameters
| Parameter |
Description |
Remarks |
| Search |
By default, if either the Name, Company, Email or the Secret matches the search string, it will be returned. If IncludeIdInSearch=true, then a numeric Search value can also match the customer Id.
|
optional |
| IncludeIdInSearch |
When set to true, a numeric Search value can also match the customer Id. By default, this is false to preserve the existing Search behavior.
|
optional. default is false. |
| CustomerId |
If this is set, you can use the CustomerId field to find a specific customer based on their integer Id. This remains a dedicated exact-Id filter and is independent from the opt-in Search behavior above.
|
optional |
| Limit |
Specifies how many customers will be returned. If not set, all customers will be returned. |
optional. disabled by default. |
| SortByCreatedDescending |
When set to true, customers are ordered by creation date descending, with newer customers returned first. By default, this is false to preserve the existing paging and ordering behavior.
|
optional. default is false. |
| ModelVersion |
The model that will be returned. In comparison to method version, this only affects what fields and information will be returned and does not
impact the way the method works. A changelog can be found in the end of this page.
|
optional. by default, it's 1. |
| v |
Method version. |
optional. by default, it's 1. |
Results
| Parameter |
Description |
Remarks |
| Customers |
A list of Customer objects. |
always returned |
| ResellerCustomers |
A list of Customer (extended) objects. These customers belong to a different user but you can still edit some of the fields. |
always returned |
| VisibleCustomers |
A list of Customer (customer extended) objects. These customers belong to a different user but you can still view them. |
always returned |
| Result |
This is either 0(=success) or 1(=error). |
always returned |
| Message |
The message that provides additional information about the result.
|
always returned. |
Example results
{"customers":[{"id":1234,"name":"Bob","email":"bob@example.com","companyName":"SKM","created":"2015-09-04T16:11:14.453"}],"result":0,"message":null}
Errors
Model Versions
This changelog list changes of the returned fields given the model version.
- All customer objects that are returned will have the same fields as described here.
- The original model.