Veljko
1
https://api.track.toggl.com/api/v9/organizations/{organization_id}
Returns organization name and current pricing plan
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
extern crate tokio;extern crate serde_json;use reqwest::{Client};use reqwest::header::{CONTENT_TYPE};#[tokio::main]async fn main() -> Result<(), reqwest::Error> { let client = Client::new().basic_auth("<email>", "<password>"); let json = client.request(Method::GET, "https://api.track.toggl.com/api/v9/organizations/{organization_id}".to_string()) .header(CONTENT_TYPE, "application/json") .send() .await? .json() .await?; println!("{:#?}", json); Ok(())}
Parameters
Path
name |
type |
required |
description |
organization_id |
integer |
true |
Numeric ID of the organization |
Response
200
Name |
Type |
Description |
admin |
boolean |
Whether the requester is an admin of the organization |
at |
string |
Organization’s last modification date |
created_at |
string |
Organization’s creation date |
id |
integer |
Organization ID |
is_multi_workspace_enabled |
boolean |
Is true when the organization option is_multi_workspace_enabled is set |
is_unified |
boolean |
- |
max_data_retention_days |
integer |
How far back free workspaces in this org can access data. |
max_workspaces |
integer |
Maximum number of workspaces allowed for the organization |
name |
string |
Organization Name |
owner |
boolean |
Whether the requester is a the owner of the organization |
permissions |
string |
- |
pricing_plan_enterprise |
boolean |
The subscription plan is an enterprise plan |
pricing_plan_id |
integer |
Organization plan ID |
pricing_plan_name |
string |
The subscription plan name the org is currently on. Free or any plan name coming from payment provider |
suspended_at |
string |
Whether the organization is currently suspended |
trial_info |
object |
- |
user_count |
integer |
Number of organization users |
trial_info
Name |
Type |
Description |
can_have_trial |
boolean |
CanHaveInitialTrial is true if neither the organization nor the owner has never had a trial before |
last_pricing_plan_id |
integer |
null |
next_payment_date |
string |
null |
trial |
boolean |
Whether the organization’s subscription is currently on trial |
trial_available |
boolean |
When a trial is available for this organization |
trial_end_date |
string |
null |
404
Possible error messages:
- Invalid organization ID
- User not part of the organization