> This page is for Developer.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.bigcommerce.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.bigcommerce.com/_mcp/server.

# Get Inventory at Location

GET https://api.bigcommerce.com/stores/{store_hash}/v3/inventory/locations/{location_id}/items

Return a list of inventory and inventory settings for all items in a location.

**Limits**
* Limit of 1000 items for payload length.


Reference: https://docs.bigcommerce.com/developer/api-reference/rest/admin/management/inventory/items/get-location-inventory-items

## Authentication

- `X-Auth-Token` header (required) — ### OAuth scopes | UI Name | Permission | Parameter | |:--------|:-----------|:----------| | Store Inventory | read-only | `store_inventory_read_only` | | Store Inventory | modify | `store_inventory` | ### Authentication header | Header | Argument | Description | |:-------|:---------|:------------| | `X-Auth-Token` | `access_token` | For more about API accounts that generate `access_token`s, see [API Accounts and OAuth Scopes](/developer/docs/overview/api-fundamentals/api-accounts#api-accounts). | ### Further reading For example requests and more information about authenticating BigCommerce APIs, see [Authentication and Example Requests](/developer/docs/overview/api-fundamentals/api-accounts). For more about BigCommerce OAuth scopes, see [API Accounts and OAuth Scopes](/developer/docs/overview/api-fundamentals/api-accounts#oauth-scopes). For a list of API status codes, see [API Status Codes](/developer/api-reference/rest/overview#rest-http-status-codes).

## Request

### Path parameters

- `location_id` (integer, required) — Unique identifier for a location.
- `store_hash` (string, required) — Permanent ID of the BigCommerce store.

### Query parameters

- `variant_id:in` (integer, optional) — List of `variant_id` separated by comma.
- `product_id:in` (integer, optional) — List of `product_id` separated by comma.
- `sku:in` (string, optional) — List of `sku` separated by comma.
- `page` (integer, optional) — Specifies the page number in a limited (paginated) list.
- `limit` (integer, optional) — Controls the number of items per page in a limited (paginated) list.

### Headers

- `Accept` (string, required, default: application/json) — The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body.

## Response

### 200

Request has been successfully processed.

- `data` (list of LocationItemsResponse, optional)
- `meta` (Meta, optional)

## Errors

### 404 Not Found Error

Request has been rejected due to resource not being found.

- `status` (integer, optional) — The HTTP status code generated by the origin server for this occurrence of the problem.
- `title` (string, optional) — Human readable error message.
- `type` (string, optional) — URL identifying the error type. Dereferencing the URL leads to documentation about the error type.
- `errors` (ErrorResponseErrors, optional) — The detailed summary describing the particular error.

## Types

### LocationItemsResponse

- `identity` (LocationItemsResponseIdentity, optional)
- `available_to_sell` (integer, optional) — Amount of available items.
- `total_inventory_onhand` (integer, optional) — Amount of available items on hand minus `safety_stock`.
- `qty_backordered` (integer, optional) — Current quantity of this item on backorder.
- `settings` (LocationItemsResponseSettings, optional)

### Meta

- `pagination` (MetaPagination, optional)

### ErrorResponseErrors

The detailed summary describing the particular error.

### LocationItemsResponseIdentity

- `sku` (string, optional) — "Stock keeping unit" identifier of item.
- `variant_id` (integer, optional) — ID of variant.
- `product_id` (integer, optional) — ID of product.

### LocationItemsResponseSettings

- `safety_stock` (integer, optional, default: 0) — Safety stock. Decreases the amount available for selling an item. If missing, the value will remain the same.
- `is_in_stock` (boolean, optional, default: true) — Shows whether an item is available for purchase independent of quantity.
- `warning_level` (integer, optional, default: 0) — Inventory warning level for the product. The store owner will be informed when the product's inventory level drops below the warning level. If missing, the value will remain the same.
- `bin_picking_number` (string, optional) — Warehouse location identifier; bin picking number for the item.
- `backorder_limit` (integer, optional, nullable) — Maximum quantity that can be backordered for this item. `null` means unlimited backorder.
- `backorder_message` (LocationItemsResponseSettingsBackorderMessage, optional, nullable) — The backorder message assigned to this item.

### MetaPagination

- `total` (integer, optional) — The total number of items in the result set.
- `count` (integer, optional) — The total number of items in the collection on current page.
- `per_page` (integer, optional) — The number of items returned in the collection per page, controlled by the limit parameter.
- `current_page` (integer, optional) — The page you are currently on within the collection.
- `total_pages` (integer, optional) — The total number of pages in the collection.
- `links` (MetaPaginationLinks, optional) — Pagination links for the previous and next parts of the whole collection.

### LocationItemsResponseSettingsBackorderMessage

The backorder message assigned to this item.

- `id` (integer, optional)
- `name` (string, optional)
- `message` (string, optional) — The shopper-facing backorder message text.
- `is_default` (boolean, optional)
- `created_at` (datetime, optional)
- `updated_at` (datetime, optional)

### MetaPaginationLinks

Pagination links for the previous and next parts of the whole collection.

- `previous` (string, optional) — The link to the previous page is returned in the response.
- `current` (string, optional) — A link to the current page is returned in the response.
- `next` (string, optional) — Link to the next page returned in the response.

## Examples

**Response**

```json
{
  "data": [
    {
      "identity": {
        "sku": "RE-130",
        "variant_id": 78,
        "product_id": 130
      },
      "available_to_sell": 10,
      "total_inventory_onhand": 12,
      "qty_backordered": 3,
      "settings": {
        "safety_stock": 2,
        "is_in_stock": true,
        "warning_level": 2,
        "bin_picking_number": "1",
        "backorder_limit": 50,
        "backorder_message": {
          "id": 1,
          "name": "Standard Backorder",
          "message": "Ships in 2-3 weeks",
          "is_default": true,
          "created_at": "2024-01-15T09:30:00Z",
          "updated_at": "2024-01-15T09:30:00Z"
        }
      }
    }
  ],
  "meta": {
    "pagination": {
      "total": 246,
      "count": 5,
      "per_page": 5,
      "current_page": 1,
      "total_pages": 50,
      "links": {
        "previous": "?limit=5&page=2",
        "current": "?limit=5&page=3",
        "next": "?limit=5&page=4"
      }
    }
  }
}
```

**SDK Code**

```python
import requests

url = "https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items"

headers = {
    "Accept": "application/json",
    "X-Auth-Token": "<apiKey>"
}

response = requests.get(url, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items';
const options = {
  method: 'GET',
  headers: {Accept: 'application/json', 'X-Auth-Token': '<apiKey>'}
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Accept", "application/json")
	req.Header.Add("X-Auth-Token", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
request["X-Auth-Token"] = '<apiKey>'

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items")
  .header("Accept", "application/json")
  .header("X-Auth-Token", "<apiKey>")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items', [
  'headers' => [
    'Accept' => 'application/json',
    'X-Auth-Token' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items");
var request = new RestRequest(Method.GET);
request.AddHeader("Accept", "application/json");
request.AddHeader("X-Auth-Token", "<apiKey>");
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Accept": "application/json",
  "X-Auth-Token": "<apiKey>"
]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.bigcommerce.com/stores/store_hash/v3/inventory/locations/1/items")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```