The Inventory Dimension 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.

reference_document string required
dimension_name string required
document_type string
istable boolean

Default: false

condition string
apply_to_all_doctypes boolean

Default: true

target_fieldname string
source_fieldname string
type_of_transaction string
fetch_from_parent string
mandatory_depends_on string
reqd boolean

Default: false

validate_negative_stock boolean

Default: false

The Inventory Dimension object
{
  "id": "inventory-dimension_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "reference_document": "reference_document_example",
  "dimension_name": "dimension_name_example",
  "document_type": "document_type_example",
  "istable": false,
  "condition": "condition_example",
  "apply_to_all_doctypes": true,
  "target_fieldname": "target_fieldname_example",
  "source_fieldname": "source_fieldname_example",
  "type_of_transaction": "type_of_transaction_example",
  "fetch_from_parent": "fetch_from_parent_example",
  "mandatory_depends_on": "mandatory_depends_on_example",
  "reqd": false,
  "validate_negative_stock": false
}
GET /api/stock/inventory-dimension/{id}

Retrieve a inventory dimension

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

Path parameters

id string required

The identifier of the inventory dimension to retrieve.

Returns

Returns the inventory dimension object if a valid identifier was provided.

GET /api/stock/inventory-dimension/{id}
curl https://api.overplane.dev/api/stock/inventory-dimension/inventory-dimension_abc123 \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "id": "inventory-dimension_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "reference_document": "reference_document_example",
  "dimension_name": "dimension_name_example",
  "document_type": "document_type_example",
  "istable": false,
  "condition": "condition_example",
  "apply_to_all_doctypes": true,
  "target_fieldname": "target_fieldname_example",
  "source_fieldname": "source_fieldname_example",
  "type_of_transaction": "type_of_transaction_example",
  "fetch_from_parent": "fetch_from_parent_example",
  "mandatory_depends_on": "mandatory_depends_on_example",
  "reqd": false,
  "validate_negative_stock": false
}
GET /api/stock/inventory-dimension

List all inventory dimensions

Returns a list of inventory dimensions. 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 inventory dimension objects.

GET /api/stock/inventory-dimension
curl https://api.overplane.dev/api/stock/inventory-dimension \
  -H "Authorization: Bearer sk_test_..."
Response
{
  "data": [
    {
      "id": "inventory-dimension_abc123",
      "created_at": "2024-01-15T09: 30: 00Z",
      "updated_at": "2024-01-15T09: 30: 00Z",
      "reference_document": "reference_document_example",
      "dimension_name": "dimension_name_example",
      "document_type": "document_type_example",
      "istable": false,
      "condition": "condition_example",
      "apply_to_all_doctypes": true,
      "target_fieldname": "target_fieldname_example",
      "source_fieldname": "source_fieldname_example",
      "type_of_transaction": "type_of_transaction_example",
      "fetch_from_parent": "fetch_from_parent_example",
      "mandatory_depends_on": "mandatory_depends_on_example",
      "reqd": false,
      "validate_negative_stock": false
    }
  ],
  "has_more": false,
  "total": 1
}
POST /api/stock/inventory-dimension

Create a inventory dimension

Creates a new inventory dimension object.

Body parameters

reference_document string required
dimension_name string required
document_type string
istable boolean

Default: false

condition string
apply_to_all_doctypes boolean

Default: true

target_fieldname string
source_fieldname string
type_of_transaction string
fetch_from_parent string
mandatory_depends_on string
reqd boolean

Default: false

validate_negative_stock boolean

Default: false

Returns

Returns the newly created inventory dimension object if the call succeeded.

POST /api/stock/inventory-dimension
curl https://api.overplane.dev/api/stock/inventory-dimension \
  -H "Authorization: Bearer sk_test_..." \
  -X POST \
  -H "Content-Type: application/json" \
  -d '{"reference_document":"reference_document_example","dimension_name":"dimension_name_example"}'
Response
{
  "id": "inventory-dimension_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "reference_document": "reference_document_example",
  "dimension_name": "dimension_name_example",
  "document_type": "document_type_example",
  "istable": false,
  "condition": "condition_example",
  "apply_to_all_doctypes": true,
  "target_fieldname": "target_fieldname_example",
  "source_fieldname": "source_fieldname_example",
  "type_of_transaction": "type_of_transaction_example",
  "fetch_from_parent": "fetch_from_parent_example",
  "mandatory_depends_on": "mandatory_depends_on_example",
  "reqd": false,
  "validate_negative_stock": false
}
PATCH /api/stock/inventory-dimension/{id}

Update a inventory dimension

Updates the specified inventory dimension 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 inventory dimension to update.

Body parameters

reference_document string
dimension_name string
document_type string
istable boolean

Default: false

condition string
apply_to_all_doctypes boolean

Default: true

target_fieldname string
source_fieldname string
type_of_transaction string
fetch_from_parent string
mandatory_depends_on string
reqd boolean

Default: false

validate_negative_stock boolean

Default: false

Returns

Returns the updated inventory dimension object.

PATCH /api/stock/inventory-dimension/{id}
curl https://api.overplane.dev/api/stock/inventory-dimension/inventory-dimension_abc123 \
  -H "Authorization: Bearer sk_test_..." \
  -X PATCH \
  -H "Content-Type: application/json" \
  -d '{"reference_document":"reference_document_example","dimension_name":"dimension_name_example"}'
Response
{
  "id": "inventory-dimension_abc123",
  "created_at": "2024-01-15T09: 30: 00Z",
  "updated_at": "2024-01-15T09: 30: 00Z",
  "reference_document": "reference_document_example",
  "dimension_name": "dimension_name_example",
  "document_type": "document_type_example",
  "istable": false,
  "condition": "condition_example",
  "apply_to_all_doctypes": true,
  "target_fieldname": "target_fieldname_example",
  "source_fieldname": "source_fieldname_example",
  "type_of_transaction": "type_of_transaction_example",
  "fetch_from_parent": "fetch_from_parent_example",
  "mandatory_depends_on": "mandatory_depends_on_example",
  "reqd": false,
  "validate_negative_stock": false
}
DELETE /api/stock/inventory-dimension/{id}

Delete a inventory dimension

Permanently deletes a inventory dimension. This cannot be undone.

Path parameters

id string required

The identifier of the inventory dimension to delete.

Returns

Returns a confirmation that the inventory dimension has been deleted.

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