Skip to content

List plans

GET
/plans/
curl --request GET \
--url https://app.commitly.com/api/plans/ \
--header 'Authorization: Bearer <token>'

Returns the plans of the company as a plain JSON array. Not paginated.

The id is used as plan_id for plan budgets and as scenario_id for scenario budgets. type distinguishes regular plans, the forecast and scenarios.

List of plans.

Media typeapplication/json
Array<object>
object
id
integer
author
object
id
string
username
string
full_name
string
date_created
string format: date-time
date_updated
string format: date-time
name
string
first_year
integer
last_year
integer
type

REGULAR plan, the FORECAST, or a SCENARIO.

string
Allowed values: REGULAR FORECAST SCENARIO
is_active
boolean
is_committed

Budgets of a committed plan cannot be updated or deleted.

boolean
update_status

IN_PROGRESS while the plan is being recalculated, otherwise READY.

string
Allowed values: IN_PROGRESS READY
use_transactions
boolean
use_invoices
boolean
update_forecast
boolean
parent

ID of the parent plan.

integer | null
comment_count
integer
Example
[
{
"id": 2001,
"author": {
"id": "19",
"username": "jane.doe@example.com",
"full_name": "Jane Doe"
},
"date_created": "2020-12-03T12:40:16.187671Z",
"date_updated": "2021-09-03T18:32:19.682824Z",
"name": "Forecast",
"first_year": 2020,
"last_year": 2023,
"type": "FORECAST",
"is_active": true,
"is_committed": false,
"update_status": "READY",
"use_transactions": true,
"use_invoices": false,
"update_forecast": true,
"parent": null,
"comment_count": 0
}
]

The access token is invalid or has expired. Request a new token. The message is localized (see Accept-Language).

Media typeapplication/json
object
detail
required

Error message.

string
code

Present only if the company’s edition does not include the function; value billing_plan_permission_denied.

string
Example
{
"detail": "Invalid token."
}
WWW-Authenticate
string

Authentication scheme, Bearer.

Example
Bearer

No access token was sent, or the credentials are not allowed to call this endpoint. If the company’s COMMITLY edition does not include the requested function, the body additionally contains "code": "billing_plan_permission_denied".

Media typeapplication/json
object
detail
required

Error message.

string
code

Present only if the company’s edition does not include the function; value billing_plan_permission_denied.

string
Example
{
"detail": "User must be authenticated to access this resource."
}