Employee expenses

Expense report header for employee expense lines. Employees create and submit expense reports, consisting of individual line items, to receive reimbursement for approved out-of-pocket costs related to their jobs.

The employees' managers must then approve the expenses. After approval, the expense reports become reimbursement request candidates for the accounting department to process into pending reimbursements, from which checks are printed.

Please be aware that this object is currently "Uncertified", signifying that it has not undergone the complete review process and the design may change during ongoing refinement. Users are advised to exercise discretion in using this object and are encouraged to provide feedback.

List employee expenses

get/objects/expenses/employee-expense

Returns up to 100 employee expense objects from the collection with a key, ID, and link for each expense. This operation is mostly for use in testing; use the query service to find expense objects that meet certain criteria and to specify the properties that are returned.

Permissions and other requirements
SubscriptionTime & Expenses
User typeBusiness, Employee, Project Manager (Projects subscription)
PermissionsList and View Expenses
SecurityOAuth2
Responses
200

OK

400

Bad Request

Request samples
Response samples
application/json
{
  • "ia::result": [
    • {
      • "key": "84",
      • "id": "EXP-00001",
      • "href": "/objects/expenses/employee-expense/84"
      },
    • {
      • "key": "85",
      • "id": "EXP-00002",
      • "href": "/objects/expenses/employee-expense/85"
      },
    • {
      • "key": "60",
      • "id": "EXP-00003",
      • "href": "/objects/expenses/employee-expense/60"
      }
    ],
  • "ia::meta": {
    • "totalCount": 3,
    • "totalSuccess": 3,
    • "totalError": 0,
    • "start": 1,
    • "pageSize": 5,
    • "next": 0,
    • "previous": 0
    }
}

Create an employee expense

post/objects/expenses/employee-expense

Creates a new employee expense. You must specify a unique employee expense ID when creating an employee expense unless document sequencing is configured, in which case the ID is auto-generated.

Permissions and other requirements
SubscriptionTime & Expenses
User typeBusiness, Employee
PermissionsAdd Expenses
SecurityOAuth2
Request
Request Body schema: application/json

Creates an employee expense

createdDate
required
string <date>

Date the employee expense was created.

Example: "2024-11-11"
required
object

Employee that incurred the expense.

key
string

Unique key for the employee.

Example: "12345"
id
string

Unique identifier for the employee.

Example: "EMP-025"
required
Array of objects

Line items of the employee expense.

Array
entryDate
string or null <date>

Date that the expense was incurred.

Example: "2021-01-23"
txnCurrency
string or null

Transaction currency. For multi-currency companies.

Example: "INR"
txnAmount
string <decimal-precision-2>

Transaction amount. For multi-currency companies.

Example: "123.45"
quantity
string or null <decimal-precision-2>

Quantity for a rate-based expense such as mileage.

Example: "5.75"
unitRate
string or null <decimal-precision-2>

Monetary amount for a rate-based expense, such as mileage.

Example: "20.00"
paidTo
string or null

Notes regarding to whom the amount was paid.

Example: "Hotel Westin"
paidFor
string or null

Notes regarding what the expense was for.

Example: "2024 Hawaii Conference"
object

General ledger account associated with the line item. Used when no expense type is assigned.

object

An expense type defined in the company.

object

Details of the conversion to base currency. For multi-currency companies.

isBillable
boolean
Default: false

Indicates whether a line item is billable.

Example: false
object

Form 1099 information for the line item.

object

The payment type defined in employee-expense-payment-type.

object
object
state
string
Default: "submitted"

Status of the employee expense in its life cycle. Expenses are posted to the general ledger when approved.

Enum: "approved" "confirmed" "declined" "draft" "paid" "partiallyApproved" "partiallyDeclined" "partiallyPaid" "posted" "reversal" "reversalPending" "reversed" "submitted" "voided"
Example: "draft"
object

Base payment details for the employee expense report.

baseCurrency
string

Base currency used for the expense report and determined by company currency used for reporting.

Example: "USD"
object

Reimbursement details.

reimbursementCurrency
string

The currency used to pay for the expense. For multi-currency companies.

Example: "EUR"
expenseReportNumber
string

Report number associated with the employee expense.

Example: "EXP-00001"
object

Expense summary that this expense is reported on.

key
string

Unique key for the employee expense summary.

Example: "334"
id
string

Unique identifier for the expense summary.

Example: "334"
postingDate
string <date>

