HomeGuides
Submit Documentation FeedbackJoin Developer CommunityLog In

Budget calendar

This topic describes the Budget calendar API handler.

HTTP Verb: GET

URL: /api/v1/budgetcalendars

Description: Returns a collection of budget calendar for the current customer

Base: HandlerBase<GetBudgetCalendarCollectionParameter, GetBudgetCalendarCollectionResult>

Handlers:

OrderHandlerDescription
500ValidateContextChecks, if BillTo in site context is not null, otherwise returns error
600GetBudgetCalendarCollectionRetrieves all BudgetCalendar`s for BillTo with filtering by FiscalYear parameter or all, if FiscalYear property is not set. Put those calendars into GetBudgetCalendarResults.
If FiscalYear property has value and GetBudgetCalendarResults collection is empty, then create new GetBudgetCalendarResult for FiscalYear property and BillTo.

HTTP Verb: PATCH

URL: /api/v1/budgetcalendars/{fiscalYear}

Description: Updates a single budget calendar by fiscal year and current customer

Base: HandlerBase<UpdateBudgetCalendarParameter, UpdateBudgetCalendarResult>

Handlers:

OrderHandlerDescription
500UpdateBudgetCalendarChecks, if BillTo in site context is not null, otherwise returns error. Tries to load BudgetCalendar for current BillTo and FiscalYear from parameter, if not existsΒ  - creates new one and inserts into database. Sets BudgetPeriods and FiscalYearEndDate from parameters.

HTTP Verb: GET

URL: /api/v1/budgetcalendars/{fiscalYear}

Description: Returns a single budget calendar by fiscal year and current customer

Base: HandlerBase<GetBudgetCalendarParameter, GetBudgetCalendarResult>

Handlers:

OrderHandlerDescription
500GetBudgetCalendarCalls GetBudgetCalendarCollection for FiscalYear parameter. If GetBudgetCalendarResults count is not equals to 1, then returns not found, otherwise gets first item.

Did this page help you?