API Documentation

API Endpoint

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

Supported aggregates params

  • total_amount

  • total_billable_amount

  • total_profit

Filter operations are supported on this endpoint.

GET /api/v2/expenses
Requestsreturns expenses

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
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": [
    {
      "id": "7",
      "type": "expenses",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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,
        "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": 252
          }
        },
        "deal": {
          "data": {
            "type": "deals",
            "id": "69"
          }
        },
        "service_type": {
          "data": {
            "type": "service_types",
            "id": "14"
          }
        },
        "person": {
          "data": null
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "486"
          }
        },
        "approver": {
          "data": null
        },
        "rejecter": {
          "data": null
        },
        "vendor": {
          "data": null
        },
        "attachment": {
          "data": null
        }
      }
    },
    {
      "id": "8",
      "type": "expenses",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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,
        "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": 252
          }
        },
        "deal": {
          "data": {
            "type": "deals",
            "id": "69"
          }
        },
        "service_type": {
          "data": {
            "type": "service_types",
            "id": "15"
          }
        },
        "person": {
          "data": null
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "486"
          }
        },
        "approver": {
          "data": null
        },
        "rejecter": {
          "data": null
        },
        "vendor": {
          "data": null
        },
        "attachment": {
          "data": null
        }
      }
    },
    {
      "id": "9",
      "type": "expenses",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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,
        "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": 252
          }
        },
        "deal": {
          "data": {
            "type": "deals",
            "id": "69"
          }
        },
        "service_type": {
          "data": {
            "type": "service_types",
            "id": "16"
          }
        },
        "person": {
          "data": null
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "486"
          }
        },
        "approver": {
          "data": null
        },
        "rejecter": {
          "data": null
        },
        "vendor": {
          "data": null
        },
        "attachment": {
          "data": null
        }
      }
    }
  ],
  "included": [
    {
      "id": "69",
      "type": "deals",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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": "dcbe3be6e9785cd36337ec9886950291",
        "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,
        "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": "2020-08-11T01:04:24.609+02:00",
        "note": null,
        "sales_closed_at": 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": 30000,
        "cost_default": 37500,
        "cost_normalized": 30000,
        "work_cost": 0,
        "work_cost_default": 0,
        "work_cost_normalized": 0,
        "profit": -30000,
        "profit_default": -37500,
        "profit_normalized": -30000,
        "invoiced": 0,
        "invoiced_default": 0,
        "invoiced_normalized": 0,
        "pending_invoicing": 0,
        "pending_invoicing_default": 0,
        "pending_invoicing_normalized": 0,
        "expense": 30000,
        "expense_default": 37500,
        "expense_normalized": 30000,
        "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": 30000,
        "forecasted_cost_default": 37500,
        "forecasted_cost_normalized": 30000,
        "forecasted_profit": -30000,
        "forecasted_profit_default": -37500,
        "forecasted_profit_normalized": -30000,
        "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": 252
          }
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "486"
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "647"
          }
        },
        "document_type": {
          "data": null
        },
        "responsible": {
          "data": {
            "type": "people",
            "id": "487"
          }
        },
        "deal_status": {
          "data": null
        },
        "project": {
          "data": {
            "type": "projects",
            "id": "58"
          }
        },
        "lost_reason": {
          "data": null
        },
        "contract": {
          "data": null
        },
        "contact": {
          "data": null
        }
      }
    },
    {
      "id": "14",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        }
      }
    },
    {
      "id": "486",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user488@email.com",
        "title": null,
        "joined_at": "2020-08-11T01:04:24.000+02:00",
        "last_seen_at": "2020-08-11T01:04:24.694+02:00",
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 1,
        "invited_at": null,
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:24.525+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "646"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "15",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        }
      }
    },
    {
      "id": "16",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        }
      }
    },
    {
      "id": "647",
      "type": "companies",
      "attributes": {
        "name": "Client394",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.541+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "487",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user489@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:24.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:24.550+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "648"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "58",
      "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,
        "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,
        "currency": "USD",
        "currency_default": "USD",
        "currency_normalized": "USD",
        "revenue": 0,
        "revenue_default": 0,
        "revenue_normalized": 0,
        "cost": 37500,
        "cost_default": 37500,
        "cost_normalized": 37500,
        "profit": -37500,
        "profit_default": -37500,
        "profit_normalized": -37500,
        "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": 252
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "650"
          }
        },
        "project_manager": {
          "data": {
            "type": "people",
            "id": "488"
          }
        },
        "last_actor": {
          "data": null
        }
      }
    },
    {
      "id": "646",
      "type": "companies",
      "attributes": {
        "name": "Organization252",
        "default_currency": "USD",
        "created_at": "2020-08-11T01:04:24.524+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "648",
      "type": "companies",
      "attributes": {
        "name": "Client395",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.546+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "650",
      "type": "companies",
      "attributes": {
        "name": "Client397",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.588+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "488",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user490@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:24.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:24.572+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "649"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "649",
      "type": "companies",
      "attributes": {
        "name": "Client396",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.569+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 252
          }
        },
        "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": 30,
        "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
      }
    }
  }
}

