Skip to main content
GET
/
accounting
/
expenses
Get All Expenses
curl --request GET \
  --url https://api.rootfi.dev/v3/accounting/expenses \
  --header 'api_key: <api-key>'
{
  "data": [
    {
      "rootfi_id": 157,
      "rootfi_created_at": "2024-01-22T05:07:31.465Z",
      "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
      "rootfi_company_id": 1089,
      "platform_id": "123456",
      "rootfi_deleted_at": "2023-11-07T05:31:56Z",
      "platform_unique_id": "<string>",
      "raw_data": {},
      "data_hash": "<string>",
      "contact_id": "<string>",
      "account_id": "<string>",
      "document_number": "<string>",
      "posted_date": "<string>",
      "payment_mode": "<string>",
      "currency_id": "<string>",
      "currency_rate": 123,
      "total_amount": 123,
      "sub_total": 123,
      "tax_amount": 123,
      "total_discount": 123,
      "memo": "<string>",
      "updated_at": "<string>",
      "line_items": [
        {
          "rootfi_id": 123,
          "platform_id": "<string>",
          "line_item_type": "BILLS",
          "line_item_type_id": "<string>",
          "tracking_category_ids": [
            "<string>"
          ],
          "project_id": "<string>",
          "item_id": "<string>",
          "item": {
            "rootfi_id": 157,
            "rootfi_created_at": "2024-01-22T05:07:31.465Z",
            "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
            "rootfi_company_id": 1089,
            "platform_id": "123456",
            "rootfi_deleted_at": "2023-11-07T05:31:56Z",
            "platform_unique_id": "<string>",
            "raw_data": {},
            "data_hash": "<string>",
            "name": "<string>",
            "description": "<string>",
            "status": "ACTIVE",
            "type": "INVENTORY",
            "code": "<string>",
            "quantity_on_hand": 123,
            "is_bill_item": true,
            "bill_item": {
              "tax_id": "<string>",
              "account_id": "<string>",
              "unit_price": 123,
              "description": "<string>"
            },
            "is_invoice_item": true,
            "invoice_item": {
              "tax_id": "<string>",
              "account_id": "<string>",
              "unit_price": 123,
              "description": "<string>"
            },
            "updated_at": "<string>"
          },
          "tax_id": "<string>",
          "tax": {
            "rootfi_id": 157,
            "rootfi_created_at": "2024-01-22T05:07:31.465Z",
            "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
            "rootfi_company_id": 1089,
            "platform_id": "123456",
            "rootfi_deleted_at": "2023-11-07T05:31:56Z",
            "platform_unique_id": "<string>",
            "raw_data": {},
            "data_hash": "<string>",
            "name": "<string>",
            "code": "<string>",
            "tax_type": "<string>",
            "effective_tax_rate": 123,
            "total_tax_rate": 123,
            "components": [
              {
                "name": "<string>",
                "rate": 123,
                "tax_agency": "<string>",
                "is_compound": true
              }
            ],
            "updated_at": "<string>"
          },
          "account_id": "<string>",
          "account": {
            "rootfi_id": 157,
            "rootfi_created_at": "2024-01-22T05:07:31.465Z",
            "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
            "rootfi_company_id": 1089,
            "platform_id": "123456",
            "rootfi_deleted_at": "2023-11-07T05:31:56Z",
            "platform_unique_id": "<string>",
            "raw_data": {},
            "data_hash": "<string>",
            "name": "<string>",
            "description": "<string>",
            "nominal_code": "<string>",
            "current_balance": 123,
            "updated_at": "<string>",
            "status": "<string>",
            "category": "ASSET",
            "sub_category": "<string>",
            "currency_id": "<string>",
            "parent_account_id": "<string>",
            "parent_account": {
              "rootfi_id": 157,
              "rootfi_created_at": "2024-01-22T05:07:31.465Z",
              "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
              "rootfi_company_id": 1089,
              "platform_id": "123456",
              "rootfi_deleted_at": "2023-11-07T05:31:56Z",
              "platform_unique_id": "<string>",
              "raw_data": {},
              "data_hash": "<string>",
              "name": "<string>",
              "description": "<string>",
              "nominal_code": "<string>",
              "current_balance": 123,
              "updated_at": "<string>",
              "status": "<string>",
              "category": "ASSET",
              "sub_category": "<string>",
              "currency_id": "<string>",
              "parent_account_id": "<string>"
            },
            "currency": {
              "rootfi_id": 157,
              "rootfi_created_at": "2024-01-22T05:07:31.465Z",
              "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
              "rootfi_company_id": 1089,
              "platform_id": "123456",
              "rootfi_deleted_at": "2023-11-07T05:31:56Z",
              "platform_unique_id": "<string>",
              "raw_data": {},
              "data_hash": "<string>",
              "name": "<string>",
              "code": "<string>",
              "symbol": "<string>",
              "is_base_currency": true,
              "exchange_rate": 123,
              "updated_at": "<string>"
            }
          },
          "description": "<string>",
          "quantity": 123,
          "unit_amount": 123,
          "total_amount": 123,
          "sub_total": 123,
          "tax_amount": 123,
          "total_discount": 123,
          "updated_at": "2023-11-07T05:31:56Z"
        }
      ],
      "contact": {
        "rootfi_id": 157,
        "rootfi_created_at": "2024-01-22T05:07:31.465Z",
        "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
        "rootfi_company_id": 1089,
        "platform_id": "123456",
        "rootfi_deleted_at": "2023-11-07T05:31:56Z",
        "platform_unique_id": "<string>",
        "raw_data": {},
        "data_hash": "<string>",
        "name": "<string>",
        "contact_name": "<string>",
        "contact_type": "CUSTOMER",
        "currency_id": "<string>",
        "tax_number": "<string>",
        "registration_number": "<string>",
        "status": "ACTIVE",
        "updated_at": "<string>",
        "external_links": [
          {
            "rootfi_id": 123,
            "platform_id": "<string>",
            "link": "<string>",
            "type": "EMAIL"
          }
        ],
        "phone_numbers": [
          {
            "rootfi_id": 123,
            "platform_id": "<string>",
            "number": "<string>",
            "type": "MOBILE"
          }
        ],
        "addresses": [
          {
            "rootfi_id": 123,
            "platform_id": "<string>",
            "street": "<string>",
            "locality": "<string>",
            "city": "<string>",
            "state": "<string>",
            "pincode": "<string>",
            "country": "<string>"
          }
        ]
      },
      "currency": {
        "rootfi_id": 157,
        "rootfi_created_at": "2024-01-22T05:07:31.465Z",
        "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
        "rootfi_company_id": 1089,
        "platform_id": "123456",
        "rootfi_deleted_at": "2023-11-07T05:31:56Z",
        "platform_unique_id": "<string>",
        "raw_data": {},
        "data_hash": "<string>",
        "name": "<string>",
        "code": "<string>",
        "symbol": "<string>",
        "is_base_currency": true,
        "exchange_rate": 123,
        "updated_at": "<string>"
      },
      "account": {
        "rootfi_id": 157,
        "rootfi_created_at": "2024-01-22T05:07:31.465Z",
        "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
        "rootfi_company_id": 1089,
        "platform_id": "123456",
        "rootfi_deleted_at": "2023-11-07T05:31:56Z",
        "platform_unique_id": "<string>",
        "raw_data": {},
        "data_hash": "<string>",
        "name": "<string>",
        "description": "<string>",
        "nominal_code": "<string>",
        "current_balance": 123,
        "updated_at": "<string>",
        "status": "<string>",
        "category": "ASSET",
        "sub_category": "<string>",
        "currency_id": "<string>",
        "parent_account_id": "<string>",
        "parent_account": {
          "rootfi_id": 157,
          "rootfi_created_at": "2024-01-22T05:07:31.465Z",
          "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
          "rootfi_company_id": 1089,
          "platform_id": "123456",
          "rootfi_deleted_at": "2023-11-07T05:31:56Z",
          "platform_unique_id": "<string>",
          "raw_data": {},
          "data_hash": "<string>",
          "name": "<string>",
          "description": "<string>",
          "nominal_code": "<string>",
          "current_balance": 123,
          "updated_at": "<string>",
          "status": "<string>",
          "category": "ASSET",
          "sub_category": "<string>",
          "currency_id": "<string>",
          "parent_account_id": "<string>"
        },
        "currency": {
          "rootfi_id": 157,
          "rootfi_created_at": "2024-01-22T05:07:31.465Z",
          "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
          "rootfi_company_id": 1089,
          "platform_id": "123456",
          "rootfi_deleted_at": "2023-11-07T05:31:56Z",
          "platform_unique_id": "<string>",
          "raw_data": {},
          "data_hash": "<string>",
          "name": "<string>",
          "code": "<string>",
          "symbol": "<string>",
          "is_base_currency": true,
          "exchange_rate": 123,
          "updated_at": "<string>"
        }
      },
      "documents": [
        {
          "rootfi_id": 157,
          "rootfi_created_at": "2024-01-22T05:07:31.465Z",
          "rootfi_updated_at": "2024-01-22T05:07:31.000Z",
          "rootfi_company_id": 1089,
          "platform_id": "123456",
          "rootfi_deleted_at": "2023-11-07T05:31:56Z",
          "platform_unique_id": "<string>",
          "raw_data": {},
          "data_hash": "<string>",
          "file_name": "<string>",
          "file_type": "<string>",
          "file_size": "<string>",
          "document_type_id": "<string>",
          "document_type": "<string>",
          "document_uploaded": true,
          "updated_at": "<string>"
        }
      ]
    }
  ],
  "prev": "<string>",
  "next": "<string>",
  "total_count": 123
}
Expenses are Payment made by a business at the time of purchase (ex. a credit card payment)

Authorizations

api_key
string
header
required

Query Parameters

limit
integer | null

The number of objects you want to retrieve

next
string | null

The next page of objects to retrieve

prev
string | null

The previous page of objects to retrieve

expand
string | null

Comma separated fields to expand. Supported values are account, line_items, contact, currency, documents

select
string | null

Comma separated fields to select. Supported values are raw_data, data_hash

rootfi_updated_at[gte]
string | null

Filter by rootfi_updated_at Greater than or Equal To.

rootfi_company_id[eq]
integer | null

Filter by rootfi_company_id. You can filter by any field using this syntax field_name[operator]

include_deleted_records
string | null

Include deleted records. By default, deleted records are not included. Supported values are true and false

return_count
string | null

Return the count of the objects. Supported values are true and false

sort[rootfi_created_at]
enum<string> | null

Sort by rootfi_created_at

Available options:
ASC,
DESC
sort[rootfi_updated_at]
enum<string> | null

Sort by rootfi_updated_at

Available options:
ASC,
DESC

Response

The data of the Expenses endpoint

data
accountingExpenseObject · object[]
required
prev
string | null

The previous page of objects to retrieve

next
string | null

The next page of objects to retrieve

total_count
integer | null

The total count of the objects