Supported Formats

json

GET /api/v2/stock_adjustments.json
Retrieves a list of stock adjustments

Supported Formats

json

Examples

Response Example:

HTTP/1.1 200 OK
{
  "stock_adjustments": [
    {
      "id": 1,
      "sequential_id": 1000,
      "adjusted_at": "2022-08-23T21:55:46.000Z",
      "created_at": "2022-08-22T19:35:04.000Z",
      "updated_at": "2022-08-23T21:55:46.000Z",
      "archived": false,
      "stock_adjustment_reason": {
        "id": 1,
        "reason": "Damaged Products"
      },
      "location": {
        "id": 1,
        "shopify_id": 34915680278,
      }
    },
    {
      "id": 2,
      "sequential_id": 1001,
      "adjusted_at": null,
      "created_at": "2022-08-23T21:55:59.000Z",
      "updated_at": "2022-08-23T21:55:59.000Z",
      "archived": false,
      "stock_adjustment_reason": null,
      "location": {
        "id": 1,
        "shopify_id": 34915680278,
      }
    }
  ]
}

Params

Param name Description
adjusted_since
optional

Return only stock adjustments that have been adjusted on or after a specified date (Using ISO 8601 format; e.g. 2014-04-25T16:15:47-04:00)

Validations:

  • Must be a DateTime

limit
optional

Return up to this many stock adjustments per page

Validations:

  • Must be a Integer

offset
optional

Specifies the number of matching records to skip over. NOTE: This should not be used for pagination. Use the since_id param instead. If both offset and since_id are provided, only since_id will be used.

Validations:

  • Must be a Integer

updated_since
optional

Return only stock adjustments that have been updated on or after a specified date (Using ISO 8601 format; e.g. 2014-04-25T16:15:47-04:00)

Validations:

  • Must be a String

since_id
optional

Return only stock adjustments with ID values greater than the provided ID. Use in combination with the limit param for pagination. Can not be used in combination with the offset param. If both offset and since_id are provided, only since_id will be used.

Validations:

  • Must be a Integer

Returns

Code: 200

Description:

The requested stock adjustment data

Param name Description
id
required

“id”: 808950810

A unique numeric identifier for the stock adjustment.

Validations:

  • Must be a Integer

sequential_id
required

“sequential_id”: 23133

A sequential number assigned to a stock adjustment.

Validations:

  • Must be a Integer

adjusted_at
required

“adjusted_at”: “2021-02-09T19:47:30.000Z”

The date and time (ISO 8601 format) when the stock adjustment was performed.

Validations:

  • Must be a DateTime

created_at
required

“created_at”: “2021-02-05T17:55:46.000Z”

The date and time (ISO 8601 format) when the stock adjustment was created.

Validations:

  • Must be a DateTime

updated_at
required

“updated_at”: “2021-02-09T19:47:30.000Z”

The date and time (ISO 8601 format) when the stock adjustment was last updated.

Validations:

  • Must be a DateTime

archived
required

“archived”: false

Indicates whether the stock adjustment has been archived or not.

Validations:

  • Must be one of: true, false, 1, 0.

location
required

Information about the location at which the stock adjustment was made.

Validations:

  • Must be a Hash

location[id]
required

“id”: 3824

The unique numeric identifier for the location.

Validations:

  • Must be a Integer

location[shopify_id]
required

“shopify_id”: 35616076169238

The identifier for the associated Shopify Location.

Validations:

  • Must be a Integer

stock_adjustment_reason
required

Information about the reason for the stock adjustment.

Validations:

  • Must be a Hash

stock_adjustment_reason[id]
required

“id”: 3824

The unique numeric identifier for the stock adjustment reason.

Validations:

  • Must be a Integer

stock_adjustment_reason[reason]
required

“reason”: “Damaged Products”

The description of the stock adjustment reason.

Validations:

  • Must be a String


GET /api/v2/stock_adjustments/{stock_adjustment_id}.json
Retrieves a single stock adjustment by ID

Supported Formats

json

Errors

Code Description
404 No stock adjustments found

Examples

Response Example:

HTTP/1.1 200 OK
{
  "id": 1,
  "sequential_id": 1000,
  "adjusted_at": "2022-08-23T21:55:46.000Z",
  "created_at": "2022-08-22T19:35:04.000Z",
  "updated_at": "2022-08-23T21:55:46.000Z",
  "archived": false,
  "stock_adjustment_reason": {
    "id": 1,
    "reason": "Damaged Products"
  },
  "location": {
    "id": 1,
    "shopify_id": 34915680278,
  }
}

Params

Param name Description
id
required

The ID of the stock adjustment

Validations:

  • Must be a number.

Returns

Code: 200

Description:

The requested stock adjustment data

Param name Description
id
required

“id”: 808950810

A unique numeric identifier for the stock adjustment.

Validations:

  • Must be a Integer

sequential_id
required

“sequential_id”: 23133

A sequential number assigned to a stock adjustment.

Validations:

  • Must be a Integer

adjusted_at
required

“adjusted_at”: “2021-02-09T19:47:30.000Z”

The date and time (ISO 8601 format) when the stock adjustment was performed.

Validations:

  • Must be a DateTime

created_at
required

“created_at”: “2021-02-05T17:55:46.000Z”

The date and time (ISO 8601 format) when the stock adjustment was created.

Validations:

  • Must be a DateTime

updated_at
required

“updated_at”: “2021-02-09T19:47:30.000Z”

The date and time (ISO 8601 format) when the stock adjustment was last updated.

Validations:

  • Must be a DateTime

archived
required

“archived”: false

Indicates whether the stock adjustment has been archived or not.

Validations:

  • Must be one of: true, false, 1, 0.

location
required

Information about the location at which the stock adjustment was made.

Validations:

  • Must be a Hash

location[id]
required

“id”: 3824

The unique numeric identifier for the location.

Validations:

  • Must be a Integer

location[shopify_id]
required

“shopify_id”: 35616076169238

The identifier for the associated Shopify Location.

Validations:

  • Must be a Integer

stock_adjustment_reason
required

Information about the reason for the stock adjustment.

Validations:

  • Must be a Hash

stock_adjustment_reason[id]
required

“id”: 3824

The unique numeric identifier for the stock adjustment reason.

Validations:

  • Must be a Integer

stock_adjustment_reason[reason]
required

“reason”: “Damaged Products”

The description of the stock adjustment reason.

Validations:

  • Must be a String