API Documentation
Expenses ¶
Expenses ¶
Supported filter params
-
deal_id (array)
-
service_type_id (array)
-
company_id (array)
-
project_id (array)
-
date_after
-
date_before
-
pay_on_after
-
pay_on_before
-
paid_on_after
-
paid_on_before
-
status (1: paid, 2: unpaid)
Supported sort params
-
name
-
date
-
pay_on
-
paid_on
-
amount
-
billable_amount
-
profit
-
service_type.name
Supported aggregates params
-
total_amount
-
total_billable_amount
-
total_profit
Filter operations are supported on this endpoint.
GET /api/v2/expenses
Requests
GETÂ Â /api/v2/expenses
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": [
{
"id": "7",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 1,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:38.804+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"deal": {
"data": {
"type": "deals",
"id": "71"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "18"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "649"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
{
"id": "8",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 2,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:38.920+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"deal": {
"data": {
"type": "deals",
"id": "71"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "20"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "649"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
{
"id": "9",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 3,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:39.033+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"deal": {
"data": {
"type": "deals",
"id": "71"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "22"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "649"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
}
],
"included": [
{
"id": "71",
"type": "deals",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"end_date": null,
"number": 1,
"suffix": null,
"time_approval": true,
"expense_approval": true,
"client_access": false,
"deal_type_id": 2,
"budget": true,
"sales_status_id": null,
"sales_status_updated_at": null,
"tag_list": [],
"origin_deal_id": null,
"profit_margin": 0,
"discount": null,
"email_key": "2a2e4f3cfb825b84579e4eafcfb438ce",
"purchase_order_number": null,
"custom_fields": null,
"forecasted_billable_time": 0,
"forecasted_margin": 0,
"forecasted_budget_usage": 0,
"forecasted_time_usage": 0,
"budget_usage": 0,
"position": 1,
"budget_revamp": false,
"future_booked_time": 0,
"probability": 50,
"budget_warning": null,
"billable_time": 0,
"estimated_time": 0,
"budgeted_time": 0,
"worked_time": 0,
"time_to_close": null,
"unapproved_entries_count": 0,
"rejected_entries_count": 0,
"estimated_remaining_time": 0,
"unapproved_time": 0,
"lost_comment": null,
"closed_at": null,
"delivered_on": null,
"last_activity_at": null,
"deleted_at": null,
"created_at": "2021-04-15T01:03:38.712+02:00",
"note": null,
"sales_closed_at": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"sales_closed_on": null,
"note_interpolated": null,
"todo_count": 0,
"todo_due_date": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"services_revenue": 0,
"services_revenue_default": 0,
"services_revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"work_cost": 0,
"work_cost_default": 0,
"work_cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"invoiced": 0,
"invoiced_default": 0,
"invoiced_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"expense": 0,
"expense_default": 0,
"expense_normalized": 0,
"expense_billable": 0,
"expense_billable_default": 0,
"expense_billable_normalized": 0,
"budget_total": 0,
"budget_total_default": 0,
"budget_total_normalized": 0,
"budget_used": 0,
"budget_used_default": 0,
"budget_used_normalized": 0,
"actual_rate": 0,
"actual_rate_default": 0,
"actual_rate_normalized": 0,
"budget_remaining": 0,
"budget_remaining_default": 0,
"budget_remaining_normalized": 0,
"projected_revenue": 0,
"projected_revenue_default": 0,
"projected_revenue_normalized": 0,
"future_revenue": 0,
"future_revenue_default": 0,
"future_revenue_normalized": 0,
"future_budget_used": 0,
"future_budget_used_default": 0,
"future_budget_used_normalized": 0,
"future_cost": 0,
"future_cost_default": 0,
"future_cost_normalized": 0,
"forecasted_revenue": 0,
"forecasted_revenue_default": 0,
"forecasted_revenue_normalized": 0,
"forecasted_cost": 0,
"forecasted_cost_default": 0,
"forecasted_cost_normalized": 0,
"forecasted_profit": 0,
"forecasted_profit_default": 0,
"forecasted_profit_normalized": 0,
"forecasted_budget_used": 0,
"forecasted_budget_used_default": 0,
"forecasted_budget_used_normalized": 0,
"invoiced_rate": 0,
"invoiced_rate_default": 0,
"invoiced_rate_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"creator": {
"data": {
"type": "people",
"id": "649"
}
},
"company": {
"data": {
"type": "companies",
"id": "847"
}
},
"document_type": {
"data": null
},
"responsible": {
"data": {
"type": "people",
"id": "650"
}
},
"deal_status": {
"data": null
},
"project": {
"data": {
"type": "projects",
"id": "87"
}
},
"lost_reason": {
"data": null
},
"contract": {
"data": null
},
"contact": {
"data": null
},
"subsidiary": {
"data": null
}
}
},
{
"id": "18",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
}
}
},
{
"id": "649",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user650@email.com",
"title": null,
"joined_at": "2021-04-15T01:03:39.000+02:00",
"last_seen_at": "2021-04-15T01:03:39.071+02:00",
"deactivated_at": null,
"archived_at": null,
"role_id": 1,
"invited_at": null,
"is_user": true,
"user_id": 650,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:38.606+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"company": {
"data": {
"type": "companies",
"id": "846"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "20",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
}
}
},
{
"id": "22",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
}
}
},
{
"id": "847",
"type": "companies",
"attributes": {
"name": "Client562",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:38.626+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "650",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user651@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:38.000+02:00",
"is_user": true,
"user_id": 651,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:38.635+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"company": {
"data": {
"type": "companies",
"id": "848"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "87",
"type": "projects",
"attributes": {
"name": "test project",
"number": 1,
"project_type_id": 2,
"project_color_id": null,
"last_activity_at": null,
"public_access": true,
"time_on_tasks": false,
"tag_colors": {},
"archived_at": null,
"created_at": "2021-04-15T01:03:38.693+02:00",
"board_count": 0,
"budget_count": 1,
"worked_time": 0,
"estimated_time": 0,
"profit_margin": 0,
"budget_closing_date": null,
"invoice_payment_due": null,
"custom_fields": null,
"task_custom_fields_ids": null,
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "USD",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"needs_invoicing": 0,
"needs_invoicing_default": 0,
"needs_invoicing_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"company": {
"data": {
"type": "companies",
"id": "850"
}
},
"project_manager": {
"data": {
"type": "people",
"id": "651"
}
},
"last_actor": {
"data": null
}
}
},
{
"id": "846",
"type": "companies",
"attributes": {
"name": "Organization284",
"billing_name": null,
"vat": null,
"default_currency": "USD",
"created_at": "2021-04-15T01:03:38.604+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "848",
"type": "companies",
"attributes": {
"name": "Client563",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:38.632+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "850",
"type": "companies",
"attributes": {
"name": "Client565",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:38.691+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "651",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user652@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:38.000+02:00",
"is_user": true,
"user_id": 652,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:38.665+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"company": {
"data": {
"type": "companies",
"id": "849"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "849",
"type": "companies",
"attributes": {
"name": "Client564",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:38.662+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 284
}
},
"bill_to": {
"data": null
}
}
}
],
"links": {
"first": "http://www.example.com/api/v2/expenses?page%5Bnumber%5D=1&page%5Bsize%5D=30",
"last": "http://www.example.com/api/v2/expenses?page%5Bnumber%5D=1&page%5Bsize%5D=30"
},
"meta": {
"current_page": 1,
"total_pages": 1,
"total_count": 3,
"page_size": 30,
"max_page_size": 200,
"organization_features": {
"custom_fields": {
"type": "metered",
"limit": 15,
"used": 0
},
"custom_fields_per_project": {
"type": "metered",
"limit": 10,
"used": 0
},
"public_custom_reports": {
"type": "metered",
"limit": 100,
"used": 0
},
"private_custom_reports": {
"type": "metered",
"limit": 30,
"used": 0
},
"scheduling_placeholders": {
"type": "metered",
"limit": 5,
"used": 0
},
"multigrouping": {
"type": "switch",
"available": true
},
"client_access_to_budgets": {
"type": "switch",
"available": true
},
"subsidiaries": {
"type": "switch",
"available": true
},
"time_approvals": {
"type": "switch",
"available": true
},
"expenses_approvals": {
"type": "switch",
"available": true
},
"timeoff_approvals": {
"type": "switch",
"available": true
},
"autotracking": {
"type": "switch",
"available": true
},
"forecasting": {
"type": "switch",
"available": true
},
"webhooks": {
"type": "switch",
"available": true
},
"table_pivoting": {
"type": "switch",
"available": true
},
"formula_fields": {
"type": "switch",
"available": true
},
"single_sign_on": {
"type": "switch",
"available": true
},
"duplicate_tasks": {
"type": "switch",
"available": true
},
"billable_time_rounding": {
"type": "switch",
"available": true
},
"payment_sync": {
"type": "switch",
"available": true
},
"booking_methods": {
"type": "switch",
"available": true
},
"import_tasks_csv": {
"type": "switch",
"available": true
},
"reactions": {
"type": "switch",
"available": true
},
"time_week_view": {
"type": "switch",
"available": true
},
"subtasks": {
"type": "switch",
"available": true
},
"time_calendar_layout": {
"type": "switch",
"available": true
},
"theming": {
"type": "switch",
"available": true
},
"remove_branding": {
"type": "switch",
"available": true
},
"custom_invoicing_email": {
"type": "switch",
"available": true
},
"google_calendar_layout": {
"type": "switch",
"available": true
},
"pulse": {
"type": "switch",
"available": true
}
},
"settings": {}
}
}
Get expensesGET/api/v2/expenses
GET /api/v2/expenses/1
Requests
GETÂ Â /api/v2/expenses/10
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "10",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 1,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:39.427+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"deal": {
"data": {
"type": "deals",
"id": "75"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "24"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "655"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
"included": [
{
"id": "75",
"type": "deals",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"end_date": null,
"number": 1,
"suffix": null,
"time_approval": true,
"expense_approval": true,
"client_access": false,
"deal_type_id": 2,
"budget": true,
"sales_status_id": null,
"sales_status_updated_at": null,
"tag_list": [],
"origin_deal_id": null,
"profit_margin": 0,
"discount": null,
"email_key": "bbc33297b9f8e091692c2b6e6212d4f1",
"purchase_order_number": null,
"custom_fields": null,
"forecasted_billable_time": 0,
"forecasted_margin": 0,
"forecasted_budget_usage": 0,
"forecasted_time_usage": 0,
"budget_usage": 0,
"position": 1,
"budget_revamp": false,
"future_booked_time": 0,
"probability": 50,
"budget_warning": null,
"billable_time": 0,
"estimated_time": 0,
"budgeted_time": 0,
"worked_time": 0,
"time_to_close": null,
"unapproved_entries_count": 0,
"rejected_entries_count": 0,
"estimated_remaining_time": 0,
"unapproved_time": 0,
"lost_comment": null,
"closed_at": null,
"delivered_on": null,
"last_activity_at": null,
"deleted_at": null,
"created_at": "2021-04-15T01:03:39.332+02:00",
"note": null,
"sales_closed_at": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"sales_closed_on": null,
"note_interpolated": null,
"todo_count": 0,
"todo_due_date": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"services_revenue": 0,
"services_revenue_default": 0,
"services_revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"work_cost": 0,
"work_cost_default": 0,
"work_cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"invoiced": 0,
"invoiced_default": 0,
"invoiced_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"expense": 0,
"expense_default": 0,
"expense_normalized": 0,
"expense_billable": 0,
"expense_billable_default": 0,
"expense_billable_normalized": 0,
"budget_total": 0,
"budget_total_default": 0,
"budget_total_normalized": 0,
"budget_used": 0,
"budget_used_default": 0,
"budget_used_normalized": 0,
"actual_rate": 0,
"actual_rate_default": 0,
"actual_rate_normalized": 0,
"budget_remaining": 0,
"budget_remaining_default": 0,
"budget_remaining_normalized": 0,
"projected_revenue": 0,
"projected_revenue_default": 0,
"projected_revenue_normalized": 0,
"future_revenue": 0,
"future_revenue_default": 0,
"future_revenue_normalized": 0,
"future_budget_used": 0,
"future_budget_used_default": 0,
"future_budget_used_normalized": 0,
"future_cost": 0,
"future_cost_default": 0,
"future_cost_normalized": 0,
"forecasted_revenue": 0,
"forecasted_revenue_default": 0,
"forecasted_revenue_normalized": 0,
"forecasted_cost": 0,
"forecasted_cost_default": 0,
"forecasted_cost_normalized": 0,
"forecasted_profit": 0,
"forecasted_profit_default": 0,
"forecasted_profit_normalized": 0,
"forecasted_budget_used": 0,
"forecasted_budget_used_default": 0,
"forecasted_budget_used_normalized": 0,
"invoiced_rate": 0,
"invoiced_rate_default": 0,
"invoiced_rate_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"creator": {
"data": {
"type": "people",
"id": "655"
}
},
"company": {
"data": {
"type": "companies",
"id": "858"
}
},
"document_type": {
"data": null
},
"responsible": {
"data": {
"type": "people",
"id": "656"
}
},
"deal_status": {
"data": null
},
"project": {
"data": {
"type": "projects",
"id": "88"
}
},
"lost_reason": {
"data": null
},
"contract": {
"data": null
},
"contact": {
"data": null
},
"subsidiary": {
"data": null
}
}
},
{
"id": "24",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
}
}
},
{
"id": "655",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user656@email.com",
"title": null,
"joined_at": "2021-04-15T01:03:39.000+02:00",
"last_seen_at": "2021-04-15T01:03:39.468+02:00",
"deactivated_at": null,
"archived_at": null,
"role_id": 1,
"invited_at": null,
"is_user": true,
"user_id": 656,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:39.223+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"company": {
"data": {
"type": "companies",
"id": "857"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "858",
"type": "companies",
"attributes": {
"name": "Client572",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.244+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "656",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user657@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:39.000+02:00",
"is_user": true,
"user_id": 657,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:39.254+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"company": {
"data": {
"type": "companies",
"id": "859"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "88",
"type": "projects",
"attributes": {
"name": "test project",
"number": 1,
"project_type_id": 2,
"project_color_id": null,
"last_activity_at": null,
"public_access": true,
"time_on_tasks": false,
"tag_colors": {},
"archived_at": null,
"created_at": "2021-04-15T01:03:39.313+02:00",
"board_count": 0,
"budget_count": 1,
"worked_time": 0,
"estimated_time": 0,
"profit_margin": 0,
"budget_closing_date": null,
"invoice_payment_due": null,
"custom_fields": null,
"task_custom_fields_ids": null,
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "USD",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"needs_invoicing": 0,
"needs_invoicing_default": 0,
"needs_invoicing_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"company": {
"data": {
"type": "companies",
"id": "861"
}
},
"project_manager": {
"data": {
"type": "people",
"id": "657"
}
},
"last_actor": {
"data": null
}
}
},
{
"id": "857",
"type": "companies",
"attributes": {
"name": "Organization285",
"billing_name": null,
"vat": null,
"default_currency": "USD",
"created_at": "2021-04-15T01:03:39.222+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "859",
"type": "companies",
"attributes": {
"name": "Client573",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.251+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "861",
"type": "companies",
"attributes": {
"name": "Client575",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.311+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "657",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user658@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:39.000+02:00",
"is_user": true,
"user_id": 658,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:39.286+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"company": {
"data": {
"type": "companies",
"id": "860"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "860",
"type": "companies",
"attributes": {
"name": "Client574",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.282+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 285
}
},
"bill_to": {
"data": null
}
}
}
],
"meta": {
"organization_features": {
"custom_fields": {
"type": "metered",
"limit": 15,
"used": 0
},
"custom_fields_per_project": {
"type": "metered",
"limit": 10,
"used": 0
},
"public_custom_reports": {
"type": "metered",
"limit": 100,
"used": 0
},
"private_custom_reports": {
"type": "metered",
"limit": 30,
"used": 0
},
"scheduling_placeholders": {
"type": "metered",
"limit": 5,
"used": 0
},
"multigrouping": {
"type": "switch",
"available": true
},
"client_access_to_budgets": {
"type": "switch",
"available": true
},
"subsidiaries": {
"type": "switch",
"available": true
},
"time_approvals": {
"type": "switch",
"available": true
},
"expenses_approvals": {
"type": "switch",
"available": true
},
"timeoff_approvals": {
"type": "switch",
"available": true
},
"autotracking": {
"type": "switch",
"available": true
},
"forecasting": {
"type": "switch",
"available": true
},
"webhooks": {
"type": "switch",
"available": true
},
"table_pivoting": {
"type": "switch",
"available": true
},
"formula_fields": {
"type": "switch",
"available": true
},
"single_sign_on": {
"type": "switch",
"available": true
},
"duplicate_tasks": {
"type": "switch",
"available": true
},
"billable_time_rounding": {
"type": "switch",
"available": true
},
"payment_sync": {
"type": "switch",
"available": true
},
"booking_methods": {
"type": "switch",
"available": true
},
"import_tasks_csv": {
"type": "switch",
"available": true
},
"reactions": {
"type": "switch",
"available": true
},
"time_week_view": {
"type": "switch",
"available": true
},
"subtasks": {
"type": "switch",
"available": true
},
"time_calendar_layout": {
"type": "switch",
"available": true
},
"theming": {
"type": "switch",
"available": true
},
"remove_branding": {
"type": "switch",
"available": true
},
"custom_invoicing_email": {
"type": "switch",
"available": true
},
"google_calendar_layout": {
"type": "switch",
"available": true
},
"pulse": {
"type": "switch",
"available": true
}
},
"settings": {}
}
}
POST /api/v2/expenses
Requests
POSTÂ Â /api/v2/expenses
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "expenses",
"attributes": {
"name": "test name",
"amount": 10000,
"billable_amount": 10000,
"currency": "USD",
"date": "2021-04-15",
"position": 1
},
"relationships": {
"deal": {
"data": {
"type": "deals",
"id": "77"
}
},
"service_type": {
"data": {
"type": "service-type",
"id": "26"
}
},
"person": {
"data": {
"type": "people",
"id": "659"
}
}
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "12",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 1,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.0",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:39.876+02:00",
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 10000,
"amount_normalized": 8000,
"billable_amount": 10000,
"billable_amount_default": 12500,
"billable_amount_normalized": 10000,
"profit": 2000,
"profit_default": 2500,
"profit_normalized": 2000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"deal": {
"data": {
"type": "deals",
"id": "77"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "26"
}
},
"person": {
"data": {
"type": "people",
"id": "659"
}
},
"creator": {
"data": {
"type": "people",
"id": "659"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
"included": [
{
"id": "77",
"type": "deals",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"end_date": null,
"number": 1,
"suffix": null,
"time_approval": true,
"expense_approval": true,
"client_access": false,
"deal_type_id": 2,
"budget": true,
"sales_status_id": null,
"sales_status_updated_at": null,
"tag_list": [],
"origin_deal_id": null,
"profit_margin": 0,
"discount": null,
"email_key": "364e77541ae65944551d61b94b9e46d1",
"purchase_order_number": null,
"custom_fields": null,
"forecasted_billable_time": 0,
"forecasted_margin": 0,
"forecasted_budget_usage": 0,
"forecasted_time_usage": 0,
"budget_usage": 0,
"position": 1,
"budget_revamp": false,
"future_booked_time": 0,
"probability": 50,
"budget_warning": null,
"billable_time": 0,
"estimated_time": 0,
"budgeted_time": 0,
"worked_time": 0,
"time_to_close": null,
"unapproved_entries_count": 0,
"rejected_entries_count": 0,
"estimated_remaining_time": 0,
"unapproved_time": 0,
"lost_comment": null,
"closed_at": null,
"delivered_on": null,
"last_activity_at": null,
"deleted_at": null,
"created_at": "2021-04-15T01:03:39.691+02:00",
"note": null,
"sales_closed_at": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"sales_closed_on": null,
"note_interpolated": null,
"todo_count": 0,
"todo_due_date": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"services_revenue": 0,
"services_revenue_default": 0,
"services_revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"work_cost": 0,
"work_cost_default": 0,
"work_cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"invoiced": 0,
"invoiced_default": 0,
"invoiced_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"expense": 0,
"expense_default": 0,
"expense_normalized": 0,
"expense_billable": 0,
"expense_billable_default": 0,
"expense_billable_normalized": 0,
"budget_total": 10000,
"budget_total_default": 12500,
"budget_total_normalized": 10000,
"budget_used": 0,
"budget_used_default": 0,
"budget_used_normalized": 0,
"actual_rate": 0,
"actual_rate_default": 0,
"actual_rate_normalized": 0,
"budget_remaining": 10000,
"budget_remaining_default": 12500,
"budget_remaining_normalized": 10000,
"projected_revenue": 0,
"projected_revenue_default": 0,
"projected_revenue_normalized": 0,
"future_revenue": 0,
"future_revenue_default": 0,
"future_revenue_normalized": 0,
"future_budget_used": 0,
"future_budget_used_default": 0,
"future_budget_used_normalized": 0,
"future_cost": 0,
"future_cost_default": 0,
"future_cost_normalized": 0,
"forecasted_revenue": 0,
"forecasted_revenue_default": 0,
"forecasted_revenue_normalized": 0,
"forecasted_cost": 0,
"forecasted_cost_default": 0,
"forecasted_cost_normalized": 0,
"forecasted_profit": 0,
"forecasted_profit_default": 0,
"forecasted_profit_normalized": 0,
"forecasted_budget_used": 0,
"forecasted_budget_used_default": 0,
"forecasted_budget_used_normalized": 0,
"invoiced_rate": 0,
"invoiced_rate_default": 0,
"invoiced_rate_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"creator": {
"data": {
"type": "people",
"id": "659"
}
},
"company": {
"data": {
"type": "companies",
"id": "865"
}
},
"document_type": {
"data": null
},
"responsible": {
"data": {
"type": "people",
"id": "660"
}
},
"deal_status": {
"data": null
},
"project": {
"data": {
"type": "projects",
"id": "89"
}
},
"lost_reason": {
"data": null
},
"contract": {
"data": null
},
"contact": {
"data": null
},
"subsidiary": {
"data": null
}
}
},
{
"id": "26",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
}
}
},
{
"id": "659",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user660@email.com",
"title": null,
"joined_at": "2021-04-15T01:03:39.000+02:00",
"last_seen_at": "2021-04-15T01:03:39.826+02:00",
"deactivated_at": null,
"archived_at": null,
"role_id": 1,
"invited_at": null,
"is_user": true,
"user_id": 660,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:39.580+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"company": {
"data": {
"type": "companies",
"id": "864"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "865",
"type": "companies",
"attributes": {
"name": "Client578",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.601+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "660",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user661@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:39.000+02:00",
"is_user": true,
"user_id": 661,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:39.611+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"company": {
"data": {
"type": "companies",
"id": "866"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "89",
"type": "projects",
"attributes": {
"name": "test project",
"number": 1,
"project_type_id": 2,
"project_color_id": null,
"last_activity_at": null,
"public_access": true,
"time_on_tasks": false,
"tag_colors": {},
"archived_at": null,
"created_at": "2021-04-15T01:03:39.670+02:00",
"board_count": 0,
"budget_count": 1,
"worked_time": 0,
"estimated_time": 0,
"profit_margin": 0,
"budget_closing_date": null,
"invoice_payment_due": null,
"custom_fields": null,
"task_custom_fields_ids": null,
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "USD",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"needs_invoicing": 0,
"needs_invoicing_default": 0,
"needs_invoicing_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"company": {
"data": {
"type": "companies",
"id": "868"
}
},
"project_manager": {
"data": {
"type": "people",
"id": "661"
}
},
"last_actor": {
"data": null
}
}
},
{
"id": "864",
"type": "companies",
"attributes": {
"name": "Organization286",
"billing_name": null,
"vat": null,
"default_currency": "USD",
"created_at": "2021-04-15T01:03:39.579+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "866",
"type": "companies",
"attributes": {
"name": "Client579",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.607+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "868",
"type": "companies",
"attributes": {
"name": "Client581",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.668+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "661",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user662@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:39.000+02:00",
"is_user": true,
"user_id": 662,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:39.643+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"company": {
"data": {
"type": "companies",
"id": "867"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "867",
"type": "companies",
"attributes": {
"name": "Client580",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:39.639+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 286
}
},
"bill_to": {
"data": null
}
}
}
],
"meta": {
"organization_features": {
"custom_fields": {
"type": "metered",
"limit": 15,
"used": 0
},
"custom_fields_per_project": {
"type": "metered",
"limit": 10,
"used": 0
},
"public_custom_reports": {
"type": "metered",
"limit": 100,
"used": 0
},
"private_custom_reports": {
"type": "metered",
"limit": 30,
"used": 0
},
"scheduling_placeholders": {
"type": "metered",
"limit": 5,
"used": 0
},
"multigrouping": {
"type": "switch",
"available": true
},
"client_access_to_budgets": {
"type": "switch",
"available": true
},
"subsidiaries": {
"type": "switch",
"available": true
},
"time_approvals": {
"type": "switch",
"available": true
},
"expenses_approvals": {
"type": "switch",
"available": true
},
"timeoff_approvals": {
"type": "switch",
"available": true
},
"autotracking": {
"type": "switch",
"available": true
},
"forecasting": {
"type": "switch",
"available": true
},
"webhooks": {
"type": "switch",
"available": true
},
"table_pivoting": {
"type": "switch",
"available": true
},
"formula_fields": {
"type": "switch",
"available": true
},
"single_sign_on": {
"type": "switch",
"available": true
},
"duplicate_tasks": {
"type": "switch",
"available": true
},
"billable_time_rounding": {
"type": "switch",
"available": true
},
"payment_sync": {
"type": "switch",
"available": true
},
"booking_methods": {
"type": "switch",
"available": true
},
"import_tasks_csv": {
"type": "switch",
"available": true
},
"reactions": {
"type": "switch",
"available": true
},
"time_week_view": {
"type": "switch",
"available": true
},
"subtasks": {
"type": "switch",
"available": true
},
"time_calendar_layout": {
"type": "switch",
"available": true
},
"theming": {
"type": "switch",
"available": true
},
"remove_branding": {
"type": "switch",
"available": true
},
"custom_invoicing_email": {
"type": "switch",
"available": true
},
"google_calendar_layout": {
"type": "switch",
"available": true
},
"pulse": {
"type": "switch",
"available": true
}
},
"settings": {}
}
}
POSTÂ Â /api/v2/expenses
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "expenses",
"attributes": {
"name": ""
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/name"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/deal_id"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/service_type"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/amount"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/currency"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "is not an valid currency",
"source": {
"pointer": "data/attributes/currency"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/date"
}
}
]
}
Create a expensePOST/api/v2/expenses
URI Parameters
- name
string
(required) Example: Namename
- deal_id
number
(required) Example: 1deal id
- service_type_id
number
(required) Example: 1service type id
- amount
number
(required) Example: 100amount
- currency
string
(required) Example: EURcurrency
- date
date
(required) Example: 2018-01-01date
PATCH /api/v2/expenses/1
Requests
PATCHÂ Â /api/v2/expenses/16
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "expenses",
"attributes": {
"name": "new name"
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "16",
"type": "expenses",
"attributes": {
"name": "new name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 1,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:41.103+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"deal": {
"data": {
"type": "deals",
"id": "85"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "34"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "675"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
"included": [
{
"id": "85",
"type": "deals",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"end_date": null,
"number": 1,
"suffix": null,
"time_approval": true,
"expense_approval": true,
"client_access": false,
"deal_type_id": 2,
"budget": true,
"sales_status_id": null,
"sales_status_updated_at": null,
"tag_list": [],
"origin_deal_id": null,
"profit_margin": 0,
"discount": null,
"email_key": "f81480a9806440b0f2fd1f9c589723f4",
"purchase_order_number": null,
"custom_fields": null,
"forecasted_billable_time": 0,
"forecasted_margin": 0,
"forecasted_budget_usage": 0,
"forecasted_time_usage": 0,
"budget_usage": 0,
"position": 1,
"budget_revamp": false,
"future_booked_time": 0,
"probability": 50,
"budget_warning": null,
"billable_time": 0,
"estimated_time": 0,
"budgeted_time": 0,
"worked_time": 0,
"time_to_close": null,
"unapproved_entries_count": 0,
"rejected_entries_count": 0,
"estimated_remaining_time": 0,
"unapproved_time": 0,
"lost_comment": null,
"closed_at": null,
"delivered_on": null,
"last_activity_at": null,
"deleted_at": null,
"created_at": "2021-04-15T01:03:41.011+02:00",
"note": null,
"sales_closed_at": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"sales_closed_on": null,
"note_interpolated": null,
"todo_count": 0,
"todo_due_date": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"services_revenue": 0,
"services_revenue_default": 0,
"services_revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"work_cost": 0,
"work_cost_default": 0,
"work_cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"invoiced": 0,
"invoiced_default": 0,
"invoiced_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"expense": 0,
"expense_default": 0,
"expense_normalized": 0,
"expense_billable": 0,
"expense_billable_default": 0,
"expense_billable_normalized": 0,
"budget_total": 0,
"budget_total_default": 0,
"budget_total_normalized": 0,
"budget_used": 0,
"budget_used_default": 0,
"budget_used_normalized": 0,
"actual_rate": 0,
"actual_rate_default": 0,
"actual_rate_normalized": 0,
"budget_remaining": 0,
"budget_remaining_default": 0,
"budget_remaining_normalized": 0,
"projected_revenue": 0,
"projected_revenue_default": 0,
"projected_revenue_normalized": 0,
"future_revenue": 0,
"future_revenue_default": 0,
"future_revenue_normalized": 0,
"future_budget_used": 0,
"future_budget_used_default": 0,
"future_budget_used_normalized": 0,
"future_cost": 0,
"future_cost_default": 0,
"future_cost_normalized": 0,
"forecasted_revenue": 0,
"forecasted_revenue_default": 0,
"forecasted_revenue_normalized": 0,
"forecasted_cost": 0,
"forecasted_cost_default": 0,
"forecasted_cost_normalized": 0,
"forecasted_profit": 0,
"forecasted_profit_default": 0,
"forecasted_profit_normalized": 0,
"forecasted_budget_used": 0,
"forecasted_budget_used_default": 0,
"forecasted_budget_used_normalized": 0,
"invoiced_rate": 0,
"invoiced_rate_default": 0,
"invoiced_rate_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"creator": {
"data": {
"type": "people",
"id": "675"
}
},
"company": {
"data": {
"type": "companies",
"id": "893"
}
},
"document_type": {
"data": null
},
"responsible": {
"data": {
"type": "people",
"id": "676"
}
},
"deal_status": {
"data": null
},
"project": {
"data": {
"type": "projects",
"id": "93"
}
},
"lost_reason": {
"data": null
},
"contract": {
"data": null
},
"contact": {
"data": null
},
"subsidiary": {
"data": null
}
}
},
{
"id": "34",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
}
}
},
{
"id": "675",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user676@email.com",
"title": null,
"joined_at": "2021-04-15T01:03:41.000+02:00",
"last_seen_at": "2021-04-15T01:03:41.142+02:00",
"deactivated_at": null,
"archived_at": null,
"role_id": 1,
"invited_at": null,
"is_user": true,
"user_id": 676,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:40.903+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"company": {
"data": {
"type": "companies",
"id": "892"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "893",
"type": "companies",
"attributes": {
"name": "Client602",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:40.925+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "676",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user677@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:40.000+02:00",
"is_user": true,
"user_id": 677,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:40.934+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"company": {
"data": {
"type": "companies",
"id": "894"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "93",
"type": "projects",
"attributes": {
"name": "test project",
"number": 1,
"project_type_id": 2,
"project_color_id": null,
"last_activity_at": null,
"public_access": true,
"time_on_tasks": false,
"tag_colors": {},
"archived_at": null,
"created_at": "2021-04-15T01:03:40.993+02:00",
"board_count": 0,
"budget_count": 1,
"worked_time": 0,
"estimated_time": 0,
"profit_margin": 0,
"budget_closing_date": null,
"invoice_payment_due": null,
"custom_fields": null,
"task_custom_fields_ids": null,
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "USD",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"needs_invoicing": 0,
"needs_invoicing_default": 0,
"needs_invoicing_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"company": {
"data": {
"type": "companies",
"id": "896"
}
},
"project_manager": {
"data": {
"type": "people",
"id": "677"
}
},
"last_actor": {
"data": null
}
}
},
{
"id": "892",
"type": "companies",
"attributes": {
"name": "Organization290",
"billing_name": null,
"vat": null,
"default_currency": "USD",
"created_at": "2021-04-15T01:03:40.902+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "894",
"type": "companies",
"attributes": {
"name": "Client603",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:40.931+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "896",
"type": "companies",
"attributes": {
"name": "Client605",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:40.990+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "677",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user678@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:40.000+02:00",
"is_user": true,
"user_id": 678,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:40.966+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"company": {
"data": {
"type": "companies",
"id": "895"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "895",
"type": "companies",
"attributes": {
"name": "Client604",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:40.963+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 290
}
},
"bill_to": {
"data": null
}
}
}
],
"meta": {
"organization_features": {
"custom_fields": {
"type": "metered",
"limit": 15,
"used": 0
},
"custom_fields_per_project": {
"type": "metered",
"limit": 10,
"used": 0
},
"public_custom_reports": {
"type": "metered",
"limit": 100,
"used": 0
},
"private_custom_reports": {
"type": "metered",
"limit": 30,
"used": 0
},
"scheduling_placeholders": {
"type": "metered",
"limit": 5,
"used": 0
},
"multigrouping": {
"type": "switch",
"available": true
},
"client_access_to_budgets": {
"type": "switch",
"available": true
},
"subsidiaries": {
"type": "switch",
"available": true
},
"time_approvals": {
"type": "switch",
"available": true
},
"expenses_approvals": {
"type": "switch",
"available": true
},
"timeoff_approvals": {
"type": "switch",
"available": true
},
"autotracking": {
"type": "switch",
"available": true
},
"forecasting": {
"type": "switch",
"available": true
},
"webhooks": {
"type": "switch",
"available": true
},
"table_pivoting": {
"type": "switch",
"available": true
},
"formula_fields": {
"type": "switch",
"available": true
},
"single_sign_on": {
"type": "switch",
"available": true
},
"duplicate_tasks": {
"type": "switch",
"available": true
},
"billable_time_rounding": {
"type": "switch",
"available": true
},
"payment_sync": {
"type": "switch",
"available": true
},
"booking_methods": {
"type": "switch",
"available": true
},
"import_tasks_csv": {
"type": "switch",
"available": true
},
"reactions": {
"type": "switch",
"available": true
},
"time_week_view": {
"type": "switch",
"available": true
},
"subtasks": {
"type": "switch",
"available": true
},
"time_calendar_layout": {
"type": "switch",
"available": true
},
"theming": {
"type": "switch",
"available": true
},
"remove_branding": {
"type": "switch",
"available": true
},
"custom_invoicing_email": {
"type": "switch",
"available": true
},
"google_calendar_layout": {
"type": "switch",
"available": true
},
"pulse": {
"type": "switch",
"available": true
}
},
"settings": {}
}
}
PATCHÂ Â /api/v2/expenses/17
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
"data": {
"type": "expenses",
"attributes": {
"name": ""
}
}
}
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/name"
}
}
]
}
DELETE /api/v2/expenses/1
Requests
DELETEÂ Â /api/v2/expenses/19
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
This response has no content.
PATCH /api/v2/expenses/1/approve
Requests
PATCHÂ Â /api/v2/expenses/21/approve
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "21",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 1,
"invoiced": false,
"approved": true,
"approved_at": "2021-04-15T01:03:42.792+02:00",
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:42.750+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"deal": {
"data": {
"type": "deals",
"id": "95"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "44"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "696"
}
},
"approver": {
"data": {
"type": "people",
"id": "696"
}
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
"included": [
{
"id": "95",
"type": "deals",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"end_date": null,
"number": 1,
"suffix": null,
"time_approval": true,
"expense_approval": true,
"client_access": false,
"deal_type_id": 2,
"budget": true,
"sales_status_id": null,
"sales_status_updated_at": null,
"tag_list": [],
"origin_deal_id": null,
"profit_margin": 0,
"discount": null,
"email_key": "38028ed33cc0c6503bb93f4b85a63f37",
"purchase_order_number": null,
"custom_fields": null,
"forecasted_billable_time": 0,
"forecasted_margin": 0,
"forecasted_budget_usage": 0,
"forecasted_time_usage": 0,
"budget_usage": 0,
"position": 1,
"budget_revamp": false,
"future_booked_time": 0,
"probability": 50,
"budget_warning": null,
"billable_time": 0,
"estimated_time": 0,
"budgeted_time": 0,
"worked_time": 0,
"time_to_close": null,
"unapproved_entries_count": 0,
"rejected_entries_count": 0,
"estimated_remaining_time": 0,
"unapproved_time": 0,
"lost_comment": null,
"closed_at": null,
"delivered_on": null,
"last_activity_at": null,
"deleted_at": null,
"created_at": "2021-04-15T01:03:42.654+02:00",
"note": null,
"sales_closed_at": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"sales_closed_on": null,
"note_interpolated": null,
"todo_count": 0,
"todo_due_date": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"services_revenue": 0,
"services_revenue_default": 0,
"services_revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"work_cost": 0,
"work_cost_default": 0,
"work_cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"invoiced": 0,
"invoiced_default": 0,
"invoiced_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"expense": 0,
"expense_default": 0,
"expense_normalized": 0,
"expense_billable": 0,
"expense_billable_default": 0,
"expense_billable_normalized": 0,
"budget_total": 0,
"budget_total_default": 0,
"budget_total_normalized": 0,
"budget_used": 0,
"budget_used_default": 0,
"budget_used_normalized": 0,
"actual_rate": 0,
"actual_rate_default": 0,
"actual_rate_normalized": 0,
"budget_remaining": 0,
"budget_remaining_default": 0,
"budget_remaining_normalized": 0,
"projected_revenue": 0,
"projected_revenue_default": 0,
"projected_revenue_normalized": 0,
"future_revenue": 0,
"future_revenue_default": 0,
"future_revenue_normalized": 0,
"future_budget_used": 0,
"future_budget_used_default": 0,
"future_budget_used_normalized": 0,
"future_cost": 0,
"future_cost_default": 0,
"future_cost_normalized": 0,
"forecasted_revenue": 0,
"forecasted_revenue_default": 0,
"forecasted_revenue_normalized": 0,
"forecasted_cost": 0,
"forecasted_cost_default": 0,
"forecasted_cost_normalized": 0,
"forecasted_profit": 0,
"forecasted_profit_default": 0,
"forecasted_profit_normalized": 0,
"forecasted_budget_used": 0,
"forecasted_budget_used_default": 0,
"forecasted_budget_used_normalized": 0,
"invoiced_rate": 0,
"invoiced_rate_default": 0,
"invoiced_rate_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"creator": {
"data": {
"type": "people",
"id": "696"
}
},
"company": {
"data": {
"type": "companies",
"id": "929"
}
},
"document_type": {
"data": null
},
"responsible": {
"data": {
"type": "people",
"id": "697"
}
},
"deal_status": {
"data": null
},
"project": {
"data": {
"type": "projects",
"id": "98"
}
},
"lost_reason": {
"data": null
},
"contract": {
"data": null
},
"contact": {
"data": null
},
"subsidiary": {
"data": null
}
}
},
{
"id": "44",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
}
}
},
{
"id": "696",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user697@email.com",
"title": null,
"joined_at": "2021-04-15T01:03:42.000+02:00",
"last_seen_at": "2021-04-15T01:03:42.789+02:00",
"deactivated_at": null,
"archived_at": null,
"role_id": 1,
"invited_at": null,
"is_user": true,
"user_id": 697,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:42.543+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"company": {
"data": {
"type": "companies",
"id": "928"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "929",
"type": "companies",
"attributes": {
"name": "Client633",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:42.564+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "697",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user698@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:42.000+02:00",
"is_user": true,
"user_id": 698,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:42.574+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"company": {
"data": {
"type": "companies",
"id": "930"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "98",
"type": "projects",
"attributes": {
"name": "test project",
"number": 1,
"project_type_id": 2,
"project_color_id": null,
"last_activity_at": null,
"public_access": true,
"time_on_tasks": false,
"tag_colors": {},
"archived_at": null,
"created_at": "2021-04-15T01:03:42.634+02:00",
"board_count": 0,
"budget_count": 1,
"worked_time": 0,
"estimated_time": 0,
"profit_margin": 0,
"budget_closing_date": null,
"invoice_payment_due": null,
"custom_fields": null,
"task_custom_fields_ids": null,
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "USD",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"needs_invoicing": 0,
"needs_invoicing_default": 0,
"needs_invoicing_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"company": {
"data": {
"type": "companies",
"id": "932"
}
},
"project_manager": {
"data": {
"type": "people",
"id": "698"
}
},
"last_actor": {
"data": null
}
}
},
{
"id": "928",
"type": "companies",
"attributes": {
"name": "Organization295",
"billing_name": null,
"vat": null,
"default_currency": "USD",
"created_at": "2021-04-15T01:03:42.541+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "930",
"type": "companies",
"attributes": {
"name": "Client634",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:42.570+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "932",
"type": "companies",
"attributes": {
"name": "Client636",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:42.632+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "698",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user699@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:42.000+02:00",
"is_user": true,
"user_id": 699,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:42.607+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"company": {
"data": {
"type": "companies",
"id": "931"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "931",
"type": "companies",
"attributes": {
"name": "Client635",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:42.603+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 295
}
},
"bill_to": {
"data": null
}
}
}
],
"meta": {
"organization_features": {
"custom_fields": {
"type": "metered",
"limit": 15,
"used": 0
},
"custom_fields_per_project": {
"type": "metered",
"limit": 10,
"used": 0
},
"public_custom_reports": {
"type": "metered",
"limit": 100,
"used": 0
},
"private_custom_reports": {
"type": "metered",
"limit": 30,
"used": 0
},
"scheduling_placeholders": {
"type": "metered",
"limit": 5,
"used": 0
},
"multigrouping": {
"type": "switch",
"available": true
},
"client_access_to_budgets": {
"type": "switch",
"available": true
},
"subsidiaries": {
"type": "switch",
"available": true
},
"time_approvals": {
"type": "switch",
"available": true
},
"expenses_approvals": {
"type": "switch",
"available": true
},
"timeoff_approvals": {
"type": "switch",
"available": true
},
"autotracking": {
"type": "switch",
"available": true
},
"forecasting": {
"type": "switch",
"available": true
},
"webhooks": {
"type": "switch",
"available": true
},
"table_pivoting": {
"type": "switch",
"available": true
},
"formula_fields": {
"type": "switch",
"available": true
},
"single_sign_on": {
"type": "switch",
"available": true
},
"duplicate_tasks": {
"type": "switch",
"available": true
},
"billable_time_rounding": {
"type": "switch",
"available": true
},
"payment_sync": {
"type": "switch",
"available": true
},
"booking_methods": {
"type": "switch",
"available": true
},
"import_tasks_csv": {
"type": "switch",
"available": true
},
"reactions": {
"type": "switch",
"available": true
},
"time_week_view": {
"type": "switch",
"available": true
},
"subtasks": {
"type": "switch",
"available": true
},
"time_calendar_layout": {
"type": "switch",
"available": true
},
"theming": {
"type": "switch",
"available": true
},
"remove_branding": {
"type": "switch",
"available": true
},
"custom_invoicing_email": {
"type": "switch",
"available": true
},
"google_calendar_layout": {
"type": "switch",
"available": true
},
"pulse": {
"type": "switch",
"available": true
}
},
"settings": {}
}
}
Approves an expensePATCH/api/v2/expenses/{id}/approve
URI Parameters
- id
number
(required) Example: 1expense id
PATCH /api/v2/expenses/1/unapprove
Requests
PATCHÂ Â /api/v2/expenses/24/unapprove
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
"data": {
"id": "24",
"type": "expenses",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"pay_on": null,
"paid_on": null,
"position": 1,
"invoiced": false,
"approved": false,
"approved_at": null,
"rejected": false,
"rejected_reason": null,
"rejected_at": null,
"deleted_at": null,
"reimbursable": null,
"reimbursed_on": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"created_at": "2021-04-15T01:03:43.586+02:00",
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 10000,
"amount_default": 12500,
"amount_normalized": 10000,
"billable_amount": 0,
"billable_amount_default": 0,
"billable_amount_normalized": 0,
"profit": -10000,
"profit_default": -12500,
"profit_normalized": -10000
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"deal": {
"data": {
"type": "deals",
"id": "100"
}
},
"service_type": {
"data": {
"type": "service_types",
"id": "50"
}
},
"person": {
"data": null
},
"creator": {
"data": {
"type": "people",
"id": "705"
}
},
"approver": {
"data": null
},
"rejecter": {
"data": null
},
"vendor": {
"data": null
},
"service": {
"data": null
},
"attachment": {
"data": null
}
}
},
"included": [
{
"id": "100",
"type": "deals",
"attributes": {
"name": "test name",
"date": "2021-04-15",
"end_date": null,
"number": 1,
"suffix": null,
"time_approval": true,
"expense_approval": true,
"client_access": false,
"deal_type_id": 2,
"budget": true,
"sales_status_id": null,
"sales_status_updated_at": null,
"tag_list": [],
"origin_deal_id": null,
"profit_margin": 0,
"discount": null,
"email_key": "26713418a7fa8ee12c85043a6446fd26",
"purchase_order_number": null,
"custom_fields": null,
"forecasted_billable_time": 0,
"forecasted_margin": 0,
"forecasted_budget_usage": 0,
"forecasted_time_usage": 0,
"budget_usage": 0,
"position": 1,
"budget_revamp": false,
"future_booked_time": 0,
"probability": 50,
"budget_warning": null,
"billable_time": 0,
"estimated_time": 0,
"budgeted_time": 0,
"worked_time": 0,
"time_to_close": null,
"unapproved_entries_count": 0,
"rejected_entries_count": 0,
"estimated_remaining_time": 0,
"unapproved_time": 0,
"lost_comment": null,
"closed_at": null,
"delivered_on": null,
"last_activity_at": null,
"deleted_at": null,
"created_at": "2021-04-15T01:03:43.459+02:00",
"note": null,
"sales_closed_at": null,
"exchange_rate": "1.25",
"exchange_date": "2021-04-15",
"sales_closed_on": null,
"note_interpolated": null,
"todo_count": 0,
"todo_due_date": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"services_revenue": 0,
"services_revenue_default": 0,
"services_revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"work_cost": 0,
"work_cost_default": 0,
"work_cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"invoiced": 0,
"invoiced_default": 0,
"invoiced_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"expense": 0,
"expense_default": 0,
"expense_normalized": 0,
"expense_billable": 0,
"expense_billable_default": 0,
"expense_billable_normalized": 0,
"budget_total": 0,
"budget_total_default": 0,
"budget_total_normalized": 0,
"budget_used": 0,
"budget_used_default": 0,
"budget_used_normalized": 0,
"actual_rate": 0,
"actual_rate_default": 0,
"actual_rate_normalized": 0,
"budget_remaining": 0,
"budget_remaining_default": 0,
"budget_remaining_normalized": 0,
"projected_revenue": 0,
"projected_revenue_default": 0,
"projected_revenue_normalized": 0,
"future_revenue": 0,
"future_revenue_default": 0,
"future_revenue_normalized": 0,
"future_budget_used": 0,
"future_budget_used_default": 0,
"future_budget_used_normalized": 0,
"future_cost": 0,
"future_cost_default": 0,
"future_cost_normalized": 0,
"forecasted_revenue": 0,
"forecasted_revenue_default": 0,
"forecasted_revenue_normalized": 0,
"forecasted_cost": 0,
"forecasted_cost_default": 0,
"forecasted_cost_normalized": 0,
"forecasted_profit": 0,
"forecasted_profit_default": 0,
"forecasted_profit_normalized": 0,
"forecasted_budget_used": 0,
"forecasted_budget_used_default": 0,
"forecasted_budget_used_normalized": 0,
"invoiced_rate": 0,
"invoiced_rate_default": 0,
"invoiced_rate_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"creator": {
"data": {
"type": "people",
"id": "705"
}
},
"company": {
"data": {
"type": "companies",
"id": "945"
}
},
"document_type": {
"data": null
},
"responsible": {
"data": {
"type": "people",
"id": "706"
}
},
"deal_status": {
"data": null
},
"project": {
"data": {
"type": "projects",
"id": "100"
}
},
"lost_reason": {
"data": null
},
"contract": {
"data": null
},
"contact": {
"data": null
},
"subsidiary": {
"data": null
}
}
},
{
"id": "50",
"type": "service_types",
"attributes": {
"name": "test name",
"category_id": null,
"archived_at": null,
"description": "test description"
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
}
}
},
{
"id": "705",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user706@email.com",
"title": null,
"joined_at": "2021-04-15T01:03:43.000+02:00",
"last_seen_at": "2021-04-15T01:03:43.627+02:00",
"deactivated_at": null,
"archived_at": null,
"role_id": 1,
"invited_at": null,
"is_user": true,
"user_id": 706,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:43.352+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"company": {
"data": {
"type": "companies",
"id": "944"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "945",
"type": "companies",
"attributes": {
"name": "Client647",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:43.373+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "706",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user707@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:43.000+02:00",
"is_user": true,
"user_id": 707,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:43.383+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"company": {
"data": {
"type": "companies",
"id": "946"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "100",
"type": "projects",
"attributes": {
"name": "test project",
"number": 1,
"project_type_id": 2,
"project_color_id": null,
"last_activity_at": null,
"public_access": true,
"time_on_tasks": false,
"tag_colors": {},
"archived_at": null,
"created_at": "2021-04-15T01:03:43.441+02:00",
"board_count": 0,
"budget_count": 1,
"worked_time": 0,
"estimated_time": 0,
"profit_margin": 0,
"budget_closing_date": null,
"invoice_payment_due": null,
"custom_fields": null,
"task_custom_fields_ids": null,
"currency": "USD",
"currency_default": "USD",
"currency_normalized": "USD",
"revenue": 0,
"revenue_default": 0,
"revenue_normalized": 0,
"cost": 0,
"cost_default": 0,
"cost_normalized": 0,
"profit": 0,
"profit_default": 0,
"profit_normalized": 0,
"pending_invoicing": 0,
"pending_invoicing_default": 0,
"pending_invoicing_normalized": 0,
"needs_invoicing": 0,
"needs_invoicing_default": 0,
"needs_invoicing_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"company": {
"data": {
"type": "companies",
"id": "948"
}
},
"project_manager": {
"data": {
"type": "people",
"id": "707"
}
},
"last_actor": {
"data": null
}
}
},
{
"id": "944",
"type": "companies",
"attributes": {
"name": "Organization297",
"billing_name": null,
"vat": null,
"default_currency": "USD",
"created_at": "2021-04-15T01:03:43.351+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "946",
"type": "companies",
"attributes": {
"name": "Client648",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:43.379+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "948",
"type": "companies",
"attributes": {
"name": "Client650",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:43.438+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"bill_to": {
"data": null
}
}
},
{
"id": "707",
"type": "people",
"attributes": {
"first_name": "test first name",
"last_name": "test last name",
"email": "user708@email.com",
"title": null,
"joined_at": null,
"last_seen_at": null,
"deactivated_at": null,
"archived_at": null,
"role_id": 3,
"invited_at": "2021-04-15T01:03:43.000+02:00",
"is_user": true,
"user_id": 708,
"tag_list": [],
"avatar_url": null,
"virtual": false,
"custom_fields": null,
"autotracking": false,
"created_at": "2021-04-15T01:03:43.414+02:00",
"placeholder": false,
"color_id": null,
"private_custom_reports_used": 0,
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"company": {
"data": {
"type": "companies",
"id": "947"
}
},
"subsidiary": {
"data": null
}
}
},
{
"id": "947",
"type": "companies",
"attributes": {
"name": "Client649",
"billing_name": null,
"vat": null,
"default_currency": null,
"created_at": "2021-04-15T01:03:43.411+02:00",
"archived_at": null,
"avatar_url": null,
"invoice_email_recipients": {},
"custom_fields": null,
"description": null,
"due_days": null,
"tag_list": [],
"contact": {}
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": 297
}
},
"bill_to": {
"data": null
}
}
}
],
"meta": {
"organization_features": {
"custom_fields": {
"type": "metered",
"limit": 15,
"used": 0
},
"custom_fields_per_project": {
"type": "metered",
"limit": 10,
"used": 0
},
"public_custom_reports": {
"type": "metered",
"limit": 100,
"used": 0
},
"private_custom_reports": {
"type": "metered",
"limit": 30,
"used": 0
},
"scheduling_placeholders": {
"type": "metered",
"limit": 5,
"used": 0
},
"multigrouping": {
"type": "switch",
"available": true
},
"client_access_to_budgets": {
"type": "switch",
"available": true
},
"subsidiaries": {
"type": "switch",
"available": true
},
"time_approvals": {
"type": "switch",
"available": true
},
"expenses_approvals": {
"type": "switch",
"available": true
},
"timeoff_approvals": {
"type": "switch",
"available": true
},
"autotracking": {
"type": "switch",
"available": true
},
"forecasting": {
"type": "switch",
"available": true
},
"webhooks": {
"type": "switch",
"available": true
},
"table_pivoting": {
"type": "switch",
"available": true
},
"formula_fields": {
"type": "switch",
"available": true
},
"single_sign_on": {
"type": "switch",
"available": true
},
"duplicate_tasks": {
"type": "switch",
"available": true
},
"billable_time_rounding": {
"type": "switch",
"available": true
},
"payment_sync": {
"type": "switch",
"available": true
},
"booking_methods": {
"type": "switch",
"available": true
},
"import_tasks_csv": {
"type": "switch",
"available": true
},
"reactions": {
"type": "switch",
"available": true
},
"time_week_view": {
"type": "switch",
"available": true
},
"subtasks": {
"type": "switch",
"available": true
},
"time_calendar_layout": {
"type": "switch",
"available": true
},
"theming": {
"type": "switch",
"available": true
},
"remove_branding": {
"type": "switch",
"available": true
},
"custom_invoicing_email": {
"type": "switch",
"available": true
},
"google_calendar_layout": {
"type": "switch",
"available": true
},
"pulse": {
"type": "switch",
"available": true
}
},
"settings": {}
}
}
Unapproves an expensePATCH/api/v2/expenses/{id}/unapprove
URI Parameters
- id
number
(required) Example: 1expense id
Generated by aglio on 14 Apr 2021