Skip to content

Latest commit

 

History

History
148 lines (108 loc) · 4.77 KB

CustomersApi.md

File metadata and controls

148 lines (108 loc) · 4.77 KB

IO.Swagger.Api.CustomersApi

All URIs are relative to https://api.facestore.local/v1

Method HTTP request Description
GetCustomerById GET /customers/{id}/
GetCustomers GET /customers

GetCustomerById

List GetCustomerById (long? id, List includes)

Returns all customers from the system that the user has access to ### Includes You can give the following values on includes parameter: orders, groups

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class GetCustomerByIdExample
    {
        public void main()
        {
            
            // Configure API key authorization: APIKeyHeader
            Configuration.Default.ApiKey.Add("APIToken", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("APIToken", "Bearer");

            var apiInstance = new CustomersApi();
            var id = 789;  // long? | ID of customer
            var includes = new List<string>(); // List<string> | Include associated objects within response (optional) 

            try
            {
                List&lt;Customer&gt; result = apiInstance.GetCustomerById(id, includes);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomersApi.GetCustomerById: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
id long? ID of customer
includes List Include associated objects within response [optional]

Return type

List

Authorization

APIKeyHeader

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetCustomers

List GetCustomers (List includes, int? limit, List orderBy)

Returns all customers from the system that the user has access to ### Includes You can give the following values on includes parameter: orders, groups

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class GetCustomersExample
    {
        public void main()
        {
            
            // Configure API key authorization: APIKeyHeader
            Configuration.Default.ApiKey.Add("APIToken", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("APIToken", "Bearer");

            var apiInstance = new CustomersApi();
            var includes = new List<string>(); // List<string> | Include associated objects within response (optional) 
            var limit = 56;  // int? | max records to return (optional) 
            var orderBy = new List<string>(); // List<string> | Specify the field to be sorted, examples:  - `?order_by=id|desc` - `?order_by=updated_at|desc,position|asc`  (optional) 

            try
            {
                List&lt;Customer&gt; result = apiInstance.GetCustomers(includes, limit, orderBy);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CustomersApi.GetCustomers: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
includes List Include associated objects within response [optional]
limit int? max records to return [optional]
orderBy List Specify the field to be sorted, examples: - `?order_by=id desc` - `?order_by=updated_at

Return type

List

Authorization

APIKeyHeader

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]