Get expenses
GET/api/v2/expenses


GET /api/v2/expenses/1
Requestsreturns expense

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
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "10",
    "type": "expenses",
    "attributes": {
      "name": "test name",
      "date": "2020-08-11",
      "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,
      "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": 253
        }
      },
      "deal": {
        "data": {
          "type": "deals",
          "id": "70"
        }
      },
      "service_type": {
        "data": {
          "type": "service_types",
          "id": "17"
        }
      },
      "person": {
        "data": null
      },
      "creator": {
        "data": {
          "type": "people",
          "id": "489"
        }
      },
      "approver": {
        "data": null
      },
      "rejecter": {
        "data": null
      },
      "vendor": {
        "data": null
      },
      "attachment": {
        "data": null
      }
    }
  },
  "included": [
    {
      "id": "70",
      "type": "deals",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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": "3c98649e564fe3fc79a641d725abdfe4",
        "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,
        "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": "2020-08-11T01:04:24.915+02:00",
        "note": null,
        "sales_closed_at": 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": 10000,
        "cost_default": 12500,
        "cost_normalized": 10000,
        "work_cost": 0,
        "work_cost_default": 0,
        "work_cost_normalized": 0,
        "profit": -10000,
        "profit_default": -12500,
        "profit_normalized": -10000,
        "invoiced": 0,
        "invoiced_default": 0,
        "invoiced_normalized": 0,
        "pending_invoicing": 0,
        "pending_invoicing_default": 0,
        "pending_invoicing_normalized": 0,
        "expense": 10000,
        "expense_default": 12500,
        "expense_normalized": 10000,
        "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": 10000,
        "forecasted_cost_default": 12500,
        "forecasted_cost_normalized": 10000,
        "forecasted_profit": -10000,
        "forecasted_profit_default": -12500,
        "forecasted_profit_normalized": -10000,
        "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": 253
          }
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "489"
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "652"
          }
        },
        "document_type": {
          "data": null
        },
        "responsible": {
          "data": {
            "type": "people",
            "id": "490"
          }
        },
        "deal_status": {
          "data": null
        },
        "project": {
          "data": {
            "type": "projects",
            "id": "59"
          }
        },
        "lost_reason": {
          "data": null
        },
        "contract": {
          "data": null
        },
        "contact": {
          "data": null
        }
      }
    },
    {
      "id": "17",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        }
      }
    },
    {
      "id": "489",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user491@email.com",
        "title": null,
        "joined_at": "2020-08-11T01:04:24.000+02:00",
        "last_seen_at": "2020-08-11T01:04:24.965+02:00",
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 1,
        "invited_at": null,
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:24.800+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "651"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "652",
      "type": "companies",
      "attributes": {
        "name": "Client398",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.815+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "490",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user492@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:24.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:24.825+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "653"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "59",
      "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,
        "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,
        "currency": "USD",
        "currency_default": "USD",
        "currency_normalized": "USD",
        "revenue": 0,
        "revenue_default": 0,
        "revenue_normalized": 0,
        "cost": 12500,
        "cost_default": 12500,
        "cost_normalized": 12500,
        "profit": -12500,
        "profit_default": -12500,
        "profit_normalized": -12500,
        "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": 253
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "655"
          }
        },
        "project_manager": {
          "data": {
            "type": "people",
            "id": "491"
          }
        },
        "last_actor": {
          "data": null
        }
      }
    },
    {
      "id": "651",
      "type": "companies",
      "attributes": {
        "name": "Organization253",
        "default_currency": "USD",
        "created_at": "2020-08-11T01:04:24.798+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "653",
      "type": "companies",
      "attributes": {
        "name": "Client399",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.821+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "655",
      "type": "companies",
      "attributes": {
        "name": "Client401",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.893+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "491",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user493@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:24.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:24.870+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "654"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "654",
      "type": "companies",
      "attributes": {
        "name": "Client400",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:24.864+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 253
          }
        },
        "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": 30,
        "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
      }
    }
  }
}

