# Request and Response

## Get products and its information from the catalog

<mark style="color:blue;">`GET`</mark> `https://api.alephcrm.com/v2/products`

#### Query Parameters

| Name                                         | Type    | Description    |
| -------------------------------------------- | ------- | -------------- |
| API\_KEY<mark style="color:red;">\*</mark>   | String  | (default=none) |
| accountId <mark style="color:red;">\*</mark> | Integer | (default=none) |
| SKU<mark style="color:red;">\*</mark>        | String  | (default=none) |
| brand                                        | String  | (default=none) |
| ownCode                                      | String  | (default=none) |
| priceListId                                  | Integer | (default=none) |
| dateUpdatedFrom                              | Date    | (default=none) |
| types                                        | String  | (default=none) |
| catalogStatus                                | String  | (default=none) |
| sort                                         | String  | (default=ID)   |
| offset                                       | Integer | (default=0)    |
| limit                                        | Integer | (default=100)  |

{% tabs %}
{% tab title="200: OK Array of Products" %}

```json
{
    "Paging": {
        "Limit": integer,
        "Offset": integer,
        "Total": integer
    },
    "Total": integer,
    "Results": [ProductCatalogType]
}
```

{% endtab %}

{% tab title="206: Partial Content Array of Products" %}

```json
{
    "Paging": {
        "Limit": integer,
        "Offset": integer,
        "Total": integer
    },
    "Total": integer,
    "Results": [ProductCatalogType]
}json
```

{% endtab %}

{% tab title="400: Bad Request {"Status": integer, "Message": string}" %}

{% endtab %}

{% tab title="401: Unauthorized {"Status": integer, "Message": string}" %}

{% endtab %}

{% tab title="403: Forbidden {"Status": integer, "Message": string}" %}

{% endtab %}

{% tab title="404: Not Found {"Status": integer, "Message": string}" %}

{% endtab %}

{% tab title="500: Internal Server Error string" %}

{% endtab %}

{% tab title="412: Precondition Failed {"Status": integer, "Message": string}" %}

{% endtab %}

{% tab title="416: Range Not Satisfiable {"Status": integer, "Message": string}" %}

{% endtab %}

{% tab title="429: Too Many Requests {"Status": integer, "Message": string}" %}

{% endtab %}
{% endtabs %}

## Parameters details

### API\_KEY

The API\_KEY that was provided.

### accountId

The Alephee account ID of the orders you are trying to get.

### SKU

Filters products which SKU equals the provided one

### Brand

Filters products which brand equals the provided one

### ownCode

Filters products which own code equals the provided one

### priceListId

Filters product’s prices collection, returning only those that the price list ID matches the provides one. If you manage only 1 price list, leave this parameter empty.

### dateUpdatedFrom

Filter products which have been updated after the provided date.\
(Format yyyy-mm-dd HH:mm with HH in 24 hours-format)\
Will only return modified products on-or-after the given date.

### types

Filter products which have based on a list of product types.\
The filter value must be a comma separated list of integer numeric values.\
Available values are:\
1 = Normal product\
2 = Kit product type\
5 = Variation child product type\
6 = Variation master product type\
Eg: 1,5,6 gets only products of normal, and variation types, without including the kit product type.

### catalogStatus

Filter the products that are in the list of status provided.\
Available status values are:\
0 = Assigned,\
1 = Approved (assigned and approved),\
2 = Observed (assigned but observed),2 = Observed (assigned but observed),\
3 = Observed and fixed,\
4 = Observed and rejected,\
5 = Deleted\
This parameter can receive a list of status separated by a comma. For example: 1, 2, 4.

### sort

Indicates the field to be sorted by (ascending only). Available fields: ID

### offset

Used for paging. Moves the inferior limit of the records to the provided one. For example, offset=50 gets the rows skipping the first 50 records

### limit

Used for paging. Defines the number of records to be returned. For example, limit=10 gets only 10 records

#### Paging example:

offset=50, limit=10, will skip the first 50 records and return the next 10 ones (from record 51 to 61)
