CostCode

Creates a new cost code.

Creates a new cost code, using its code as a unique identifier on the specified job and business unit.

For help with authorization, please visit https://developer.hcssapps.com/getting-started/request-tokens

Securitybearer
Request
Request Body schema: application/json

The cost code.

code
required
string

Gets the cost code code. This is a required field.

businessUnitCode
required
string

Gets the business unit. This is a required field.

jobCode
required
string

Gets job code. This is a required field.

id
string or null <uuid>

The Id of the cost code.

quantity
number or null <double>

The quantity.

description
string or null

The cost code description.

unitOfMeasurement
string or null

The unit of measure.

laborHours
number or null <double>

The labor hours.

equipmentHours
number or null <double>

The equipment hours.

laborDollars
number or null <double>

The labor cost.

equipmentDollars
number or null <double>

The equipment cost.

materialDollars
number or null <double>

The material cost.

subcontractDollars
number or null <double>

The subcontract cost.

supplyDollars
number or null <double>

The supply cost.

Array of objects or null (DisTag)

The cost code tags.

status
string or null

The cost code status. Items Enum: "A" for Active, "C" for Completed, "I" for Inactive

accountingCode
string or null

The accounting code.

category
string or null

"Category" accounting field.

criticalPathMethod
string or null

"CPM Code" accounting field.

generalLedgerAccount
string or null

"GL Acct" accounting field.

subJob
string or null

"Sub-Job" accounting field.

workBreakdownStructureCode
string or null

"WBS Code" accounting field.

note
string or null

The cost code note.

estimateResources
string or null

The estimate resources.

historyCode
string or null

The historical activity code.

historicalBidItem
string or null

The historical bid item.

heavyBidEstimateCode
string or null

The HeavyBid estimate code.

isTM
boolean or null

The flag indicating whether the cost code is a time-and-material item.

workType
string or null

The work type.

payItemNumber
string or null

The pay item number.

payItemFactor
number or null <double>

Any costs contributed by this cost code are multiplied by this factor before being applied to its parent pay item.

isPayItemDriver
boolean or null

Whether this cost code contributes to the cost of its parent pay item.

accountingTemplateName
string or null

The accounting template name.

isCapExpected
boolean or null

The flag indicating whether to set the cost code to cap expected.

isHiddenFromMobile
boolean or null

The flag indicating whether cost code is hidden from mobile.

Responses
post/api/v1/CostCode
Request samples
application/json
{
  • "code": "8530000z",
  • "businessUnitCode": "manager",
  • "jobCode": "Z3924",
  • "id": "af8d7c49-35de-4266-b603-02f238f9fae1",
  • "quantity": 1.5,
  • "description": "Purchase Pipe Materials",
  • "unitOfMeasurement": "LS",
  • "laborHours": 0.5,
  • "equipmentHours": 0.5,
  • "laborDollars": 0.5,
  • "equipmentDollars": 0.5,
  • "materialDollars": 60311.92,
  • "subcontractDollars": 0.5,
  • "supplyDollars": 0.5,
  • "tags": [
    ],
  • "status": "A",
  • "accountingCode": "135z",
  • "category": "Category",
  • "criticalPathMethod": "CPM Code",
  • "generalLedgerAccount": "GL Acct",
  • "subJob": "Sub-Job",
  • "workBreakdownStructureCode": "WBS Code",
  • "note": "12P - 413",
  • "estimateResources": "01z",
  • "historyCode": "HistCode",
  • "historicalBidItem": "HistBidItem",
  • "heavyBidEstimateCode": "HBEstiMateCode",
  • "isTM": false,
  • "workType": "G",
  • "payItemNumber": "PayItem1",
  • "payItemFactor": 2.1,
  • "isPayItemDriver": true,
  • "accountingTemplateName": "default",
  • "isCapExpected": false,
  • "isHiddenFromMobile": false
}

Returns a list of cost codes.

Returns a list of cost codes for the specified business unit code, job code, and accounting template.

For help with authorization, please visit https://developer.hcssapps.com/getting-started/request-tokens

Securitybearer
Request
query Parameters
businessUnitCode
required
string

The business unit code.

Example: businessUnitCode=MANAGER
jobCode
required
string

The job code.

Example: jobCode=JOB123
accountingTemplateName
string
Default: ""

The accounting template name. If blank or unspecified, the primary accounting template for the business unit is used.

Example: accountingTemplateName=MAINTEMPLATE
Responses
get/api/v1/CostCode
Request samples
Response samples
application/json
[
  • {
    }
]

Creates and updates cost codes.

This call also requires heavyjob:write scope.

For help with authorization, please visit https://developer.hcssapps.com/getting-started/request-tokens

Securitybearer
Request
Request Body schema:
required

The list of cost codes.

Array ([ 1 .. 100 ] items)
businessUnitCode
required
string

The business unit code. This is a required field.

jobCode
required
string

The job code. This is a required field.

code
required
string

The cost code code. This is a required field.

status
required
string