Gets a expense
GET/api/v2/expenses/{id}

URI Parameters
HideShow
id
number (required) Example: 1

expense id


POST /api/v2/expenses
Requestscreates expensereturns error

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,
      "currency": "USD",
      "date": "2020-08-11"
    },
    "relationships": {
      "deal": {
        "data": {
          "type": "deals",
          "id": "71"
        }
      },
      "service_type": {
        "data": {
          "type": "service-type",
          "id": "18"
        }
      },
      "person": {
        "data": {
          "type": "people",
          "id": "492"
        }
      }
    }
  }
}
Responses201
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "12",
    "type": "expenses",
    "attributes": {
      "name": "test name",
      "date": "2020-08-11",
      "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,
      "currency": "USD",
      "currency_default": "USD",
      "currency_normalized": "EUR",
      "amount": 10000,
      "amount_default": 10000,
      "amount_normalized": 8000,
      "billable_amount": 0,
      "billable_amount_default": 0,
      "billable_amount_normalized": 0,
      "profit": -8000,
      "profit_default": -10000,
      "profit_normalized": -8000
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": 254
        }
      },
      "deal": {
        "data": {
          "type": "deals",
          "id": "71"
        }
      },
      "service_type": {
        "data": {
          "type": "service_types",
          "id": "18"
        }
      },
      "person": {
        "data": {
          "type": "people",
          "id": "492"
        }
      },
      "creator": {
        "data": {
          "type": "people",
          "id": "492"
        }
      },
      "approver": {
        "data": null
      },
      "rejecter": {
        "data": null
      },
      "vendor": {
        "data": null
      },
      "attachment": {
        "data": null
      }
    }
  },
  "included": [
    {
      "id": "71",
      "type": "deals",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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": "baae67844622c908199807a0220ceca1",
        "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,
        "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": "2020-08-11T01:04:25.214+02:00",
        "note": null,
        "sales_closed_at": 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": 18000,
        "cost_default": 22500,
        "cost_normalized": 18000,
        "work_cost": 0,
        "work_cost_default": 0,
        "work_cost_normalized": 0,
        "profit": -18000,
        "profit_default": -22500,
        "profit_normalized": -18000,
        "invoiced": 0,
        "invoiced_default": 0,
        "invoiced_normalized": 0,
        "pending_invoicing": 0,
        "pending_invoicing_default": 0,
        "pending_invoicing_normalized": 0,
        "expense": 18000,
        "expense_default": 22500,
        "expense_normalized": 18000,
        "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": 18000,
        "forecasted_cost_default": 22500,
        "forecasted_cost_normalized": 18000,
        "forecasted_profit": -18000,
        "forecasted_profit_default": -22500,
        "forecasted_profit_normalized": -18000,
        "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": 254
          }
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "492"
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "657"
          }
        },
        "document_type": {
          "data": null
        },
        "responsible": {
          "data": {
            "type": "people",
            "id": "493"
          }
        },
        "deal_status": {
          "data": null
        },
        "project": {
          "data": {
            "type": "projects",
            "id": "60"
          }
        },
        "lost_reason": {
          "data": null
        },
        "contract": {
          "data": null
        },
        "contact": {
          "data": null
        }
      }
    },
    {
      "id": "18",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        }
      }
    },
    {
      "id": "492",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user494@email.com",
        "title": null,
        "joined_at": "2020-08-11T01:04:25.000+02:00",
        "last_seen_at": "2020-08-11T01:04:25.269+02:00",
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 1,
        "invited_at": null,
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:25.103+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "656"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "657",
      "type": "companies",
      "attributes": {
        "name": "Client402",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:25.127+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "493",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user495@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:25.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:25.142+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "658"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "60",
      "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,
        "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,
        "currency": "USD",
        "currency_default": "USD",
        "currency_normalized": "USD",
        "revenue": 0,
        "revenue_default": 0,
        "revenue_normalized": 0,
        "cost": 22500,
        "cost_default": 22500,
        "cost_normalized": 22500,
        "profit": -22500,
        "profit_default": -22500,
        "profit_normalized": -22500,
        "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": 254
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "660"
          }
        },
        "project_manager": {
          "data": {
            "type": "people",
            "id": "494"
          }
        },
        "last_actor": {
          "data": null
        }
      }
    },
    {
      "id": "656",
      "type": "companies",
      "attributes": {
        "name": "Organization254",
        "default_currency": "USD",
        "created_at": "2020-08-11T01:04:25.100+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "658",
      "type": "companies",
      "attributes": {
        "name": "Client403",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:25.137+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "660",
      "type": "companies",
      "attributes": {
        "name": "Client405",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:25.189+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "494",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user496@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:25.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:25.171+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "659"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "659",
      "type": "companies",
      "attributes": {
        "name": "Client404",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:25.167+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 254
          }
        },
        "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": 30,
        "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
      }
    }
  }
}

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": ""
    }
  }
}
Responses422
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"
      }
    },
    {
      "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 expense
POST/api/v2/expenses

URI Parameters
HideShow
name
string (required) Example: Name

name

deal_id
number (required) Example: 1

deal id

service_type_id
number (required) Example: 1

service type id

amount
number (required) Example: 100

amount

currency
string (required) Example: EUR

currency

date
date (required) Example: 2018-01-01

date


PATCH /api/v2/expenses/1
Requestsupdates expensereturns error

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"
    }
  }
}
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "16",
    "type": "expenses",
    "attributes": {
      "name": "new name",
      "date": "2020-08-11",
      "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,
      "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": 258
        }
      },
      "deal": {
        "data": {
          "type": "deals",
          "id": "75"
        }
      },
      "service_type": {
        "data": {
          "type": "service_types",
          "id": "22"
        }
      },
      "person": {
        "data": null
      },
      "creator": {
        "data": {
          "type": "people",
          "id": "504"
        }
      },
      "approver": {
        "data": null
      },
      "rejecter": {
        "data": null
      },
      "vendor": {
        "data": null
      },
      "attachment": {
        "data": null
      }
    }
  },
  "included": [
    {
      "id": "75",
      "type": "deals",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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": "8316ff7dcc4d36c734ccf250ec813f90",
        "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,
        "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": "2020-08-11T01:04:26.222+02:00",
        "note": null,
        "sales_closed_at": 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": 10000,
        "cost_default": 12500,
        "cost_normalized": 10000,
        "work_cost": 0,
        "work_cost_default": 0,
        "work_cost_normalized": 0,
        "profit": -10000,
        "profit_default": -12500,
        "profit_normalized": -10000,
        "invoiced": 0,
        "invoiced_default": 0,
        "invoiced_normalized": 0,
        "pending_invoicing": 0,
        "pending_invoicing_default": 0,
        "pending_invoicing_normalized": 0,
        "expense": 10000,
        "expense_default": 12500,
        "expense_normalized": 10000,
        "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": 10000,
        "forecasted_cost_default": 12500,
        "forecasted_cost_normalized": 10000,
        "forecasted_profit": -10000,
        "forecasted_profit_default": -12500,
        "forecasted_profit_normalized": -10000,
        "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": 258
          }
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "504"
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "677"
          }
        },
        "document_type": {
          "data": null
        },
        "responsible": {
          "data": {
            "type": "people",
            "id": "505"
          }
        },
        "deal_status": {
          "data": null
        },
        "project": {
          "data": {
            "type": "projects",
            "id": "64"
          }
        },
        "lost_reason": {
          "data": null
        },
        "contract": {
          "data": null
        },
        "contact": {
          "data": null
        }
      }
    },
    {
      "id": "22",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        }
      }
    },
    {
      "id": "504",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user506@email.com",
        "title": null,
        "joined_at": "2020-08-11T01:04:26.000+02:00",
        "last_seen_at": "2020-08-11T01:04:26.288+02:00",
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 1,
        "invited_at": null,
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:26.083+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "676"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "677",
      "type": "companies",
      "attributes": {
        "name": "Client418",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:26.107+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "505",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user507@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:26.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:26.122+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "678"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "64",
      "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,
        "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,
        "currency": "USD",
        "currency_default": "USD",
        "currency_normalized": "USD",
        "revenue": 0,
        "revenue_default": 0,
        "revenue_normalized": 0,
        "cost": 12500,
        "cost_default": 12500,
        "cost_normalized": 12500,
        "profit": -12500,
        "profit_default": -12500,
        "profit_normalized": -12500,
        "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": 258
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "680"
          }
        },
        "project_manager": {
          "data": {
            "type": "people",
            "id": "506"
          }
        },
        "last_actor": {
          "data": null
        }
      }
    },
    {
      "id": "676",
      "type": "companies",
      "attributes": {
        "name": "Organization258",
        "default_currency": "USD",
        "created_at": "2020-08-11T01:04:26.081+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "678",
      "type": "companies",
      "attributes": {
        "name": "Client419",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:26.116+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "680",
      "type": "companies",
      "attributes": {
        "name": "Client421",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:26.190+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "506",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user508@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:26.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:26.162+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "679"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "679",
      "type": "companies",
      "attributes": {
        "name": "Client420",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:26.156+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 258
          }
        },
        "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": 30,
        "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
      }
    }
  }
}

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": ""
    }
  }
}
Responses422
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"
      }
    }
  ]
}

