expenses

Gets a new blank expense object

Changed on

Returns a blank object with default values

get/api/v1/expenses/create

Request

Query parameters

includestring
Example:first_load

Includes child relationships in the response, format is comma separated. Check each model for the list of associated includes

Headers

X-API-TOKENstring required
Example:TOKEN

The API token to be used for authentication

X-Requested-Withstring required
Example:XMLHttpRequest

Used to send the XMLHttpRequest header

Response

A blank expense object

idstring

The expense hashed id

user_idstring

The user hashed id

assigned_user_idstring

The assigned user hashed id

project_idstring

The associated project_id

client_idstring

The client hashed id

invoice_idstring

The related invoice hashed id

bank_idstring

The bank id related to this expense

invoice_currency_idstring

The currency id of the related invoice

currency_idstring

The currency id of the expense

invoice_category_idstring

The invoice category id

payment_type_idstring

The payment type id

recurring_expense_idstring

The related recurring expense this expense was created from

private_notesstring

The private notes of the expense

public_notesstring

The public notes of the expense

transaction_referencestring

The transaction references of the expense

transcation_idstring

The transaction id of the expense

custom_value1string

A custom value

custom_value2string

A custom value

custom_value3string

A custom value

custom_value4string

A custom value

tax_amountnumber

The tax amount

tax_name1string

Tax Name 1

tax_name2string

Tax Name 2

tax_name3string

Tax Name 3

tax_rate1number float

Tax rate 1

tax_rate2number float

Tax rate 2

tax_rate3number float

Tax rate 3

amountnumber float

The total expense amont

foreign_amountnumber float

The total foreign amount of the expense

exchange_ratenumber float

The exchange rate at the time of the expense

datestring

The expense date format Y-m-d

payment_datestring

The date of payment for the expense, format Y-m-d

should_be_invoicedboolean

Flag whether the expense should be invoiced

is_deletedboolean

Boolean determining whether the expense has been deleted

invoice_documentsboolean

Passing the expense documents over to the invoice

updated_atnumber

Timestamp

archived_atnumber

Timestamp

calculate_tax_by_amountboolean

Flag indicating whether to calculate tax based on amount rather than percentage

category_idstring

The unique identifier of the expense category

numberstring

The unique number assigned to this expense

purchase_order_idstring

The unique identifier of the associated purchase order

tax_amount1number float

The amount of the first tax

tax_amount2number float

The amount of the second tax

tax_amount3number float

The amount of the third tax

transaction_idstring

The unique identifier of the transaction

uses_inclusive_taxesboolean

Flag indicating whether taxes are included in the price

vendor_idstring

The unique identifier of the vendor associated with this expense

Example response

{
  "id": "Opnel5aKBz",
  "user_id": "Opnel5aKBz",
  "assigned_user_id": "Opnel5aKBz",
  "project_id": "Opnel5aKBz",
  "client_id": "Opnel5aKBz",
  "invoice_id": "Opnel5aKBz",
  "invoice_currency_id": "1",
  "currency_id": "2",
  "invoice_category_id": "Opnel5aKBz",
  "recurring_expense_id": "Opnel5aKBz",
  "tax_amount": 10,
  "tax_name1": "GST",
  "tax_name2": "VAT",
  "tax_name3": "IVA",
  "tax_rate1": 10,
  "tax_rate2": 10,
  "tax_rate3": 10,
  "amount": 10,
  "foreign_amount": 10,
  "exchange_rate": 0.8,
  "date": "2022-12-01",
  "payment_date": "2022-12-01",
  "should_be_invoiced": true,
  "is_deleted": true,
  "invoice_documents": true,
  "updated_at": 1434342123,
  "archived_at": 1434342123,
  "calculate_tax_by_amount": true,
  "category_id": "Opnel5aKBz",
  "number": "EXP-0001",
  "purchase_order_id": "Opnel5aKBz",
  "tax_amount1": 10,
  "tax_amount2": 5,
  "tax_amount3": 2.5,
  "transaction_id": "txn_1234567890",
  "uses_inclusive_taxes": true,
  "vendor_id": "Opnel5aKBz"
}

Changes

    • info

      the response optional property became read-only for the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status