Post
/api/v1/finance/budgets
Create a new budget.
Description
This endpoint inserts (add) a budget. The 200 response contains a field named 'reference'. It is important to save this value since it is used as an identifier for all the other operations to recognise this specific entity
Use Case
The user wants to add a budget from outside the Bloxs application.
Request fields
The request contains the following fields:
| Field | Description |
|---|---|
| externalIdentifier | The unique identifier for this specific budget, not created by Bloxs. |
| budgetType | Refers to the budget type: 1 = Operating Budget, 2 = Investment Budget. |
| ownerReference | The reference of the relation that owns the budget. This refers to the reference created by Bloxs, not to be confused with the externalIdentifier. |
| name | the name the user wants to assign to this budget. |
| calendarYear | The calendar year to which the budget applies. |
| ledgerAccountCode | The code of the ledger account. |
| realEstateObjectReference | This is the reference of the realestate object associated with the budget. This refers to the reference created by Bloxs, not to be confused with the externalIdentifier. |
| month | Indicates the month to which the budget applies. 1 = January, 2 = February, and so on. The 'Month' field is not required for Investment Budgets and only applies to Operating Budgets. |
| amount | The budgeted amount |
Response fields
In addition to the request, the 200 response contains the fields in the table below.
| Field | Description |
|---|---|
| reference | The unique identifier for this specific budget, created by Bloxs. |
| lastModified | Timestamp of the last modification within Bloxs (determined by Bloxs). |
Security
HTTP
Type Bearer
Please enter a valid token
Body parameters
object
externalIdentifier
string | null
Min length0
Max length100
budgetType
integer (int32) Required
Valid values[
1,
2
]
ownerReference
string Required
Min length0
Max length100
name
string Required
Min length0
Max length256
calendarYear
integer (int32) Required
lines
Array of object (BudgetLine) Required
object
ledgerAccountCode
string Required
Min length0
Max length12
realEstateObjectReference
string | null
Min length0
Max length100
month
integer (int32) Required
Minimum0
Maximum12
amount
number (double) Required
Responses
200
The budget was created
object
reference
string | null
Min length0
Max length100
externalIdentifier
string | null
Min length0
Max length100
budgetType
integer (int32)
Valid values[
1,
2
]
calendarYear
integer (int32)
ownerReference
string
Min length0
Max length100
lastModified
string (date-time)
lines
Array of object (BudgetLine) | null
object
ledgerAccountCode
string
Min length0
Max length12
realEstateObjectReference
string | null
Min length0
Max length100
month
integer (int32)
Minimum0
Maximum12
amount
number (double)
400
The budget data has validation issues
object
type
string | null
title
string | null
traceId
string | null
status
integer (int32)
errors
object | null
property*
Array of string | null additionalProperties
string