POST /stocks/material-types/folders

Create a material type folder

This endpoint allows the user to create a material type folder.

Operation ID: createMaterialTypeFolder
lock This endpoint requires a Bearer token in the Authorization header.

Request Body

Content-Type: application/json · Required fields: name

name string required

Name of the material type folder.

Example: Material Type Folder 1

code string | null

Code of the material type folder. Not required in the endpoint request but will be generated internally since there cannot be a material type folder without a code. When sent, needs to be unique.

Example: MTF1

parent_id string

ID of the parent material type folder

Example: 1

Responses

data object

MaterialTypeFolder model structure details

id string read-only

ID of the Material Type Folder

type string read-only

Model type

stock-material-type-folder
attributes object
material_type_folder_id string read-only

ID of the material type folder

Example: 1

parent_id string

ID of the associated folder of the material type folder

Example: 1

name string

Name of the material type folder

Example: Chemical

code string

Code of the material type folder

Example: CH-00001

created_at string (date-time)

Creation date

Example: 2021-01-01 00:00:00

updated_at string (date-time)

Last update date

Example: 2021-01-01 00:00:00

deleted_at string (date-time) | null

Deletion date

Example: 2021-01-01 00:00:00

status string
error
error object
http_code integer
401
message string

Example: Authentication token invalid.

more_info string
status string
error
error object
http_code integer
429
message string

Example: Too Many Requests.

more_info string
status string
error
error object
http_code integer
500
message string

Example: An error has occurred during the request.

more_info string