GL posting date.

Example: "2024-01-23"
memo
string

Memo.

Example: "Paid to employee"
description
string

Reason for the expense.

Example: "Supplies for customer training"
reclassificationNotes
string

If an expense is reclassified, reason for the reclassification.

Example: "Classified as supplies, not travel expense"
object

An attachment for employee expenses.(Company subscription with permissions to Add and Edit Attachments.)

key
string

Unique key for the attachment.

Example: "25"
id
string

Unique identifier for the attachment.

Example: "1"
Responses
201

Created

400

Bad Request

Request samples
application/json
{
  • "state": "submitted",
  • "expenseReportNumber": "EXP-00001",
  • "employee": {
    • "id": "10"
    },
  • "createdDate": "2021-03-11",
  • "expenseSummary": {
    • "postingDate": "2021-01-31",
    • "title": "Expenses - Q1 batch"
    },
  • "basePaymentInformation": {
    • "baseCurrency": "USD"
    },
  • "reimbursementInformation": {
    • "reimbursementCurrency": "EUR"
    },
  • "description": "Travel expense",
  • "memo": "Paid to employee",
  • "lines": [
    • {
      • "account": null,
      • "id": "6775.30",
      • "paidTo": "paid To",
      • "paidFor": "paid For",
      • "isBillable": false,
      • "form1099": {
        },
      • "paymentType": {
        },
      • "quantity": "10",
      • "unitrate": "20",
      • "txnCurrency": "INR",
      • "txnAmount": "100",
      • "transactionToReimburseConversion": {
        },
      • "dimensions": {
        }
      }
    ]
}
Response samples
application/json
{
  • "ia::result": {
    • "key": "124",
    • "id": "124",
    • "href": "/objects/expenses/employee-expense/124"
    },
  • "ia::meta": {
    • "totalCount": 1
    }
}

Get an employee expense

get/objects/expenses/employee-expense/{key}

Returns detailed information for a specified employee expense.

Permissions and other requirements
SubscriptionTime & Expenses
User typeBusiness, Employee, Project Manager (Projects subscription)
PermissionsList and View Expenses
SecurityOAuth2
Request
path Parameters
key
required
string

System-assigned key for the employee-expense.

Responses
200

OK

400

Bad Request

Request samples
Response samples
application/json
{
  • "ia::result": {
    • "expenseReportNumber": "ER-0152",
    • "employee": {
      • "id": "10",
      • "key": "10",
      • "href": "/objects/company-config/employee/10"
      },
    • "employeeContact": {
      • "key": "977",
      • "id": "Thomas Glenn",
      • "firstName": "Thomas",
      • "lastName": "Glenn",
      • "href": "/objects/company-config/contact/977"
      },
    • "key": "124",
    • "id": "124",
    • "createdDate": "2021-03-11",
    • "expenseSummary": {
      • "postingDate": "2021-01-31",
      • "title": "Expenses - Q1 batch",
      • "key": "3",
      • "id": "3",
      • "href": "/objects/expenses/employee-expense-summary/3"
      },
    • "basePaymentInformation": {
      • "totalEntered": "1.38",
      • "totalPaid": "0",
      • "totalSelected": "0",
      • "totalDue": "1.38",
      • "baseCurrency": "USD"
      },
    • "state": "approved",
    • "reimbursementInformation": {
      • "totalEntered": "1.16",
      • "totalSelected": "0",
      • "totalPaid": "0",
      • "totalDue": "1.16",
      • "reimbursementCurrency": "EUR"
      },
    • "description": "Supplies for customer training",
    • "nonReimbursable": {
      • "baseTotalEntered": "0",
      • "reimbursementTotalEntered": "0"
      },
    • "lines": [
      • {
        }
      ],
    • "memo": "Covered by customer",
    • "entity": {
      • "key": "46",
      • "id": "Western Region",
      • "name": "Western Region",
      • "href": "/objects/company-config/entity/46"
      },
    • "href": "/objects/expenses/employee-expense/124"
    },
  • "ia::meta": {
    • "totalCount": 1,
    • "totalSuccess": 1,
    • "totalError": 0
    }
}

Update an employee expense

patch/objects/expenses/employee-expense/{key}

Updates an existing employee expense by setting field values. Any fields not provided remain unchanged.

Permissions and other requirements
SubscriptionTime & Expenses
User typeBusiness, Employee
PermissionsEdit Expenses
SecurityOAuth2
Request
path Parameters
key
required
string