Update a expense
PATCH/api/v2/expenses/{id}

URI Parameters
HideShow
id
number (required) Example: 1

expense id


DELETE /api/v2/expenses/1
Requestsdeletes expense

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
Responses204
This response has no content.

Deletes a expense
DELETE/api/v2/expenses/{id}

URI Parameters
HideShow
id
number (required) Example: 1

expense id


PATCH /api/v2/expenses/1/approve
Requestsapproves expense

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
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "21",
    "type": "expenses",
    "attributes": {
      "name": "test name",
      "date": "2020-08-11",
      "pay_on": null,
      "paid_on": null,
      "position": 1,
      "invoiced": false,
      "approved": true,
      "approved_at": "2020-08-11T01:04:27.405+02:00",
      "rejected": false,
      "rejected_reason": null,
      "rejected_at": null,
      "deleted_at": null,
      "reimbursable": null,
      "reimbursed_on": null,
      "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": 263
        }
      },
      "deal": {
        "data": {
          "type": "deals",
          "id": "80"
        }
      },
      "service_type": {
        "data": {
          "type": "service_types",
          "id": "27"
        }
      },
      "person": {
        "data": null
      },
      "creator": {
        "data": {
          "type": "people",
          "id": "520"
        }
      },
      "approver": {
        "data": {
          "type": "people",
          "id": "520"
        }
      },
      "rejecter": {
        "data": null
      },
      "vendor": {
        "data": null
      },
      "attachment": {
        "data": null
      }
    }
  },
  "included": [
    {
      "id": "80",
      "type": "deals",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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": "9b66a92b09f968b7a56b6f2909673f3b",
        "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,
        "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": "2020-08-11T01:04:27.360+02:00",
        "note": null,
        "sales_closed_at": 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": 10000,
        "cost_default": 12500,
        "cost_normalized": 10000,
        "work_cost": 0,
        "work_cost_default": 0,
        "work_cost_normalized": 0,
        "profit": -10000,
        "profit_default": -12500,
        "profit_normalized": -10000,
        "invoiced": 0,
        "invoiced_default": 0,
        "invoiced_normalized": 0,
        "pending_invoicing": 0,
        "pending_invoicing_default": 0,
        "pending_invoicing_normalized": 0,
        "expense": 10000,
        "expense_default": 12500,
        "expense_normalized": 10000,
        "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": 10000,
        "forecasted_cost_default": 12500,
        "forecasted_cost_normalized": 10000,
        "forecasted_profit": -10000,
        "forecasted_profit_default": -12500,
        "forecasted_profit_normalized": -10000,
        "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": 263
          }
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "520"
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "703"
          }
        },
        "document_type": {
          "data": null
        },
        "responsible": {
          "data": {
            "type": "people",
            "id": "521"
          }
        },
        "deal_status": {
          "data": null
        },
        "project": {
          "data": {
            "type": "projects",
            "id": "69"
          }
        },
        "lost_reason": {
          "data": null
        },
        "contract": {
          "data": null
        },
        "contact": {
          "data": null
        }
      }
    },
    {
      "id": "27",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        }
      }
    },
    {
      "id": "520",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user522@email.com",
        "title": null,
        "joined_at": "2020-08-11T01:04:27.000+02:00",
        "last_seen_at": "2020-08-11T01:04:27.402+02:00",
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 1,
        "invited_at": null,
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:27.271+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "702"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "703",
      "type": "companies",
      "attributes": {
        "name": "Client439",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.286+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "521",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user523@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:27.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:27.296+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "704"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "69",
      "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,
        "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,
        "currency": "USD",
        "currency_default": "USD",
        "currency_normalized": "USD",
        "revenue": 0,
        "revenue_default": 0,
        "revenue_normalized": 0,
        "cost": 12500,
        "cost_default": 12500,
        "cost_normalized": 12500,
        "profit": -12500,
        "profit_default": -12500,
        "profit_normalized": -12500,
        "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": 263
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "706"
          }
        },
        "project_manager": {
          "data": {
            "type": "people",
            "id": "522"
          }
        },
        "last_actor": {
          "data": null
        }
      }
    },
    {
      "id": "702",
      "type": "companies",
      "attributes": {
        "name": "Organization263",
        "default_currency": "USD",
        "created_at": "2020-08-11T01:04:27.270+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "704",
      "type": "companies",
      "attributes": {
        "name": "Client440",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.292+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "706",
      "type": "companies",
      "attributes": {
        "name": "Client442",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.339+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "522",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user524@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:27.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:27.321+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "705"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "705",
      "type": "companies",
      "attributes": {
        "name": "Client441",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.317+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 263
          }
        },
        "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": 30,
        "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
      }
    }
  }
}