The cost code status. Items Enum: "A" for Active, "C" for Completed, "I" for Inactive

description
string or null

The cost code description.

quantity
number or null <double>

The quantity.

unitOfMeasure
string or null

The unit of measure.

laborHours
number or null <double>

The labor hours.

equipmentHours
number or null <double>

The equipment hours.

laborDollars
number or null <double>

The labor cost.

equipmentDollars
number or null <double>

The equipment cost.

materialDollars
number or null <double>

The material cost.

subcontractDollars
number or null <double>

The subcontract cost.

supplyDollars
number or null <double>

The supply cost.

note
string or null

The cost code note.

historicalActivityCode
string or null

The historical activity code.

isTm
boolean or null

The flag indicating whether the cost code is a time-and-material item.

isHiddenFromMobile
boolean or null

The flag indicating whether the cost code is hidden from mobile. Default is false.

isCapExpected
boolean or null

The flag indicating whether to set the cost code to cap expected. Default is true.

Responses
204

No Content

patch/api/v1/CostCode
Request samples
[
  • {
    }
]

Updates an existing cost code by its id.

After the result of this operation, the server entity will match exactly what is sent here. (i.e., excluded fields will be interpreted as "not needed" and deleted from the server)

For help with authorization, please visit https://developer.hcssapps.com/getting-started/request-tokens

Securitybearer
Request
path Parameters
id
required
string <uuid>

The cost code guid.

Request Body schema: application/json

The cost code.

code
required
string

Gets the cost code code. This is a required field.

businessUnitCode
required
string

Gets the business unit. This is a required field.

jobCode
required
string

Gets job code. This is a required field.

id
string or null <uuid>

The Id of the cost code.

quantity
number or null <double>

The quantity.

description
string or null

The cost code description.

unitOfMeasurement
string or null

The unit of measure.

laborHours
number or null <double>

The labor hours.

equipmentHours
number or null <double>

The equipment hours.

laborDollars
number or null <double>

The labor cost.

equipmentDollars
number or null <double>

The equipment cost.

materialDollars
number or null <double>

The material cost.

subcontractDollars
number or null <double>

The subcontract cost.

supplyDollars
number or null <double>

The supply cost.

Array of objects or null (DisTag)

The cost code tags.

status
string or null

The cost code status. Items Enum: "A" for Active, "C" for Completed, "I" for Inactive

accountingCode
string or null

The accounting code.

category
string or null

"Category" accounting field.

criticalPathMethod
string or null

"CPM Code" accounting field.

generalLedgerAccount
string or null

"GL Acct" accounting field.

subJob
string or null

"Sub-Job" accounting field.

workBreakdownStructureCode
string or null

"WBS Code" accounting field.

note
string or null

The cost code note.

estimateResources
string or null

The estimate resources.

historyCode
string or null

The historical activity code.

historicalBidItem
string or null

The historical bid item.

heavyBidEstimateCode
string or null

The HeavyBid estimate code.

isTM
boolean or null

The flag indicating whether the cost code is a time-and-material item.

workType
string or null

The work type.

payItemNumber
string or null

The pay item number.

payItemFactor
number or null <double>

Any costs contributed by this cost code are multiplied by this factor before being applied to its parent pay item.

isPayItemDriver
boolean or null

Whether this cost code contributes to the cost of its parent pay item.

accountingTemplateName
string or null

The accounting template name.

isCapExpected
boolean or null

The flag indicating whether to set the cost code to cap expected.

isHiddenFromMobile
boolean or null

The flag indicating whether cost code is hidden from mobile.

Responses
put/api/v1/CostCode/{id}
Request samples
application/json
{
  • "code": "8530000z",
  • "businessUnitCode": "manager",
  • "jobCode": "Z3924",
  • "id": "af8d7c49-35de-4266-b603-02f238f9fae1",
  • "quantity": 1.5,
  • "description": "Purchase Pipe Materials",
  • "unitOfMeasurement": "LS",
  • "laborHours": 0.5,
  • "equipmentHours": 0.5,
  • "laborDollars": 0.5,
  • "equipmentDollars": 0.5,
  • "materialDollars": 60311.92,
  • "subcontractDollars": 0.5,
  • "supplyDollars": 0.5,
  • "tags": [
    ],
  • "status": "A",
  • "accountingCode": "135z",
  • "category": "Category",
  • "criticalPathMethod": "CPM Code",
  • "generalLedgerAccount": "GL Acct",
  • "subJob": "Sub-Job",
  • "workBreakdownStructureCode": "WBS Code",
  • "note": "12P - 413",
  • "estimateResources": "01z",
  • "historyCode": "HistCode",
  • "historicalBidItem": "HistBidItem",
  • "heavyBidEstimateCode": "HBEstiMateCode",
  • "isTM": false,
  • "workType": "G",
  • "payItemNumber": "PayItem1",
  • "payItemFactor": 2.1,
  • "isPayItemDriver": true,
  • "accountingTemplateName": "default",
  • "isCapExpected": false,
  • "isHiddenFromMobile": false
}