System-assigned key for the employee-expense.

Request Body schema: application/json
createdDate
string <date>

Date the employee expense was created.

Example: "2024-11-11"
object

Employee that incurred the expense.

key
string

Unique key for the employee.

Example: "12345"
id
string

Unique identifier for the employee.

Example: "EMP-025"
state
string
Default: "submitted"

Status of the employee expense in its life cycle. Expenses are posted to the general ledger when approved.

Enum: "approved" "confirmed" "declined" "draft" "paid" "partiallyApproved" "partiallyDeclined" "partiallyPaid" "posted" "reversal" "reversalPending" "reversed" "submitted" "voided"
Example: "draft"
object

Base payment details for the employee expense report.

baseCurrency
string

Base currency used for the expense report and determined by company currency used for reporting.

Example: "USD"
object

Reimbursement details.

expenseReportNumber
string

Report number associated with the employee expense.

Example: "EXP-00001"
object

Expense summary that this expense is reported on.

key
string

Unique key for the employee expense summary.

Example: "334"
id
string

Unique identifier for the expense summary.

Example: "334"
postingDate
string <date>

GL posting date.

Example: "2024-01-23"
memo
string

Memo.

Example: "Paid to employee"
description
string

Reason for the expense.

Example: "Supplies for customer training"
reclassificationNotes
string

If an expense is reclassified, reason for the reclassification.

Example: "Classified as supplies, not travel expense"
object

An attachment for employee expenses.(Company subscription with permissions to Add and Edit Attachments.)

key
string

Unique key for the attachment.

Example: "25"
id
string

Unique identifier for the attachment.

Example: "1"
Array of objects

Line items of the employee expense.

Array
entryDate
string or null <date>

Date that the expense was incurred.

Example: "2021-01-23"
txnCurrency
string or null

Transaction currency. For multi-currency companies.

Example: "INR"
txnAmount
string <decimal-precision-2>

Transaction amount. For multi-currency companies.

Example: "123.45"
quantity
string or null <decimal-precision-2>

Quantity for a rate-based expense such as mileage.

Example: "5.75"
unitRate
string or null <decimal-precision-2>

Monetary amount for a rate-based expense, such as mileage.

Example: "20.00"
paidTo
string or null

Notes regarding to whom the amount was paid.

Example: "Hotel Westin"
paidFor
string or null

Notes regarding what the expense was for.

Example: "2024 Hawaii Conference"
object

General ledger account associated with the line item. Used when no expense type is assigned.

object

An expense type defined in the company.

object

Details of the conversion to base currency. For multi-currency companies.

isBillable
boolean
Default: false

Indicates whether a line item is billable.

Example: false
object

Form 1099 information for the line item.

object

The payment type defined in employee-expense-payment-type.

object
object
Responses
200

OK

400

Bad Request

Request samples
application/json
{
  • "memo": "Covered by customer"
}
Response samples
application/json
{
  • "ia::result": {
    • "key": "124",
    • "id": "124",
    • "href": "/objects/expenses/employee-expense/124"
    },
  • "ia::meta": {
    • "totalCount": 1,
    • "totalSuccess": 1,
    • "totalError": 0
    }
}

Delete an employee expense

delete/objects/expenses/employee-expense/{key}

Deletes an employee expense.

Permissions and other requirements
SubscriptionTime & Expenses
User typeBusiness, Employee
PermissionsDelete Expenses
SecurityOAuth2
Request
path Parameters
key
required
string

System-assigned key for the employee-expense.

Responses
204

No Content

400

Bad Request

Request samples
Response samples
application/json
{
  • "ia::result": {
    • "ia::error": {
      • "code": "invalidRequest",
      • "message": "A POST request requires a payload",
      • "errorId": "REST-1028",
      • "additionalInfo": {
        },
      • "supportId": "Kxi78%7EZuyXBDEGVHD2UmO1phYXDQAAAAo"
      }
    },
  • "ia::meta": {
    • "totalCount": 1,
    • "totalSuccess": 0,
    • "totalError": 1
    }
}

Query employee expenses

post/services/core/query

Queries an object for filtered data.

SecurityOAuth2
Request
Request Body schema: application/json
object
string

Object type to query, in the form <application-name>/<object name>. For custom objects use platform-apps/nsp::<object-name>.

Example: "expenses/employee-expense"
fields
Array of strings