Approves an expense
PATCH/api/v2/expenses/{id}/approve

URI Parameters
HideShow
id
number (required) Example: 1

expense id


PATCH /api/v2/expenses/1/unapprove
Requestsunapproves expense

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
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "24",
    "type": "expenses",
    "attributes": {
      "name": "test name",
      "date": "2020-08-11",
      "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,
      "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": 265
        }
      },
      "deal": {
        "data": {
          "type": "deals",
          "id": "82"
        }
      },
      "service_type": {
        "data": {
          "type": "service_types",
          "id": "30"
        }
      },
      "person": {
        "data": null
      },
      "creator": {
        "data": {
          "type": "people",
          "id": "526"
        }
      },
      "approver": {
        "data": null
      },
      "rejecter": {
        "data": null
      },
      "vendor": {
        "data": null
      },
      "attachment": {
        "data": null
      }
    }
  },
  "included": [
    {
      "id": "82",
      "type": "deals",
      "attributes": {
        "name": "test name",
        "date": "2020-08-11",
        "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": "266b9a4a1682b6833bcf202ec8c82354",
        "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,
        "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": "2020-08-11T01:04:27.880+02:00",
        "note": null,
        "sales_closed_at": 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": 10000,
        "cost_default": 12500,
        "cost_normalized": 10000,
        "work_cost": 0,
        "work_cost_default": 0,
        "work_cost_normalized": 0,
        "profit": -10000,
        "profit_default": -12500,
        "profit_normalized": -10000,
        "invoiced": 0,
        "invoiced_default": 0,
        "invoiced_normalized": 0,
        "pending_invoicing": 0,
        "pending_invoicing_default": 0,
        "pending_invoicing_normalized": 0,
        "expense": 10000,
        "expense_default": 12500,
        "expense_normalized": 10000,
        "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": 10000,
        "forecasted_cost_default": 12500,
        "forecasted_cost_normalized": 10000,
        "forecasted_profit": -10000,
        "forecasted_profit_default": -12500,
        "forecasted_profit_normalized": -10000,
        "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": 265
          }
        },
        "creator": {
          "data": {
            "type": "people",
            "id": "526"
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "713"
          }
        },
        "document_type": {
          "data": null
        },
        "responsible": {
          "data": {
            "type": "people",
            "id": "527"
          }
        },
        "deal_status": {
          "data": null
        },
        "project": {
          "data": {
            "type": "projects",
            "id": "71"
          }
        },
        "lost_reason": {
          "data": null
        },
        "contract": {
          "data": null
        },
        "contact": {
          "data": null
        }
      }
    },
    {
      "id": "30",
      "type": "service_types",
      "attributes": {
        "name": "test name",
        "category_id": null,
        "deleted_at": null,
        "archived_at": null
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        }
      }
    },
    {
      "id": "526",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user528@email.com",
        "title": null,
        "joined_at": "2020-08-11T01:04:27.000+02:00",
        "last_seen_at": "2020-08-11T01:04:27.946+02:00",
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 1,
        "invited_at": null,
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:27.776+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "712"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "713",
      "type": "companies",
      "attributes": {
        "name": "Client447",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.794+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "527",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user529@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:27.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:27.807+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "714"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "71",
      "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,
        "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,
        "currency": "USD",
        "currency_default": "USD",
        "currency_normalized": "USD",
        "revenue": 0,
        "revenue_default": 0,
        "revenue_normalized": 0,
        "cost": 12500,
        "cost_default": 12500,
        "cost_normalized": 12500,
        "profit": -12500,
        "profit_default": -12500,
        "profit_normalized": -12500,
        "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": 265
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "716"
          }
        },
        "project_manager": {
          "data": {
            "type": "people",
            "id": "528"
          }
        },
        "last_actor": {
          "data": null
        }
      }
    },
    {
      "id": "712",
      "type": "companies",
      "attributes": {
        "name": "Organization265",
        "default_currency": "USD",
        "created_at": "2020-08-11T01:04:27.775+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "714",
      "type": "companies",
      "attributes": {
        "name": "Client448",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.803+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "716",
      "type": "companies",
      "attributes": {
        "name": "Client450",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.859+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "bill_to": {
          "data": null
        }
      }
    },
    {
      "id": "528",
      "type": "people",
      "attributes": {
        "first_name": "test first name",
        "last_name": "test last name",
        "email": "user530@email.com",
        "title": null,
        "joined_at": null,
        "last_seen_at": null,
        "deactivated_at": null,
        "archived_at": null,
        "role_id": 3,
        "invited_at": "2020-08-11T01:04:27.000+02:00",
        "is_user": true,
        "tag_list": [],
        "avatar_url": null,
        "virtual": false,
        "custom_fields": null,
        "autotracking": false,
        "created_at": "2020-08-11T01:04:27.839+02:00",
        "placeholder": false,
        "color_id": null,
        "private_custom_reports_used": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "company": {
          "data": {
            "type": "companies",
            "id": "715"
          }
        },
        "subsidiary": {
          "data": null
        }
      }
    },
    {
      "id": "715",
      "type": "companies",
      "attributes": {
        "name": "Client449",
        "default_currency": null,
        "created_at": "2020-08-11T01:04:27.835+02:00",
        "archived_at": null,
        "avatar_url": null,
        "invoice_email_recipients": {},
        "custom_fields": null,
        "description": null,
        "due_days": null,
        "tag_list": []
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": 265
          }
        },
        "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": 30,
        "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
      }
    }
  }
}

Unapproves an expense
PATCH/api/v2/expenses/{id}/unapprove

URI Parameters
HideShow
id
number (required) Example: 1

expense id


Generated by aglio on 10 Aug 2020