Skip to content

Item types

Item types label the lines of invoices and estimates: Service, Product, or types you add. Invoices and estimates share one list. One type is the default for new lines that bill hours and fees, and one is the default for new lines that bill expenses.

Item types are shared by the whole business: everyone who may use them sees the same list. With your personal access token you can read item types if your permission profile lets you view the invoices module, and create, rename, delete or change the defaults if it lets you edit invoices. Administrators can do all of this. Members and managers can do what their permission profile grants; managing people adds nothing here. A client portal login is refused with 403.

One item type a line can carry.

Field Type Description
id string The item type’s id. Read only.
name string The name printed in the Item type column of invoice and estimate lines, 1 to 100 characters, unique in the business.
isDefaultForHours boolean Whether new lines for hours and fees get this type (Default for hours in the app). Exactly one type holds it; giving it to one type takes it from the type that held it.
isDefaultForExpenses boolean Whether new lines for expenses get this type (Default for expenses in the app). Exactly one type holds it; giving it to one type takes it from the type that held it.
position integer Where the type sits in the app’s list and pickers, counting from 1. Read only.
createdAt datetime When the type was created. Read only.
updatedAt datetime When the type last changed. Read only.

Returns the business’s item types in the order the app shows them, paged. A business always has at least one: if it has none yet, the first request creates Service (default for hours and fees) and Product (default for expenses).

GET /v1/item-types

Parameters

Parameter In Type Required Description
page query integer No Page number, default 1.
limit query integer No Rows per page, default 20, max 1000.
search query string No Matches part of the name.
updatedSince query datetime No Only item types changed at or after this moment. Records deleted since then are not reported.

Rules

  • 403 when the token’s person may not view the invoices module.

Example request

Terminal window
curl "https://api.onesuite.io/v1/item-types" \
-H "X-API-Key: $ONESUITE_TOKEN"

Example response — status 200

{
"data": [
{
"id": "cm1itype0service",
"name": "Service",
"isDefaultForHours": true,
"isDefaultForExpenses": false,
"position": 1,
"createdAt": "2026-03-02T08:15:00.000Z",
"updatedAt": "2026-03-02T08:15:00.000Z"
},
{
"id": "cm1itype0product",
"name": "Product",
"isDefaultForHours": false,
"isDefaultForExpenses": true,
"position": 2,
"createdAt": "2026-03-02T08:15:00.000Z",
"updatedAt": "2026-03-02T08:15:00.000Z"
},
{
"id": "cm1itype0hosting",
"name": "Hosting",
"isDefaultForHours": false,
"isDefaultForExpenses": false,
"position": 3,
"createdAt": "2026-11-20T10:02:11.000Z",
"updatedAt": "2026-11-20T10:02:11.000Z"
}
],
"totalCount": 3,
"page": 1,
"limit": 20
}

Returns one item type.

GET /v1/item-types/:id

Parameters

Parameter In Type Required Description
id path string Yes The item type’s id.

Rules

  • 403 when the token’s person may not view the invoices module.
  • 404 when no item type with this id exists in the business.

Example request

Terminal window
curl "https://api.onesuite.io/v1/item-types/cm1itype0service" \
-H "X-API-Key: $ONESUITE_TOKEN"

Example response — status 200

{
"data": {
"id": "cm1itype0service",
"name": "Service",
"isDefaultForHours": true,
"isDefaultForExpenses": false,
"position": 1,
"createdAt": "2026-03-02T08:15:00.000Z",
"updatedAt": "2026-03-02T08:15:00.000Z"
}
}

Adds an item type at the end of the list. It can be used on invoice and estimate lines straight away.

POST /v1/item-types

Parameters

Parameter In Type Required Description
name body string Yes The name, 1 to 100 characters, unique in the business.
isDefaultForHours body boolean No Make it the default for new lines that bill hours and fees. Default false.
isDefaultForExpenses body boolean No Make it the default for new lines that bill expenses. Default false.

Rules

  • 403 when the token’s person may not edit invoices.
  • 400 when the name is empty or longer than 100 characters.
  • 409 when another item type already has this name.
  • Making it a default takes that default from the type that held it.
  • Answers 201 with the new type.

Example request

Terminal window
curl "https://api.onesuite.io/v1/item-types" \
-X POST \
-H "X-API-Key: $ONESUITE_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"Hosting"}'

Example response — status 201

{
"data": {
"id": "cm1itype0hosting",
"name": "Hosting",
"isDefaultForHours": false,
"isDefaultForExpenses": false,
"position": 3,
"createdAt": "2026-11-20T10:02:11.000Z",
"updatedAt": "2026-11-20T10:02:11.000Z"
}
}

Changes the fields you send: renames an item type or makes it a default. A new name shows on every invoice and estimate line that uses the type.

PATCH /v1/item-types/:id

Parameters

Parameter In Type Required Description
id path string Yes The item type’s id.
name body string No The new name, 1 to 100 characters, unique in the business.
isDefaultForHours body boolean No Send true to make it the default for new lines that bill hours and fees.
isDefaultForExpenses body boolean No Send true to make it the default for new lines that bill expenses.

Rules

  • 403 when the token’s person may not edit invoices.
  • 404 when no item type with this id exists in the business.
  • 400 when the name is empty or longer than 100 characters.
  • 409 when another item type already has this name.
  • Making it a default takes that default from the type that held it.
  • Answers 200 with the updated item type.

Example request

Terminal window
curl "https://api.onesuite.io/v1/item-types/cm1itype0hosting" \
-X PATCH \
-H "X-API-Key: $ONESUITE_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"Hosting & domains"}'

Example response — status 200

{
"data": {
"id": "cm1itype0hosting",
"name": "Hosting & domains",
"isDefaultForHours": false,
"isDefaultForExpenses": false,
"position": 3,
"createdAt": "2026-11-20T10:02:11.000Z",
"updatedAt": "2026-11-20T10:30:00.000Z"
}
}

Deletes an item type that no invoice or estimate line uses.

DELETE /v1/item-types/:id

Parameters

Parameter In Type Required Description
id path string Yes The item type’s id.

Rules

  • 403 when the token’s person may not edit invoices.
  • 404 when no item type with this id exists in the business.
  • 409 when any invoice or estimate line uses it.
  • 409 when it is the business’s last item type; a business needs at least one.
  • Answers 200 with a confirmation message.

Example request

Terminal window
curl "https://api.onesuite.io/v1/item-types/cm1itype0hosting" \
-X DELETE \
-H "X-API-Key: $ONESUITE_TOKEN"

Example response — status 200

{
"message": "Item type deleted"
}