The Item Attribute object

Attributes

id string

Unique identifier for the object.

created_at string

ISO 8601 timestamp of when the object was created.

updated_at string

ISO 8601 timestamp of when the object was last updated.

attribute_name string required
numeric_values boolean

Default: false

from_range number

Default: 0

increment number

Default: 0

to_range number

Default: 0

disabled boolean

Default: false

The Item Attribute object
{
  "id": "item-attribute_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "attribute_name": "attribute_name_example",
  "numeric_values": false,
  "from_range": 0,
  "increment": 0,
  "to_range": 0,
  "disabled": false
}
GET /api/stock/item-attribute/{id}

Retrieve a item attribute

Retrieves the details of an existing item attribute. Supply the unique item attribute ID that was returned from a previous request.

Path parameters

id string required

The identifier of the item attribute to retrieve.

Returns

Returns the item attribute object if a valid identifier was provided.

GET /api/stock/item-attribute/{id}
curl https://api.overplane.dev/api/stock/item-attribute/item-attribute_abc123 \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "id": "item-attribute_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "attribute_name": "attribute_name_example",
  "numeric_values": false,
  "from_range": 0,
  "increment": 0,
  "to_range": 0,
  "disabled": false
}
GET /api/stock/item-attribute

List all item attributes

Returns a list of item attributes. The results are sorted by creation date, with the most recently created appearing first.

Query parameters

limit integer

Maximum number of objects to return. Default: 20.

offset integer

Number of objects to skip for pagination. Default: 0.

Returns

A paginated list of item attribute objects.

GET /api/stock/item-attribute
curl https://api.overplane.dev/api/stock/item-attribute \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "data": [
    {
      "id": "item-attribute_abc123",
      "created_at": "2024-01-15T09: 30: 00Z",
      "updated_at": "2024-01-15T09: 30: 00Z",
      "attribute_name": "attribute_name_example",
      "numeric_values": false,
      "from_range": 0,
      "increment": 0,
      "to_range": 0,
      "disabled": false
    }
  ],
  "has_more": false,
  "total": 1
}
POST /api/stock/item-attribute

Create a item attribute

Creates a new item attribute object.

Body parameters

attribute_name string required
numeric_values boolean

Default: false

from_range number

Default: 0

increment number

Default: 0

to_range number

Default: 0

disabled boolean

Default: false

Returns

Returns the newly created item attribute object if the call succeeded.

POST /api/stock/item-attribute
curl https://api.overplane.dev/api/stock/item-attribute \
  -H "Authorization: Bearer sk_test_..." \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{"attribute_name":"attribute_name_example"}'
Response
{
  "id": "item-attribute_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "attribute_name": "attribute_name_example",
  "numeric_values": false,
  "from_range": 0,
  "increment": 0,
  "to_range": 0,
  "disabled": false
}
PATCH /api/stock/item-attribute/{id}

Update a item attribute

Updates the specified item attribute by setting the values of the parameters passed. Any parameters not provided will be left unchanged.

Path parameters

id string required

The identifier of the item attribute to update.

Body parameters

attribute_name string
numeric_values boolean

Default: false

from_range number

Default: 0

increment number

Default: 0

to_range number

Default: 0

disabled boolean

Default: false

Returns

Returns the updated item attribute object.

PATCH /api/stock/item-attribute/{id}
curl https://api.overplane.dev/api/stock/item-attribute/item-attribute_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X PATCH \
  -H "Content-Type: application/json" \
  -d '{"attribute_name":"attribute_name_example","numeric_values":false}'
Response
{
  "id": "item-attribute_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "attribute_name": "attribute_name_example",
  "numeric_values": false,
  "from_range": 0,
  "increment": 0,
  "to_range": 0,
  "disabled": false
}
DELETE /api/stock/item-attribute/{id}

Delete a item attribute

Permanently deletes a item attribute. This cannot be undone.

Path parameters

id string required

The identifier of the item attribute to delete.

Returns

Returns a confirmation that the item attribute has been deleted.

DELETE /api/stock/item-attribute/{id}
curl https://api.overplane.dev/api/stock/item-attribute/item-attribute_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X DELETE
Response
{
  "id": "item-attribute_abc123",
  "deleted": true
}

Line items

Child objects that belong to this item attribute. These are accessed via the parent's ID.

Item Attribute Value

Attributes

idx integer
item_attribute_id string required
attribute_value string required
abbr string required

Endpoints

GET /api/stock/item-attribute-value?parent_id={id}
POST /api/stock/item-attribute-value
PATCH /api/stock/item-attribute-value/{id}
DELETE /api/stock/item-attribute-value/{id}
POST /api/stock/item-attribute-value/reorder
Item Attribute Value object
{
  "id": "item-attribute-value_abc123",
  "idx": 1,
  "item_attribute_id": "item_attribute_id_example",
  "attribute_value": "attribute_value_example",
  "abbr": "abbr_example"
}