Returns the data collections needed for the first web app load: accounts, allowance countries, company, currencies, user, vats, vehicles, vendors.
Expenses grouped by state are available via /expenses
Expenses in accounted state are available via /archive
An example output for the test company:
GET /api/home
200
{
"company": {
"id": 19,
"name": "Japanese Zaibatsu",
"business_id": null,
"created_at": "2020-04-24T14:39:06.430Z",
"updated_at": "2022-12-20T22:43:04.013Z",
"schedule": "weekly",
"lock_until": "2023-01-14",
"accountant_email": null,
"send_receipts_weekdays": [],
"iban": null,
"country_id": 10,
"software_id": 5,
"locale": "fi",
"mileage_vehicle_category_id": 1,
"allowance_country_category_id": 1,
"deleted_at": null,
"bic": null,
"einvoice_address": null,
"allowance_account_id": 789,
"mileage_account_id": 567,
"data": {
"policy_en": "",
"policy_fi": "",
"policy_sv": ""
},
"default_approver_id": null,
"is_vat_registered": true,
"is_managing": false,
"uuid": "4ae1a784-d2d1-4699-a1dc-91edd8eff132",
"show_trip_form": true,
"show_daily_allowance_form": true,
"reimbursement_account_id": null,
"employees_see_all_users": false,
"required_ssn_for_users": false,
"ssn_visible_on_forms_and_export": false,
"show_reward_form": true,
"tax_account_code": null,
"reward_account_code": null,
"password_auth_disabled": false,
"allowance_abroad_account_id": 789,
"activate_default_receipts_filter": false,
"is_nonprofit": false,
"reseller_id": null,
"integration_id": 23,
"send_data_to_incomes_register": true,
"count_additional_passengers": true,
"show_change_approval_cycle": true,
"external_id": null,
"encrypted_okta_client_id": null,
"encrypted_okta_client_secret": null,
"missing_receipts_weekly_reminder": false,
"okta_url": null,
"domain": null,
"group_id": null,
"user_request_recipients": null,
"contact_person_for_invoicing": null,
"employees_are_athletes": false,
"custom_reward_alias": null,
"support_person": null,
"missing_receipts_daily_reminder": false,
"show_budgets": true,
"allow_foreign_currency_vat": false,
"encrypted_okta_mobile_client_id": null,
"notify_users_about_payments": false,
"mark_all_free_meals_by_default": false,
"notes": null
},
"cost_centers": [],
"accounts": [
{
"id": 207,
"code": "2000",
"name": "Japanese Expense",
"url": "/api/accounts/207",
"assignee_ids": [],
"position": 2,
"default_vat_id": null,
"accountable_type": "ExpenseAccount",
"deactivated": false,
"limit": "",
"limit_type": "yearly",
"show_participants_field": false,
"show_on_receipt_form": true,
"max_vat_deduction": "",
"conditional_fields_description": null,
"conditional_fields": [],
"vat_mappings": []
},
{
"id": 333,
"code": "1111",
"name": "Daimyo reward",
"url": "/api/accounts/333",
"assignee_ids": [],
"position": 3,
"default_vat_id": null,
"accountable_type": "ExpenseAccount",
"deactivated": false,
"limit": "",
"limit_type": "yearly",
"show_participants_field": false,
"show_on_receipt_form": true,
"max_vat_deduction": "",
"conditional_fields_description": "",
"conditional_fields": [],
"vat_mappings": []
},
{
"id": 334,
"code": "3333",
"name": "Another reward",
"url": "/api/accounts/334",
"assignee_ids": [],
"position": 4,
"default_vat_id": null,
"accountable_type": "ExpenseAccount",
"deactivated": false,
"limit": "",
"limit_type": "yearly",
"show_participants_field": false,
"show_on_receipt_form": true,
"max_vat_deduction": "",
"conditional_fields_description": "",
"conditional_fields": [],
"vat_mappings": []
},
{
"id": 335,
"code": "555",
"name": "Koku",
"url": "/api/accounts/335",
"assignee_ids": [],
"position": 5,
"default_vat_id": null,
"accountable_type": "ExpenseAccount",
"deactivated": false,
"limit": "",
"limit_type": "yearly",
"show_participants_field": false,
"show_on_receipt_form": true,
"max_vat_deduction": "",
"conditional_fields_description": "",
"conditional_fields": [],
"vat_mappings": []
},
{
"id": 206,
"code": "1000",
"name": "Japanese Asset",
"url": "/api/accounts/206",
"assignee_ids": [],
"position": 1,
"default_vat_id": null,
"accountable_type": "AssetAccount",
"deactivated": false,
"limit": "",
"limit_type": "yearly",
"show_participants_field": false,
"max_vat_deduction": "",
"conditional_fields_description": null,
"credit_cards": []
}
],
"allowance_countries": [
{
"id": 8,
"name": "Japan",
"country": {
"id": 10,
"name": "Japan",
"currency": "JPY",
"created_at": "2020-04-24T14:41:04.217Z",
"updated_at": "2020-04-24T14:41:04.217Z",
"code": null,
"default_tax_percentage": "0.0"
},
"currency_symbol": "¥",
"has_breakfast": false,
"has_free_meal_days": true,
"free_meal_day_threshold": 2,
"free_meal_day_per_date": false,
"multi_country": true
},
{
"id": 9,
"name": "Vietnam",
"country": {
"id": 10,
"name": "Japan",
"currency": "JPY",
"created_at": "2020-04-24T14:41:04.217Z",
"updated_at": "2020-04-24T14:41:04.217Z",
"code": null,
"default_tax_percentage": "0.0"
},
"currency_symbol": "¥",
"has_breakfast": false,
"has_free_meal_days": true,
"free_meal_day_threshold": 2,
"free_meal_day_per_date": false,
"multi_country": true
}
],
"vats": [
{
"id": 0,
"title": "Abroad, VAT (0%)",
"value": "0.0"
}
],
"vehicles": [
{
"id": 1,
"name": "Auto",
"country": {
"id": 1,
"name": "Finland",
"currency": "EUR",
"created_at": "2017-09-06T11:51:21.283Z",
"updated_at": "2021-01-15T18:09:35.537Z",
"code": "FI",
"default_tax_percentage": "0.6"
}
},
{
"id": 2,
"name": "Bicicletta",
"country": {
"id": 1,
"name": "Finland",
"currency": "EUR",
"created_at": "2017-09-06T11:51:21.283Z",
"updated_at": "2021-01-15T18:09:35.537Z",
"code": "FI",
"default_tax_percentage": "0.6"
}
},
{
"id": 6,
"name": "Finnish Auto",
"country": {
"id": 1,
"name": "Finland",
"currency": "EUR",
"created_at": "2017-09-06T11:51:21.283Z",
"updated_at": "2021-01-15T18:09:35.537Z",
"code": "FI",
"default_tax_percentage": "0.6"
}
},
{
"id": 9,
"name": "Autolla (0.43 EUR/km)",
"country": {
"id": 1,
"name": "Finland",
"currency": "EUR",
"created_at": "2017-09-06T11:51:21.283Z",
"updated_at": "2021-01-15T18:09:35.537Z",
"code": "FI",
"default_tax_percentage": "0.6"
}
}
],
"currencies": [
{
"symbol": "€",
"code": "EUR",
"symbol_with_code": "€ (EUR)",
"code_with_name": "EUR, €"
},
{
"symbol": "$",
"code": "USD",
"symbol_with_code": "$ (USD)",
"code_with_name": "USD, US Dollar"
},
{
"symbol": "¥",
"code": "JPY",
"symbol_with_code": "¥ (JPY)",
"code_with_name": "JPY, Japanese Yen"
},
{
"symbol": "£",
"code": "GBP",
"symbol_with_code": "£ (GBP)",
"code_with_name": "GBP, Pound Sterling"
},
{
"symbol": "kr",
"code": "SEK",
"symbol_with_code": "kr (SEK)",
"code_with_name": "SEK, Swedish Krona"
},
{
"symbol": "kr",
"code": "NOK",
"symbol_with_code": "kr (NOK)",
"code_with_name": "NOK, Norwegian Krone"
},
{
"symbol": "kr.",
"code": "DKK",
"symbol_with_code": "kr. (DKK)",
"code_with_name": "DKK, Danish Crown"
},
{
"symbol": "CHF",
"code": "CHF",
"symbol_with_code": "CHF (CHF)",
"code_with_name": "CHF, Swiss Franc"
},
{
"symbol": "Lt",
"code": "LTL",
"symbol_with_code": "Lt (LTL)",
"code_with_name": "LTL, Lithuanian Litas"
},
{
"symbol": "$",
"code": "CAD",
"symbol_with_code": "$ (CAD)",
"code_with_name": "CAD, Canadian Dollar"
},
{
"symbol": "$",
"code": "HKD",
"symbol_with_code": "$ (HKD)",
"code_with_name": "HKD, Hongkong Dollar"
},
{
"symbol": "$",
"code": "AUD",
"symbol_with_code": "$ (AUD)",
"code_with_name": "AUD, Australian Dollar"
},
{
"symbol": "$",
"code": "NZD",
"symbol_with_code": "$ (NZD)",
"code_with_name": "NZD, New Zealand Dollar"
},
{
"symbol": "R",
"code": "ZAR",
"symbol_with_code": "R (ZAR)",
"code_with_name": "ZAR, South African Rand"
},
{
"symbol": "ر.س",
"code": "SAR",
"symbol_with_code": "ر.س (SAR)",
"code_with_name": "SAR, Saudi Arabian Riyal"
},
{
"symbol": "د.م.",
"code": "MAD",
"symbol_with_code": "د.م. (MAD)",
"code_with_name": "MAD, Morocco Dirham"
},
{
"symbol": "د.ك",
"code": "KWD",
"symbol_with_code": "د.ك (KWD)",
"code_with_name": "KWD, Kuwaiti Dinar"
},
{
"symbol": "د.إ",
"code": "AED",
"symbol_with_code": "د.إ (AED)",
"code_with_name": "AED, United Arab Emirates Dirham"
},
{
"symbol": "$",
"code": "SGD",
"symbol_with_code": "$ (SGD)",
"code_with_name": "SGD, Singapore Dollar"
},
{
"symbol": "RM",
"code": "MYR",
"symbol_with_code": "RM (MYR)",
"code_with_name": "MYR, Malaysian Ringgit"
},
{
"symbol": "₹",
"code": "INR",
"symbol_with_code": "₹ (INR)",
"code_with_name": "INR, Indian Rupee"
},
{
"symbol": "₽",
"code": "RUB",
"symbol_with_code": "₽ (RUB)",
"code_with_name": "RUB, Russian Rouble"
},
{
"symbol": "Kč",
"code": "CZK",
"symbol_with_code": "Kč (CZK)",
"code_with_name": "CZK, Czech Koruna"
},
{
"symbol": "zł",
"code": "PLN",
"symbol_with_code": "zł (PLN)",
"code_with_name": "PLN, Polish Zloty"
},
{
"symbol": "Ft",
"code": "HUF",
"symbol_with_code": "Ft (HUF)",
"code_with_name": "HUF, Hungarian Forint"
},
{
"symbol": "฿",
"code": "THB",
"symbol_with_code": "฿ (THB)",
"code_with_name": "THB, Thailand Baht"
},
{
"symbol": "₩",
"code": "KRW",
"symbol_with_code": "₩ (KRW)",
"code_with_name": "KRW, Korean won republic"
},
{
"symbol": "د.ت",
"code": "TND",
"symbol_with_code": "د.ت (TND)",
"code_with_name": "TND, Tunisian Dinar"
},
{
"symbol": "лв.",
"code": "BGN",
"symbol_with_code": "лв. (BGN)",
"code_with_name": "BGN, Bulgarian Lev"
},
{
"symbol": "R$",
"code": "BRL",
"symbol_with_code": "R$ (BRL)",
"code_with_name": "BRL, Brazilian Real"
},
{
"symbol": "¥",
"code": "CNY",
"symbol_with_code": "¥ (CNY)",
"code_with_name": "CNY, Chinese Renminbi"
},
{
"symbol": "kn",
"code": "HRK",
"symbol_with_code": "kn (HRK)",
"code_with_name": "HRK, Croatian Kuna"
},
{
"symbol": "₪",
"code": "ILS",
"symbol_with_code": "₪ (ILS)",
"code_with_name": "ILS, Israeli Sheqel"
},
{
"symbol": "$",
"code": "MXN",
"symbol_with_code": "$ (MXN)",
"code_with_name": "MXN, Mexican Peso"
},
{
"symbol": "Lei",
"code": "RON",
"symbol_with_code": "Lei (RON)",
"code_with_name": "RON, Romanian Leu"
},
{
"symbol": "РСД",
"code": "RSD",
"symbol_with_code": "РСД (RSD)",
"code_with_name": "RSD, Serbia Dinar"
},
{
"symbol": "₺",
"code": "TRY",
"symbol_with_code": "₺ (TRY)",
"code_with_name": "TRY, Turkish Lira"
},
{
"symbol": "₸",
"code": "KZT",
"symbol_with_code": "₸ (KZT)",
"code_with_name": "KZT, Kazakstan Tenge"
}
],
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"ssn": "0000000-0",
"last_sign_in_at": "2023-11-08T13:30:21.395Z",
"sign_in_count": 513,
"roles": [
"beta_tester",
"manager",
"employee"
],
"forward_email_address": "0f0ded3d-54f7-4965-a64c-569a93396a90@0.0.0.0",
"send_reminder_emails": true,
"iban": null,
"bic": null,
"locale": "en",
"state": "accepted",
"memberships": 27,
"country_id": 12,
"unconfirmed_email": null,
"external_id": null,
"email_is_confirmed": true,
"on_vacation": false,
"settings": {
"id": 298,
"user_id": 1,
"company_id": 19,
"default_asset_account_id": 0,
"default_expense_account_id": 0,
"default_cost_centers": null,
"mileage_vehicle_category_id": null,
"allowance_country_category_id": 5,
"allowance_account_id": null,
"allowance_abroad_account_id": null,
"mileage_account_id": null,
"reimbursement_account_code": null,
"netsuite": null,
"ir_mileage_code": 0,
"ir_daily_allowance_code": 0,
"stand_in_approver_id": null,
"receipthero_connected": false,
"send_data_to_incomes_register": true,
"last_mileage_vehicle_id": null,
"password_auth_disabled": null
},
"companies_to_switch": [
{
"id": 21,
"name": "\"Create new company\" test",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 2,
"name": "AltCorp",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 27,
"name": "Bezala Gmbh",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 1,
"name": "BuruCorp",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 3,
"name": "Cost Centers Co",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 22,
"name": "Digia ERP",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 38,
"name": "Experimental Corp",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 14,
"name": "Foreign Country Corp",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 40,
"name": "IKEA",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 48,
"name": "Magellan Oy",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 52,
"name": "Mass Mileages Company",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 6,
"name": "NeoCorp1",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 8,
"name": "NeoCorp3",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 46,
"name": "Norway AG",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 9,
"name": "Procountor Corp",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 20,
"name": "Reward Corp",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 49,
"name": "Schema Change Co LTD",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 47,
"name": "Spain & Co",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 17,
"name": "Spreadsheet Corp",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
{
"id": 11,
"name": "Swedish Corp",
"send_data_to_incomes_register": false,
"show_reward_form": true
},
{
"id": 16,
"name": "Swiss Company",
"send_data_to_incomes_register": false,
"show_reward_form": true
},
{
"id": 12,
"name": "US Division",
"send_data_to_incomes_register": false,
"show_reward_form": true
},
{
"id": 39,
"name": "Vana Tallinn",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 50,
"name": "Viking Warband",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 25,
"name": "gggfff",
"send_data_to_incomes_register": true,
"show_reward_form": false
},
{
"id": 10,
"name": "Рога и Копыта лтд.",
"send_data_to_incomes_register": true,
"show_reward_form": true
}
],
"company": {
"id": 19,
"name": "Japanese Zaibatsu",
"send_data_to_incomes_register": true,
"show_reward_form": true
},
"current_tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164414Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9a2a50ec1b55d4ec5bf036f57b9494266534f510de587f55288a96371dd2fee0"
},
"tax_percentage": "0.6",
"is_current": true
},
"approvers": [],
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
},
"address": {
"street": "233",
"city": "New York",
"postal_code": "19212",
"country_id": 4,
"latitude": "40.709476",
"longitude": "-74.007296"
}
}
}
Returns receipts, trips, daily allowances and rewards grouped by state (except for accounted expenses), as well as many other collections needed for the first web app load.
Expenses in accounted state are available via /archive
GET /api/expenses
200
{
"batch_dates": [
"2020-07-20T00:00:00.000Z",
"2020-07-16T00:00:00.000Z",
"2020-06-15T00:00:00.000Z",
"2020-05-04T00:00:00.000Z"
],
"transactions_on_review": [],
"transactions_in_draft": [],
"transactions_in_reviewing": [],
"transactions_in_unapproved": [],
"transactions_in_queue": [],
"trips_on_review": [],
"trips_in_draft": [],
"trips_in_reviewing": [],
"trips_in_unapproved": [],
"trips_in_queue": [],
"daily_allowances_on_review": [],
"daily_allowances_in_draft": [],
"daily_allowances_in_reviewing": [],
"daily_allowances_in_unapproved": [],
"daily_allowances_in_queue": [
{
"id": 149,
"description": "Daily allowance with time zone",
"_id": "daily_allowance-149",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "daily_allowance",
"updated_at": "2022-12-23T15:24:48.581Z",
"cost_center_ids": [],
"date": "2022-12-02",
"approvers": [],
"approved_by": [],
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-23T15:22:02.906Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"number_of_days": 0,
"cost_center_id": 0,
"taxable": 2500.0,
"subtotal": 50.0,
"free_meals_cost": 25.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"free_meal_days": [
{
"id": 1182,
"daily_allowance_id": 149,
"had_breakfast": false,
"had_lunch": true,
"had_dinner": true,
"is_full": true,
"created_at": "2022-12-23T15:22:02.962Z",
"updated_at": "2022-12-23T15:22:02.962Z",
"date": "2022-12-01"
}
],
"documents": [],
"entries": [
{
"id": 516,
"daily_allowance_id": 149,
"country_id": 8,
"start_time": "2022-12-01 13:15 Z",
"end_time": "2022-12-02 12:30 Z",
"country": {
"id": 8,
"name": "Japan",
"country": {
"id": 10,
"name": "Japan",
"currency": "JPY",
"created_at": "2020-04-24T14:41:04.217Z",
"updated_at": "2020-04-24T14:41:04.217Z",
"code": null,
"default_tax_percentage": "0.0"
},
"currency_symbol": "¥",
"has_breakfast": false,
"has_free_meal_days": true,
"free_meal_day_threshold": 2,
"free_meal_day_per_date": false,
"multi_country": true
}
}
]
}
],
"rewards_on_review": [],
"rewards_in_draft": [],
"rewards_in_reviewing": [],
"rewards_in_unapproved": [],
"rewards_in_queue": [
{
"id": 70,
"description": "Japanese reward. 1 Koku",
"_id": "reward-70",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-20T22:44:32.866Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-20T22:44:32.866Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 32,
"income_tax_percentage": "0.0",
"taxable": 10000.0,
"cost": 10000.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 32,
"name": "Daimyo reward",
"company_id": 19,
"expense_account_id": 333,
"account_code": "1111",
"cost": 10000.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "336",
"transaction_code_description": "Work reward",
"deduct_income_tax": false,
"fixed_price": true
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 71,
"description": "another koku",
"_id": "reward-71",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-20T23:51:24.330Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-20T23:51:24.330Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 32,
"income_tax_percentage": "0.0",
"taxable": 10000.0,
"cost": 10000.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 32,
"name": "Daimyo reward",
"company_id": 19,
"expense_account_id": 333,
"account_code": "1111",
"cost": 10000.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "336",
"transaction_code_description": "Work reward",
"deduct_income_tax": false,
"fixed_price": true
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 72,
"description": "Ggg reward",
"_id": "reward-72",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-21T12:42:25.299Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-21T12:42:25.299Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 33,
"income_tax_percentage": "0.6",
"taxable": 333.0,
"cost": 333.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 33,
"name": "Another reward",
"company_id": 19,
"expense_account_id": 334,
"account_code": "3333",
"cost": 333.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "208",
"transaction_code_description": "Notice period compensation",
"deduct_income_tax": true,
"fixed_price": false
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 73,
"description": "Another reward",
"_id": "reward-73",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-21T12:46:52.898Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-21T12:46:52.898Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 33,
"income_tax_percentage": "0.6",
"taxable": 333.0,
"cost": 333.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 33,
"name": "Another reward",
"company_id": 19,
"expense_account_id": 334,
"account_code": "3333",
"cost": 333.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "208",
"transaction_code_description": "Notice period compensation",
"deduct_income_tax": true,
"fixed_price": false
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 74,
"description": "lglflgflg",
"_id": "reward-74",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-21T12:49:22.767Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-21T12:49:22.767Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 33,
"income_tax_percentage": "0.6",
"taxable": 333.0,
"cost": 333.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 33,
"name": "Another reward",
"company_id": 19,
"expense_account_id": 334,
"account_code": "3333",
"cost": 333.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "208",
"transaction_code_description": "Notice period compensation",
"deduct_income_tax": true,
"fixed_price": false
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 75,
"description": "finally fixed??",
"_id": "reward-75",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-21T13:00:08.933Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-21T13:00:08.933Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 33,
"income_tax_percentage": "0.6",
"taxable": 333.0,
"cost": 333.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 33,
"name": "Another reward",
"company_id": 19,
"expense_account_id": 334,
"account_code": "3333",
"cost": 333.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "208",
"transaction_code_description": "Notice period compensation",
"deduct_income_tax": true,
"fixed_price": false
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 76,
"description": "won't work again",
"_id": "reward-76",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-21T13:00:47.147Z",
"cost_center_ids": [],
"date": "2022-12-21",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-21T13:00:47.147Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 33,
"income_tax_percentage": "0.6",
"taxable": 333.0,
"cost": 333.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 33,
"name": "Another reward",
"company_id": 19,
"expense_account_id": 334,
"account_code": "3333",
"cost": 333.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "208",
"transaction_code_description": "Notice period compensation",
"deduct_income_tax": true,
"fixed_price": false
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
},
{
"id": 77,
"description": "Koku reward",
"_id": "reward-77",
"user_name": "Hack Häckermann",
"state": "queue",
"user_id": 1,
"type": "reward",
"updated_at": "2022-12-23T21:07:33.287Z",
"cost_center_ids": [],
"date": "2022-12-23",
"approvers": [],
"approved_by": null,
"approved_by_ids": [],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-12-23T21:07:33.287Z",
"company_id": 19,
"paid_at": null,
"batch_sending_failed": false,
"cost_centers": [],
"reverse_of": null,
"reward_type_id": 35,
"income_tax_percentage": "0.6",
"taxable": 555.0,
"cost": 555.0,
"user": {
"id": 1,
"name": "Hack Häckermann",
"email": "buru@hack.com",
"country": {
"id": 12,
"name": "Estonia",
"currency": "EUR",
"currency_symbol": "€",
"default_tax_percentage": 0.0
}
},
"comments": [],
"reward_type": {
"id": 35,
"name": "Koku",
"company_id": 19,
"expense_account_id": 335,
"account_code": "555",
"cost": 555.0,
"deactivated": false,
"assignee_ids": [],
"transaction_code": "336",
"transaction_code_description": "Work reward",
"deduct_income_tax": true,
"fixed_price": true
},
"tax_card": {
"id": 48,
"user_id": 1,
"image": {
"url": "http://thinkpad.local:9000/rcam-test/tax_card/1/f09e967d-4496-4511-975e-96cf50c566ea.png/f09e967d-4496-4511-975e-96cf50c566ea.png?X-Amz-Expires=259200&X-Amz-Date=20231109T164349Z&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=BURULAPTOP%2F20231109%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-SignedHeaders=host&X-Amz-Signature=9d2dc8f8ce4aa9b81677b951281c803a6285efea73fcf78dd4a2a100a419882b"
},
"tax_percentage": "0.6",
"is_current": true
},
"documents": []
}
]
}
Returns extended data of receipts, trips, daily allowances and rewards in accounted state.
By default returns the expenses from the latest batch date. Each page contains collections of expenses from one batch date, starting from the most recent batch date, with each next page having batch dates in descending order.
The list of batch dates is returned on /api/home.
Expenses are returned either from one batch date (via page parameter) or from one batch document, if batch_reference_number is present.
GET /api/home
200
{
"has_more_items": true,
"transactions_in_accounted": [],
"daily_allowances_in_accounted": [
{
"id": 93,
"description": "test perdiem 1",
"_id": "daily_allowance-93",
"user_name": "KATE Key",
"state": "accounted",
"user_id": 58,
"type": "daily_allowance",
"updated_at": "2023-02-16T13:00:40.746Z",
"cost_center_ids": [
66
],
"date": "2021-12-05",
"approvers": [],
"approved_by": [
"Le Admin"
],
"approved_by_ids": [
"1"
],
"current_approvers_ids": [],
"transaction_approvers": [],
"created_at": "2022-03-31T11:00:59.254Z",
"company_id": 2,
"paid_at": "2023-03-16T21:09:41.200Z",
"batch_sending_failed": null,
"cost_centers": [
{
"id": 66,
"name": "test cost center",
"dimension_name": "123.0",
"assignee_ids": [
1
],
"deactivated": false,
"external_id": "7037",
"required_dimension": false,
"approvers": []
}
],
"reverse_of": null,
"reverse_id": null,
"number_of_days": 0,
"cost_center_id": 0,
"taxable": 62.1,
"subtotal": 62.1,
"free_meals_cost": 0,
"user": {
"id": 58,
"name": "KATE Key",
"email": "k@k.com",
"country": {
"id": 1,
"name": "Finland",
"currency": "EUR",
"currency_symbol": "€"
}
},
"comments": [
{
"comment": "this is comment!",
"user_name": "Le Admin",
"created_at": "23/08/23 12:13",
"disapprove_comment": false,
"reversal_comment": false,
"duplicate_comment": false
}
],
"free_meal_days": [
{
"id": 962,
"daily_allowance_id": 93,
"had_breakfast": false,
"had_lunch": false,
"had_dinner": false,
"is_full": true,
"created_at": "2022-03-31T11:00:59.267Z",
"updated_at": "2022-03-31T11:00:59.267Z",
"date": "2021-11-29"
},
{
"id": 963,
"daily_allowance_id": 93,
"had_breakfast": false,
"had_lunch": false,
"had_dinner": false,
"is_full": true,
"created_at": "2022-03-31T11:00:59.268Z",
"updated_at": "2022-03-31T11:00:59.268Z",
"date": "2021-11-30"
}
],
"documents": [],
"entries": [
{
"id": 186,
"daily_allowance_id": 93,
"country_id": 1,
"start_time": "2021-11-29 10:30 Z",
"end_time": "2021-11-30 10:30 Z",
"country": {
"id": 1,
"name": "Finland",
"country": {
"id": 1,
"name": "Finland",
"currency": "EUR",
"created_at": "2019-01-03T11:08:01.182Z",
"updated_at": "2019-01-03T11:08:01.182Z",
"code": null
},
"currency_symbol": "€",
"has_breakfast": false,
"has_free_meal_days": true,
"free_meal_day_threshold": 2,
"free_meal_day_per_date": false,
"multi_country": true
}
}
]
}
],
"trips_in_accounted": [],
"rewards_in_accounted": []
}
| Param name | Description |
|---|---|
|
page
optional |
Page number. Starts from 0. Ignored if Validations:
|
|
batch_reference_number
optional |
Batch Reference Number, to return the expenses from the corresponding batch document. E.g. Validations:
|