URL
Response: HTTP 200, application/json (Hide)
POST /projects/1/expenses
Payload:
1 2 3 4 5 6
{
"value": 250,
"user_id": 1,
"category_id": 1,
"record_date": "2014-05-14"
}Response:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
{
"single": {
"id": 1,
"class": "Expense",
"url_path": "\/projects\/1\/expenses\/1",
"is_trashed": false,
"trashed_on": null,
"trashed_by_id": 0,
"billable_status": 1,
"value": 250,
"record_date": 1400025600,
"summary": null,
"user_id": 1,
"parent_type": "Project",
"parent_id": 1,
"created_on": 1430164106,
"created_by_id": 1,
"updated_on": 1430164106,
"updated_by_id": 1,
"category_id": 1,
"currency_id": 2
}
}Response: HTTP 200, application/json (Hide)
GET /projects/1/expenses/1
Response:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
{
"single": {
"id": 1,
"class": "Expense",
"url_path": "\/projects\/1\/expenses\/1",
"is_trashed": false,
"trashed_on": null,
"trashed_by_id": 0,
"billable_status": 1,
"value": 250,
"record_date": 1400025600,
"summary": null,
"user_id": 1,
"parent_type": "Project",
"parent_id": 1,
"created_on": 1430164106,
"created_by_id": 1,
"updated_on": 1430164106,
"updated_by_id": 1,
"category_id": 1,
"currency_id": 2
}
}Response: HTTP 404, text/html
GET /projects/2/expenses/1