Skip to main content

Get Stock for Product

GET 

https://euwest.api.elasticpath.com/v2/inventories/:product_uuid

Gets the stock for the product matching the specified unique identifier.

Request

Path Parameters

    product_uuid UUIDrequired

    The unique identifier of the product.

Responses

Success. Returns the stock for the given product UUID

Schema
    data objectrequired
    idUUID (string)required

    The unique identifier.

    Example: 00000000-0000-0000-0000-000000000000
    typeStockType (string)required

    Possible values: [stock]

    Default value: stock
    Example: stock
    attributes objectrequired
    availableint64required
    Example: 20
    allocatedint64required
    Example: 10
    totalint64required
    Example: 30
    locations object
    property name* object
    availableint64required
    Example: 20
    allocatedint64required
    Example: 10
    totalint64required
    Example: 30
    meta objectrequired
    stock_idUUID (string)required

    The unique identifier.

    Example: 00000000-0000-0000-0000-000000000000
    timestamps Timestampsrequired
    updated_atstring

    The date and time a resource was updated.

    Example: 2017-01-10T11:41:19.244842Z
    created_atstringrequired

    The date and time a resource was created.

    Example: 2017-01-10T11:41:19.244842Z

Authorization: http

name: bearerAuthtype: httpscheme: bearer
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "https://euwest.api.elasticpath.com/v2/inventories/:product_uuid");
request.Headers.Add("Accept", "application/json");
request.Headers.Add("Authorization", "Bearer <token>");
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
Request Collapse all
Base URL
https://euwest.api.elasticpath.com/v2
Auth
Parameters
— pathrequired
ResponseClear

Click the Send API Request button above and see the response here!

We use cookies to enhance your experience. By continuing to visit this site you agree to our use of cookies.