Material

Returns materials

Returns a list of materials for the specified business unit.

Securitybearer
Request
path Parameters
businessUnitId
required
string <uuid>

The business unit id.

query Parameters
isDeleted
boolean

If true, only include deleted items. If false, only include non-deleted items. If blank, include all.

Responses
get/api/v1/businessUnits/{businessUnitId}/costTypes/material
Request samples
Response samples
application/json
[
  • {
    }
]

Creates material

Creates a material for the specified business unit.

Securitybearer
Request
path Parameters
businessUnitId
required
string <uuid>

The business unit id.

Request Body schema:
required

The material to create.

code
required
string non-empty

The code.

description
string or null

The description.

isStockpiled
required
boolean

Flag indicating whether the material is used immediately (e.g., installed), or added to the stockpile for later.

heavyBidCode
string or null

The HeavyBid code.

Responses
post/api/v1/businessUnits/{businessUnitId}/costTypes/material
Request samples
{
  • "code": "IF-Z",
  • "description": "Import Fill",
  • "isStockpiled": false,
  • "heavyBidCode": "HB1"
}
Response samples
application/json
{
  • "id": "1d66cad1-98a4-4acc-b9b2-b3f9ee0de65f",
  • "businessUnitId": "07c00dc0-aecf-45bd-bf9e-74628188b3c7",
  • "isDeleted": false,
  • "code": "IF-Z",
  • "description": "Import Fill",
  • "isStockpiled": false,
  • "heavyBidCode": "HB1"
}

Updates material

Updates an existing material with the specified id.

Securitybearer
Request
path Parameters
id
required
string <uuid>

The material id.

Request Body schema:
required

The material to be updated.

code
required
string non-empty

The code.

description
string or null

The description.

isStockpiled
required
boolean

Flag indicating whether the material is used immediately (e.g., installed), or added to the stockpile for later.

heavyBidCode
string or null

The HeavyBid code.

Responses
put/api/v1/costTypes/material/{id}
Request samples
{
  • "code": "IF-Z",
  • "description": "Import Fill",
  • "isStockpiled": false,
  • "heavyBidCode": "HB1"
}

Deletes a material

Deletes a material with the specified id.

Securitybearer
Request
path Parameters
id
required
string <uuid>

The material id.

Responses
204

No Content

delete/api/v1/costTypes/material/{id}
Request samples

Returns job materials

Returns a list of job materials (i.e., a physical material that can be used on one or more cost codes).

Securitybearer
Request
path Parameters
jobId
required
string <uuid>

The job id.

query Parameters
isDiscontinued
boolean

If true, only include discontinued items. If false or not specified, only include non-discontinued items. If blank, include all.

isDeleted
boolean

If true, only include deleted items. If false, only include non-deleted items. If blank, include all.

Responses
get/api/v1/jobs/{jobId}/costTypes/jobMaterial
Request samples
Response samples
application/json
[
  • {
    }
]

Creates job material

Creates a job material on the specified job.

Securitybearer
Request
path Parameters
jobId
required
string <uuid>

The job id.

Request Body schema:
required

The job material to be created.

materialId
required
string <uuid>

The material guid.

description
string or null

The description.

salesTaxPercent
number <double>

The sales tax, expressed as a percent (e.g., 8 means 8% sales tax).

tmRate
number <double>

The T&M rate, in dollars per unit of measure.

unitCost
number <double>

The cost per unit of measure, in dollars.

unitOfMeasure
string or null

The unit of measure.

accountingCode
string or null

The accounting code.

isDiscontinued
boolean

The IsDiscontinued flag.

Responses
post/api/v1/jobs/{jobId}/costTypes/jobMaterial
Request samples
{
  • "materialId": "caa95ace-7aa3-4a0c-af85-f33e18a9773e",
  • "description": "Job material",
  • "salesTaxPercent": 10.1,
  • "tmRate": 7.5,
  • "unitCost": 20.5,
  • "unitOfMeasure": "CY",
  • "accountingCode": "M-ACC",
  • "isDiscontinued": false
}
Response samples
application/json
{
  • "id": "58236983-650d-4528-a9f3-f773a0366ecd",
  • "code": "IF-Z",
  • "isStockpiled": false,
  • "heavyBidCode": "HB1",
  • "jobId": "77de8c55-1b14-4f43-afc2-9f2edb6d64fb",
  • "description": "Import Fill",
  • "isDeleted": false,
  • "materialId": "1d66cad1-98a4-4acc-b9b2-b3f9ee0de65f",
  • "salesTaxPercent": 8.25,
  • "tmRate": 150.3,
  • "unitCost": 20.6,
  • "unitOfMeasure": "TON",
  • "accountingCode": "M-ACC",
  • "isDiscontinued": false
}

Returns a job material

Returns a job material with the specified id.

Securitybearer
Request
path Parameters
id
required
string <uuid>

The job material id

query Parameters
isDeleted
boolean

If true, only include deleted items. If false, only include non-deleted items. If blank, include all.

isDiscontinued
boolean

If true, only include discontinued items. If false, only include non-discontinued items. If blank, include all.

Responses
200

Success

404

The specified resource is not found.

