Accounting (only available for accounting add-on users)
Create expense by listing
Changed onCreate a PMC expense for the provided listing (PMC pays the vendor). By default, 100% of the expense is applied to the PMC. If you provide expenseShare, the expense is split between PMC and Owner: when ownerId is provided, the owner share is charged to that specific owner; when ownerId is omitted, the owner share is distributed across all owners of the listing.
post/business-models-api/transactions/expenses-by-listing
Request
- Base URLhttps://open-api.guesty.com/v1
- URLhttps://open-api.guesty.com/v1/business-models-api/transactions/expenses-by-listing
- AuthAPI key in header authorization
Request body
Example request
{
"name": "Maintenance expense",
"categoryId": "123e4567-e89b-12d3-a456-426614174000",
"description": "Bulb replacement",
"amount": 5,
"recognitionDate": "2023-10-27",
"vendorId": "5f4f6e1c1c6e4e001f7e8b4e",
"referenceId": "REF-12345",
"expenseShare": {
"shareSplit": 0.5,
"ownerId": "67166b173907ef3b9bf25fb3",
"listingId": "507f191e810c19729de860ea"
},
"attachments": [
{
"url": "https://cdn.filepicker.io/api/file/bBnKEk8TlmJAUHcLApRx",
"urlThumbnail": "https://cdn.filepicker.io/api/file/bBnKEk8TlmJAUHcLApRx",
"extension": "png",
"fileName": "Invoice copy"
}
]
}Response
Expense created
Changes
- info
added the non-success response with the status
- info