Items¶
Obtain the items of a customer¶
Obtener los artículos asociados en base a la lista de precios relacionada a la clase del cliente.
Resource URL¶
-
GET
http://api.next-cloud.mx/v1/client/
(int: client_id)/items.
(format)¶ Parameters: - client_id – ID del cliente.
- format – json o xml.
Request Headers: - Authorization – Token del usuario
Status Codes: - 200 OK – Ningún error.
- 404 Not Found – El cliente no cuenta con lista de precios asociada.
- 404 Not Found – El cliente no está activo en Next Cloud.
Example request¶
GET v1/client/1/items.json HTTP/1.1
Host: api.next-cloud.mx
Accept: application/json
Authorization: Token ( token del usuario )
Example Response¶
HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json
Allow: GET, OPTIONS
{
"items":[
{
"sku": "100000",
"descripcion": "AIREADORES DE VINO TINTO VINTURI TRANSPARENTE VI-V1010",
"precio": 0.0
},
{
"sku": "4172366",
"descripcion": "ALACIADORA DE CABELLO IN-STYLER",
"precio": 1387.46
},
{
"sku": "2528211",
"descripcion": "BLURAY 3D PIONEER BDP-140 INCLUYE CABLE HDMI",
"precio": 2248.75
}
]
}
Example XML¶
Example request¶
GET v1/client/1/items.xml HTTP/1.1
Host: api.next-cloud.mx
Accept: application/xml
Content-Type: application/xml
Authorization: Token ( token del usuario )
Example Response¶
HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/xml; charset=utf-8
Allow: GET, OPTIONS
<?xml version="1.0" encoding="UTF-8"?>
<root>
<items>
<list-item>
<sku>100000</sku>
<descripcion>AIREADORES DE VINO TINTO VINTURI TRANSPARENTE VI-V1010</descripcion>
<precio>0.0</precio>
</list-item>
<list-item>
<sku>4172366</sku>
<descripcion>ALACIADORA DE CABELLO IN-STYLER</descripcion>
<precio>1387.46</precio>
</list-item>
<list-item>
<sku>2528211</sku>
<descripcion>BLURAY 3D PIONEER BDP-140 INCLUYE CABLE HDMI</descripcion>
<precio>2248.75</precio>
</list-item>
<list-item>
<sku>4173179</sku>
<descripcion>CÁMARA DIGITAL KODAK EASYSHARE 14 MPX M552</descripcion>
<precio>1415.04</precio>
</list-item>
</items>
</root>