Expenses
Retrieve expenses for a company
limit of records per page
10
page number
2
ID of the supplier associated with the expense
996501df-0bfc-4f95-954d-3a5d5dc48469
date of the transaction you want to filter frome
2022-03-23
date of the transaction you wish to filter to
2023-03-23
This field is used to filter by vendor memo. (LIKE)
test
This parameter is used to sort the records by a specific field (created_at,transacted_at,recorded_at)
created_at
Order type(asc or desc)
asc
Successful operation
Bad Request
Unauthenticated
Not Found
Internal Server
GET /api/expenses HTTP/1.1
Host: app.greenplaces.com
Accept: */*
{
"status": "Ok",
"message": "Success",
"data": [
{
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"vendor": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"name": "test name",
"description": "description...",
"website": "https://www.example.com/",
"notes": "notes...",
"services_provided": "example",
"products_purchased": "example",
"account_manager_name": "name manager",
"account_manager_email": "[email protected]",
"currency": "USD",
"score": "2",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"memo": "This is a memo",
"amount": "100.00",
"currency": "USD",
"ceda_six_industry_id": "1111B0",
"transacted_at": "2023-06-12",
"recorded_at": "2023-06-12",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
}
],
"meta": {
"pagination": {
"current": "1",
"last_page": "1",
"per_page": "10",
"total": "6"
}
}
}
Create an expense for a company
Creates airtravel segment request body data
Vendor ID for the Expense
996501df-0bfc-4f95-954d-3a5d5dc48469
Memo for the Expense
This is a memo
Amount for the Expense
100.00
Currency for the Expense
USD
CEDA six industry Code or UUID for the Expense
1111B0
Transacted At for the Expense
1999-01-01
Recorded At for the Expense
1999-01-01
Successful operation
Bad Request
Unauthenticated
Not Found
Internal Server
POST /api/expenses HTTP/1.1
Host: app.greenplaces.com
Content-Type: application/json
Accept: */*
Content-Length: 196
{
"vendor_id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"memo": "This is a memo",
"amount": "100.00",
"currency": "USD",
"ceda_six_industry": "1111B0",
"transacted_at": "1999-01-01",
"recorded_at": "1999-01-01"
}
{
"status": "Ok",
"message": "Success",
"data": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"vendor": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"name": "test name",
"description": "description...",
"website": "https://www.example.com/",
"notes": "notes...",
"services_provided": "example",
"products_purchased": "example",
"account_manager_name": "name manager",
"account_manager_email": "[email protected]",
"currency": "USD",
"score": "2",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"memo": "This is a memo",
"amount": "100.00",
"currency": "USD",
"ceda_six_industry_id": "1111B0",
"transacted_at": "2023-06-12",
"recorded_at": "2023-06-12",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"meta": {}
}
obtain information about a an expense
ID of the the Expense
996501df-0bfc-4f95-954d-3a5d5dc48469
Successful operation
Bad Request
Unauthenticated
Not Found
Internal Server
GET /api/expenses/{id} HTTP/1.1
Host: app.greenplaces.com
Accept: */*
{
"status": "Ok",
"message": "Success",
"data": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"vendor": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"name": "test name",
"description": "description...",
"website": "https://www.example.com/",
"notes": "notes...",
"services_provided": "example",
"products_purchased": "example",
"account_manager_name": "name manager",
"account_manager_email": "[email protected]",
"currency": "USD",
"score": "2",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"memo": "This is a memo",
"amount": "100.00",
"currency": "USD",
"ceda_six_industry_id": "1111B0",
"transacted_at": "2023-06-12",
"recorded_at": "2023-06-12",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"meta": {}
}
Update of an expense
ID of the the Expense
996501df-0bfc-4f95-954d-3a5d5dc48469
Update airtravel segment request body data
Vendor ID for the Expense
996501df-0bfc-4f95-954d-3a5d5dc48469
Memo for the Expense
This is a memo
Amount for the Expense
100.00
Currency for the Expense
USD
CEDA six industry ID for the Expense
1111B0
Transacted At for the Expense
1999-01-01
Recorded At for the Expense
1999-01-01
Successful operation
Bad Request
Unauthenticated
Not Found
Internal Server
PUT /api/expenses/{id} HTTP/1.1
Host: app.greenplaces.com
Content-Type: application/json
Accept: */*
Content-Length: 196
{
"vendor_id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"memo": "This is a memo",
"amount": "100.00",
"currency": "USD",
"ceda_six_industry": "1111B0",
"transacted_at": "1999-01-01",
"recorded_at": "1999-01-01"
}
{
"status": "Ok",
"message": "Success",
"data": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"vendor": {
"id": "996501df-0bfc-4f95-954d-3a5d5dc48469",
"name": "test name",
"description": "description...",
"website": "https://www.example.com/",
"notes": "notes...",
"services_provided": "example",
"products_purchased": "example",
"account_manager_name": "name manager",
"account_manager_email": "[email protected]",
"currency": "USD",
"score": "2",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"memo": "This is a memo",
"amount": "100.00",
"currency": "USD",
"ceda_six_industry_id": "1111B0",
"transacted_at": "2023-06-12",
"recorded_at": "2023-06-12",
"updated_at": "2023-06-12T17:30:21.000000Z",
"created_at": "2023-06-12T17:30:21.000000Z"
},
"meta": {}
}
remove an expense
ID of the the Expense
996501df-0bfc-4f95-954d-3a5d5dc48469
Successful operation
Bad Request
Unauthenticated
Not Found
Internal Server
DELETE /api/expenses/{id} HTTP/1.1
Host: app.greenplaces.com
Accept: */*
{
"status": "Ok",
"message": "Success",
"data": null,
"meta": {}
}