get/api/v1/costTypes/jobMaterial/{id}
Request samples
Response samples
application/json
{
  • "id": "58236983-650d-4528-a9f3-f773a0366ecd",
  • "code": "IF-Z",
  • "isStockpiled": false,
  • "heavyBidCode": "HB1",
  • "jobId": "77de8c55-1b14-4f43-afc2-9f2edb6d64fb",
  • "description": "Import Fill",
  • "isDeleted": false,
  • "materialId": "1d66cad1-98a4-4acc-b9b2-b3f9ee0de65f",
  • "salesTaxPercent": 8.25,
  • "tmRate": 150.3,
  • "unitCost": 20.6,
  • "unitOfMeasure": "TON",
  • "accountingCode": "M-ACC",
  • "isDiscontinued": false
}

Updates job material

Updates an existing job material with the specified id.

Securitybearer
Request
path Parameters
id
required
string <uuid>

The job material id.

Request Body schema:
required

The job material to be updated.

materialId
required
string <uuid>

The material guid.

description
string or null

The description.

salesTaxPercent
number <double>

The sales tax, expressed as a percent (e.g., 8 means 8% sales tax).

tmRate
number <double>

The T&M rate, in dollars per unit of measure.

unitCost
number <double>

The cost per unit of measure, in dollars.

unitOfMeasure
string or null

The unit of measure.

accountingCode
string or null

The accounting code.

isDiscontinued
boolean

The IsDiscontinued flag.

Responses
put/api/v1/costTypes/jobMaterial/{id}
Request samples
{
  • "materialId": "caa95ace-7aa3-4a0c-af85-f33e18a9773e",
  • "description": "Job material",
  • "salesTaxPercent": 10.1,
  • "tmRate": 7.5,
  • "unitCost": 20.5,
  • "unitOfMeasure": "CY",
  • "accountingCode": "M-ACC",
  • "isDiscontinued": false
}

Deletes job material

Deletes the job material with the specified id.

Securitybearer
Request
path Parameters
id
required
string <uuid>

The job material id.

Responses
204

No Content

delete/api/v1/costTypes/jobMaterial/{id}
Request samples

Returns installed materials

Returns a list of installed materials.

Securitybearer
Request
Request Body schema:

The request object for getting installed materials.

jobIds
Array of strings or null <uuid>

List of Job Ids. Used with JobTagIds to limit jobs. Returns jobs with JobIds and JobTagIds.

jobTagIds
Array of strings or null <uuid>

List of Job Tag Ids. Used with JobIds to limit jobs. Returns jobs with JobIds and JobTagIds.

foremanIds
Array of strings or null <uuid>

List of Foreman Ids. Used to limit transactions. Returns transactions only for foremen specified.

startDate
string or null <date-time>

Beginning local date (yyyy-MM-dd) of date range. Used with EndDate. Transactions whose dates fall within this date range will be included.

endDate
string or null <date-time>

End local date (yyyy-MM-dd) of date range. Used with StartDate. Transactions whose dates fall within this date range will be included.

cursor
string or null

Optional.
When there are additional results, the metadata nextCursor field should be passed to retrieve the next page of results.

limit
integer or null <int32>

The maximum number of results that should be returned.

businessUnitId
string or null <uuid>

The business unit id.

costCodeIds
Array of strings or null <uuid>

List of Cost Code Ids.

modifiedSince
string or null <date-time>

The modifiedSince datetime.

onlyTM
boolean or null

The onlyTM optional parameter to filter to T&M data.

Responses
post/api/v1/costTypes/materialInstalled/advancedRequest
Request samples
{
  • "jobIds": [
    ],
  • "jobTagIds": [
    ],
  • "foremanIds": [
    ],
  • "startDate": "2019-08-24T14:15:22Z",
  • "endDate": "2019-08-24T14:15:22Z",
  • "cursor": "string",
  • "limit": 0,
  • "businessUnitId": "214dd610-35bc-4504-9246-7073493e0400",
  • "costCodeIds": [
    ],
  • "modifiedSince": "2019-08-24T14:15:22Z",
  • "onlyTM": true
}
Response samples
application/json
{
  • "results": [
    ],
  • "metadata": {
    }
}

Returns received materials

Returns a list of received materials.

Securitybearer
Request
Request Body schema:

The request object for getting received materials.

jobIds
Array of strings or null <uuid>

List of Job Ids. Used with JobTagIds to limit jobs. Returns jobs with JobIds and JobTagIds.

jobTagIds
Array of strings or null <uuid>

List of Job Tag Ids. Used with JobIds to limit jobs. Returns jobs with JobIds and JobTagIds.

foremanIds
Array of strings or null <uuid>

List of Foreman Ids. Used to limit transactions. Returns transactions only for foremen specified.

startDate
string or null <date-time>

Beginning local date (yyyy-MM-dd) of date range. Used with EndDate. Transactions whose dates fall within this date range will be included.

endDate
string or null <date-time>

End local date (yyyy-MM-dd) of date range. Used with StartDate. Transactions whose dates fall within this date range will be included.

cursor
string or null

Optional.
When there are additional results, the metadata nextCursor field should be passed to retrieve the next page of results.

limit
integer or null <int32>

The maximum number of results that should be returned.

modifiedSince
string or null <date-time>

The modifiedSince datetime.

businessUnitId
string or null <uuid>

The business unit id.

Responses
post/api/v1/costTypes/materialReceived/advancedRequest
Request samples
{
  • "modifiedSince": "2021-01-01T00:00:00",
  • "businessUnitId": "81aa06f2-46ec-457f-9b35-ae6e05d4dbef",
  • "jobIds": [
    ],
  • "foremanIds": [
    ],
  • "startDate": "2021-01-01T00:00:00",
  • "endDate": "2021-12-31T00:00:00",
  • "limit": 500
}
Response samples
application/json
{
  • "results": [
    ],
  • "metadata": {
    }
}