{
  "opencollection": "1.0.0",
  "info": {
    "name": "Horizon API V1 AccountExternalTruckIdentifier Materials API",
    "version": "1.0"
  },
  "request": {
    "auth": {
      "type": "bearer",
      "token": "{{bearerToken}}"
    }
  },
  "items": [
    {
      "info": {
        "name": "Materials",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "Retrieve Materials that belong to a Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/companies/:company-id/materials",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "company-id",
                "value": "",
                "type": "path",
                "description": "Company ID"
              },
              {
                "name": "page[limit]",
                "value": "",
                "type": "query",
                "description": "The maximum number of paginated results to return"
              },
              {
                "name": "page[after]",
                "value": "",
                "type": "query",
                "description": "The cursor to start paginating after"
              },
              {
                "name": "page[before]",
                "value": "",
                "type": "query",
                "description": "The cursor to stop paginating at"
              },
              {
                "name": "search[datagrid]",
                "value": "",
                "type": "query",
                "description": "Search string for datagrid queries"
              }
            ]
          },
          "docs": "Retrieve `Materials` for a `Company`\n\nDatagrid search (`search[datagrid]`) queries against the following properties:\n * `name`\n * `external_id`\n * `material_type.name`"
        },
        {
          "info": {
            "name": "Create a Material for a Company",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.tread-horizon.com/v1/companies/:company-id/materials",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "company-id",
                "value": "",
                "type": "path",
                "description": "Company ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Create `Materials` for a `Company`\n\nThis endpoint requires the `create_materials` permission"
        },
        {
          "info": {
            "name": "Typeahead search on Material for a Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/companies/:company-id/materials/typeahead",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "company-id",
                "value": "",
                "type": "path",
                "description": "Company ID"
              },
              {
                "name": "page[limit]",
                "value": "",
                "type": "query",
                "description": "The maximum number of paginated results to return"
              },
              {
                "name": "page[after]",
                "value": "",
                "type": "query",
                "description": "The cursor to start paginating after"
              },
              {
                "name": "page[before]",
                "value": "",
                "type": "query",
                "description": "The cursor to stop paginating at"
              },
              {
                "name": "search[query]",
                "value": "",
                "type": "query",
                "description": "Search string for queries"
              }
            ]
          },
          "docs": "Typeahead search against the `name` property on `Material` for a `Company`."
        },
        {
          "info": {
            "name": "Typeahead search on Materials that belong to Order's Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/companies/:company-id/orders/:order-id/materials/typeahead",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "company-id",
                "value": "",
                "type": "path",
                "description": "Company ID"
              },
              {
                "name": "order-id",
                "value": "",
                "type": "path",
                "description": "Order ID"
              },
              {
                "name": "page[limit]",
                "value": "",
                "type": "query",
                "description": "The maximum number of paginated results to return"
              },
              {
                "name": "page[after]",
                "value": "",
                "type": "query",
                "description": "The cursor to start paginating after"
              },
              {
                "name": "page[before]",
                "value": "",
                "type": "query",
                "description": "The cursor to stop paginating at"
              },
              {
                "name": "search[query]",
                "value": "",
                "type": "query",
                "description": "Search string for queries"
              }
            ]
          },
          "docs": "Typeahead search against the `name` property for `Materials` that belong to the `Order`'s `Company`"
        },
        {
          "info": {
            "name": "Retrieve Materials that belong to the current Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/materials",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "page[limit]",
                "value": "",
                "type": "query",
                "description": "The maximum number of paginated results to return"
              },
              {
                "name": "page[after]",
                "value": "",
                "type": "query",
                "description": "The cursor to start paginating after"
              },
              {
                "name": "page[before]",
                "value": "",
                "type": "query",
                "description": "The cursor to stop paginating at"
              },
              {
                "name": "search[datagrid]",
                "value": "",
                "type": "query",
                "description": "Search string for datagrid queries"
              }
            ]
          },
          "docs": "Retrieve `Materials` visible to the currently authenticated `Company`.\n\nDatagrid search (`search[datagrid]`) queries against the following properties:\n * `name`\n * `external_id`\n * `material_type.name`\n "
        },
        {
          "info": {
            "name": "Create a Material",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.tread-horizon.com/v1/materials",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Create a new Material\n\nThis endpoint requires the `create_materials` permission"
        },
        {
          "info": {
            "name": "Typeahead search on Materials",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/materials/typeahead",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "page[limit]",
                "value": "",
                "type": "query",
                "description": "The maximum number of paginated results to return"
              },
              {
                "name": "page[after]",
                "value": "",
                "type": "query",
                "description": "The cursor to start paginating after"
              },
              {
                "name": "page[before]",
                "value": "",
                "type": "query",
                "description": "The cursor to stop paginating at"
              },
              {
                "name": "search[query]",
                "value": "",
                "type": "query",
                "description": "Search string for queries"
              }
            ]
          },
          "docs": "Typeahead search against the `name` property for `Material` visible to the currently authenticated `Company`.\n"
        },
        {
          "info": {
            "name": "Retrieve a single Material",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/materials/:id",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "Material ID"
              }
            ]
          },
          "docs": "Retrieve a `Material` by ID"
        },
        {
          "info": {
            "name": "Update a Material",
            "type": "http"
          },
          "http": {
            "method": "PATCH",
            "url": "https://api.tread-horizon.com/v1/materials/:id",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "Material ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Update `Material` by ID\n\nThis endpoint required the `edit_material` permission"
        },
        {
          "info": {
            "name": "Delete a Material",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://api.tread-horizon.com/v1/materials/:id",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "Material ID"
              }
            ]
          },
          "docs": "Delete a `Material` by ID\n\nThis endpoint requires the `delete_material` permission"
        },
        {
          "info": {
            "name": "Activate a Material",
            "type": "http"
          },
          "http": {
            "method": "PUT",
            "url": "https://api.tread-horizon.com/v1/materials/:material-id/activate",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "material-id",
                "value": "",
                "type": "path",
                "description": "Material ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Activate a `Material` by ID\n\nThis endpoint requires the `edit_material` permission"
        },
        {
          "info": {
            "name": "Deactivate a Material",
            "type": "http"
          },
          "http": {
            "method": "PUT",
            "url": "https://api.tread-horizon.com/v1/materials/:material-id/deactivate",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "material-id",
                "value": "",
                "type": "path",
                "description": "Material ID"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Deactivate a `Material` by ID\n\nThis endpoint requires the `edit_material` permission"
        },
        {
          "info": {
            "name": "Typeahead search on Materials that belong to Order's Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.tread-horizon.com/v1/orders/:order-id/materials/typeahead",
            "headers": [
              {
                "name": "Accept-Language",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "order-id",
                "value": "",
                "type": "path",
                "description": "Order ID"
              },
              {
                "name": "page[limit]",
                "value": "",
                "type": "query",
                "description": "The maximum number of paginated results to return"
              },
              {
                "name": "page[after]",
                "value": "",
                "type": "query",
                "description": "The cursor to start paginating after"
              },
              {
                "name": "page[before]",
                "value": "",
                "type": "query",
                "description": "The cursor to stop paginating at"
              },
              {
                "name": "search[query]",
                "value": "",
                "type": "query",
                "description": "Search string for queries"
              }
            ]
          },
          "docs": "Typeahead search against the `name` property for `Materials` that belong to the `Order`'s `Company`"
        }
      ]
    }
  ],
  "bundled": true
}