List of fields to include in the response. Can be any combination of these:

  • The name of a field in the object that you are querying, such as id.

  • The name of a field in a related object, using the form relatedObjectName.fieldName, such as vendor.id.

  • The result of an aggregate function run against the values in the returned objects. Use the form function:fieldName, such as min:startDate to return the earliest starting date. Valid function names are:

    • count
    • avg
    • sum
    • min
    • max
  • The result of an aggregate function run against the values in related objects, using the form function:relatedObjectName.fieldName, such as max:vendor.creditLimit. The same functions are supported as for object fields.

Example: ["key","id","max:vendor.creditLimit"]
Array of equal (object) or not equal (object) or less than (object) or (less than or equal (object)) or greater than (object) or (greater than or equal (object)) or in (object) or not in (object) or between (object) or not between (object) or contains (object) or does not contain (object) or starts with (object) or does not start with (object) or ends with (object) or does not end with (object)

Filter conditions to select the objects to return based on their field values. You use operators and conditions to build your filter, such as {"$eq":{"status":"active"}} to select objects in which status is equal to "active".

Example: [{"$eq":{"status":"active"}},{"$gt":{"totalDue":"1000"}},{"$contains":{"name":"Acme"}}]
Array
Any of:

Field value must be equal to this specified value.

For date fields, you can use these macro values that are relative to the current date or the asOfDate in filterParameters, if set:

  • today
  • currentWeek
  • currentMonth
  • currentQuarter
  • currentYear
  • yesterday
  • lastWeek
  • priorMonth
  • priorQuarter
  • priorYear

These are most useful for queries that you want to save and use repeatedly, such as for views or reports. Just change the asOfDate each time to retrieve the same data set for different time periods.

For example, {"eq":{"postingDate":"priorYear"}}.

object

The field name and value to be compared with object values.

Example: {"status":"active"}
filterExpression
string
Default: "and"

Logical operators to apply when there are multiple filter conditions. The conditions in the filters array are implicitly numbered starting at 1. Supports and, or, and grouping with parentheses.

Shortcuts:

  • and by itself means that all conditions must be true.
  • or by itself means that at least one condition must be true.
Example: "(1 and 2) or 3"
object

Pre-defined filter options.

asOfDate
string <date>

The "as of" date to use with any relative date comparisons in filters. For example, if asOfDate is set to "2022-04-01" then priorMonth will be "03".

The current date is used if asOfDate is not set.

Example: "2022-04-01"
includeHierarchyFields
boolean
Default: false

Set to true to include hierarchical structure information with each object in the response.

Example: false
caseSensitiveComparison
boolean
Default: true

Queries are case-sensitive by default. Set to false to ignore case in a query.

Example: true
includePrivate
boolean
Default: false

By default, in a multi-entity company, queries from the top-level entity do not access data in private entities. Set includePrivate to true if you want to query data in private entities.

Example: false
Array of objects

Set the order of the results by specifying field names to sort by and whether they should be in ascending or descending order.

Example: [{"totalDue":"asc"},{"lastPaymentMadeDate":"desc"}]
Array
property name*
additional property
string
Enum: "asc" "desc"
start
integer

First record of the result set to include in the response.

Example: 1
size
integer

Number of records to include in the response.

Example: 100
Responses
200

OK

400

Bad Request

Request samples
application/json
{
  • "object": "expenses/employee-expense",
  • "filters": [
    • {
      • "$eq": null,
      • "employee.name": "Dosorio"
      }
    ],
  • "fields": [
    • "key",
    • "id",
    • "reimbursement.totalPaid",
    • "href"
    ],
  • "orderBy": [
    • {
      • "id": "asc"
      }
    ]
}
Response samples
application/json
{
  • "ia::result": [
    • {
      • "key": "880",
      • "id": "880",
      • "reimbursement.totalPaid": "0.00",
      • "href": "/objects/expenses/employee-expense/880"
      },
    • {
      • "key": "881",
      • "id": "881",
      • "reimbursement.totalPaid": "0.00",
      • "href": "/objects/expenses/employee-expense/881"
      },
    • {
      • "key": "883",
      • "id": "883",
      • "reimbursement.totalPaid": "0.00",
      • "href": "/objects/expenses/employee-expense/883"
      }
    ],
  • "ia::meta": {
    • "totalCount": 3,
    • "start": 1,
    • "pageSize": 100,
    • "next": null,
    • "previous": null
    }
}