Approvals
GET Get timesheet setups
https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups
Get timesheet setups for a given workspace.
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
curl https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups \
-H "Content-Type: application/json" \
-u <email>:<password>
req, err := http.NewRequest(http.MethodGet,
"https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups")
if err != nil {
print(err)
}
req.Header.Set("Content-Type", "application/json; charset=utf-8")
req.SetBasicAuth("<email>", "<password>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
print(err)
}
defer resp.Body.Close()
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
print(err)
}
fmt.Print(string(body))
require 'net/http'
require 'uri'
require 'json'
uri = URI('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups')
http = Net::HTTP.new(uri.host, uri.port)
req = Net::HTTP::Get.new(uri.path)
req['Content-Type'] = "application/json"
request.basic_auth '<email>', '<password>'
res = http.request(req)
puts JSON.parse(res.body)
fetch("https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups", {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": `Basic ${base64.encode(<email>:<password>)}`
},
})
.then((resp) => resp.json())
.then((json) => {
console.log(json);
})
.catch(err => console.error(err));
import requests
from base64 import b64encode
data = requests.get('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups', headers={'content-type': 'application/json', 'Authorization' : 'Basic %s' % b64encode(b"<email>:<password>").decode("ascii")})
print(data.json())
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/workspaces/{workspace_id}/timesheet_setups".to_string())
.header(CONTENT_TYPE, "application/json")
.send()
.await?
.json()
.await?;
println!("{:#?}", json);
Ok(())
}
Parameters
Path
name | type | required | description |
---|---|---|---|
workspace_id | integer | true | Numeric ID of the workspace |
Query
name | type | required | description |
---|---|---|---|
member_ids | integer | false | Numeric ID of the members, comma-separated |
approver_ids | integer | false | Numeric ID of the approvers, comma-separated |
sort_field | string | false | Field used for sorting, default start_date. |
sort_order | string | false | Sort order. |
Response
200
Name | Type | Description |
---|---|---|
data | Array of object | - |
data
Name | Type | Description |
---|---|---|
approver_id | integer | - |
approver_name | string | - |
approvers | Array of object | - |
end_date | string | - |
errors | Array of object | - |
id | integer | - |
member_id | integer | - |
member_name | string | - |
periodicity | string | - |
permissions | string | - |
reminder_day | string | - |
reminder_time | string | - |
start_date | string | - |
workspace_id | integer | - |
approvers
Name | Type | Description |
---|---|---|
name | string | - |
user_id | integer | - |
errors
Name | Type | Description |
---|---|---|
code | string | - |
message | string | - |
400
Possible error messages:
- Workspace not found
- Invalid user ID
- User not in workspace
402
Approvals are a premium feature
403
User does not have access to this resource
500
Internal Server Error
POST Create a timesheet setup
https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups
Create timesheet setups.
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
curl -X POST https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups \
-H "Content-Type: application/json" \
-d '\{"approver_id":"integer","approver_ids":[\{\}],"member_ids":[\{\}],"periodicity":"string","reminder_day":"string","reminder_time":"string","start_date":"string"\}' \
-u <email>:<password>
bytes, err := json.Marshal('\{"approver_id":"integer","approver_ids":[\{\}],"member_ids":[\{\}],"periodicity":"string","reminder_day":"string","reminder_time":"string","start_date":"string"\}')
if err != nil {
print(err)
}
req, err := http.NewRequest(http.MethodPost,
"https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups", bytes.NewBuffer(bytes))
if err != nil {
print(err)
}
req.Header.Set("Content-Type", "application/json; charset=utf-8")
req.SetBasicAuth("<email>", "<password>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
print(err)
}
defer resp.Body.Close()
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
print(err)
}
fmt.Print(string(body))
require 'net/http'
require 'uri'
require 'json'
uri = URI('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups')
http = Net::HTTP.new(uri.host, uri.port)
req = Net::HTTP::Post.new(uri.path)
req['Content-Type'] = "application/json"
req.body = \{"approver_id":"integer","approver_ids":[\{\}],"member_ids":[\{\}],"periodicity":"string","reminder_day":"string","reminder_time":"string","start_date":"string"\}.to_json
request.basic_auth '<email>', '<password>'
res = http.request(req)
puts JSON.parse(res.body)
fetch("https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups", {
method: "POST",
body: \{"approver_id":"integer","approver_ids":[\{\}],"member_ids":[\{\}],"periodicity":"string","reminder_day":"string","reminder_time":"string","start_date":"string"\},
headers: {
"Content-Type": "application/json",
"Authorization": `Basic ${base64.encode(<email>:<password>)}`
},
})
.then((resp) => resp.json())
.then((json) => {
console.log(json);
})
.catch(err => console.error(err));
import requests
from base64 import b64encode
data = requests.post('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups', json=\{"approver_id":"integer","approver_ids":[\{\}],"member_ids":[\{\}],"periodicity":"string","reminder_day":"string","reminder_time":"string","start_date":"string"\}, headers={'content-type': 'application/json', 'Authorization' : 'Basic %s' % b64encode(b"<email>:<password>").decode("ascii")})
print(data.json())
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::POST, "https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups".to_string())
.json(&serde_json::json!(\{"approver_id":"integer","approver_ids":[\{\}],"member_ids":[\{\}],"periodicity":"string","reminder_day":"string","reminder_time":"string","start_date":"string"\}))
.header(CONTENT_TYPE, "application/json")
.send()
.await?
.json()
.await?;
println!("{:#?}", json);
Ok(())
}
Parameters
Path
name | type | required | description |
---|---|---|---|
workspace_id | integer | true | Numeric ID of the workspace |
Body
Name | Type | Description |
---|---|---|
approver_id | integer | - |
approver_ids | Array of integer | - |
member_ids | Array of integer | - |
periodicity | string | - |
reminder_day | string | - |
reminder_time | string | - |
start_date | string | - |
Response
200
Name | Type | Description |
---|---|---|
items | Array of object | - |
items
Name | Type | Description |
---|---|---|
approver_id | integer | - |
approver_name | string | - |
approvers | Array of object | - |
end_date | string | - |
errors | Array of object | - |
id | integer | - |
member_id | integer | - |
member_name | string | - |
periodicity | string | - |
permissions | string | - |
reminder_day | string | - |
reminder_time | string | - |
start_date | string | - |
workspace_id | integer | - |
approvers
Name | Type | Description |
---|---|---|
name | string | - |
user_id | integer | - |
errors
Name | Type | Description |
---|---|---|
code | string | - |
message | string | - |
400
Possible error messages:
- Workspace not found
- Invalid user ID
- Too many user IDs
- Invalid date
- Invalid periodicity
- User not in workspace
- User is not an admin in the workspace
- Approver cannot be member
- Member already has a timesheet setup
402
Approvals are a premium feature
403
User does not have access to this resource
500
Internal Server Error
POST Update a timesheet setup
https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}
Updates a timesheet setups.
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
curl -X POST https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id} \
-H "Content-Type: application/json" \
-d '\{"approver_id":"integer","approver_ids":[\{\}],"end_date":"string","reminder_day":"string","reminder_time":"string"\}' \
-u <email>:<password>
bytes, err := json.Marshal('\{"approver_id":"integer","approver_ids":[\{\}],"end_date":"string","reminder_day":"string","reminder_time":"string"\}')
if err != nil {
print(err)
}
req, err := http.NewRequest(http.MethodPost,
"https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}", bytes.NewBuffer(bytes))
if err != nil {
print(err)
}
req.Header.Set("Content-Type", "application/json; charset=utf-8")
req.SetBasicAuth("<email>", "<password>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
print(err)
}
defer resp.Body.Close()
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
print(err)
}
fmt.Print(string(body))
require 'net/http'
require 'uri'
require 'json'
uri = URI('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}')
http = Net::HTTP.new(uri.host, uri.port)
req = Net::HTTP::Post.new(uri.path)
req['Content-Type'] = "application/json"
req.body = \{"approver_id":"integer","approver_ids":[\{\}],"end_date":"string","reminder_day":"string","reminder_time":"string"\}.to_json
request.basic_auth '<email>', '<password>'
res = http.request(req)
puts JSON.parse(res.body)
fetch("https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}", {
method: "POST",
body: \{"approver_id":"integer","approver_ids":[\{\}],"end_date":"string","reminder_day":"string","reminder_time":"string"\},
headers: {
"Content-Type": "application/json",
"Authorization": `Basic ${base64.encode(<email>:<password>)}`
},
})
.then((resp) => resp.json())
.then((json) => {
console.log(json);
})
.catch(err => console.error(err));
import requests
from base64 import b64encode
data = requests.post('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}', json=\{"approver_id":"integer","approver_ids":[\{\}],"end_date":"string","reminder_day":"string","reminder_time":"string"\}, headers={'content-type': 'application/json', 'Authorization' : 'Basic %s' % b64encode(b"<email>:<password>").decode("ascii")})
print(data.json())
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::POST, "https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}".to_string())
.json(&serde_json::json!(\{"approver_id":"integer","approver_ids":[\{\}],"end_date":"string","reminder_day":"string","reminder_time":"string"\}))
.header(CONTENT_TYPE, "application/json")
.send()
.await?
.json()
.await?;
println!("{:#?}", json);
Ok(())
}
Parameters
Path
name | type | required | description |
---|---|---|---|
workspace_id | integer | true | Numeric ID of the workspace |
setup_id | integer | true | Numeric ID of the timesheet setup |
Body
Name | Type | Description |
---|---|---|
approver_id | integer | - |
approver_ids | Array of integer | - |
end_date | string | - |
reminder_day | string | - |
reminder_time | string | - |
Response
200
Name | Type | Description |
---|---|---|
approver_id | integer | - |
approver_name | string | - |
approvers | Array of object | - |
end_date | string | - |
errors | Array of object | - |
id | integer | - |
member_id | integer | - |
member_name | string | - |
periodicity | string | - |
permissions | string | - |
reminder_day | string | - |
reminder_time | string | - |
start_date | string | - |
workspace_id | integer | - |
approvers
Name | Type | Description |
---|---|---|
name | string | - |
user_id | integer | - |
errors
Name | Type | Description |
---|---|---|
code | string | - |
message | string | - |
400
Possible error messages:
- Workspace not found
- Invalid user ID
- Invalid date
- User is not an admin in the workspace
- End date must respect periodicity
- Member already has a timesheet setup
402
Approvals are a premium feature
403
User does not have access to this resource
404
Timesheet setup was not found
500
Internal Server Error
DELETE Delete a timesheet setup
https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}
Delete a timesheet setup for a given workspace.
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
curl -X DELETE https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id} \
-H "Content-Type: application/json" \
-u <email>:<password>
req, err := http.NewRequest(http.MethodPut,
"https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}")
if err != nil {
print(err)
}
req.Header.Set("Content-Type", "application/json; charset=utf-8")
req.SetBasicAuth("<email>", "<password>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
print(err)
}
defer resp.Body.Close()
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
print(err)
}
fmt.Print(string(body))
require 'net/http'
require 'uri'
require 'json'
uri = URI('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}')
http = Net::HTTP.new(uri.host, uri.port)
req = Net::HTTP::Delete.new(uri.path)
req['Content-Type'] = "application/json"
request.basic_auth '<email>', '<password>'
res = http.request(req)
puts JSON.parse(res.body)
fetch("https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}", {
method: "DELETE",
headers: {
"Content-Type": "application/json",
"Authorization": `Basic ${base64.encode(<email>:<password>)}`
},
})
.then((resp) => resp.json())
.then((json) => {
console.log(json);
})
.catch(err => console.error(err));
import requests
from base64 import b64encode
data = requests.delete('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}', headers={'content-type': 'application/json', 'Authorization' : 'Basic %s' % b64encode(b"<email>:<password>").decode("ascii")})
print(data.json())
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::DELETE, "https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheet_setups/{setup_id}".to_string())
.header(CONTENT_TYPE, "application/json")
.send()
.await?
.json()
.await?;
println!("{:#?}", json);
Ok(())
}
Parameters
Path
name | type | required | description |
---|---|---|---|
workspace_id | integer | true | Numeric ID of the workspace |
setup_id | integer | false | Numeric ID of the timesheet setup |
Response
200
Successful operation.
400
Possible error messages:
- Workspace not found
- Invalid setup ID
- Failed to delete timesheet setup, member has approved, rejected or submitted timesheets
402
Approvals are a premium feature
403
User does not have access to this resource
500
Internal Server Error
GET Get timesheets
https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets
Get timesheets applying various filters.
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
curl https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets \
-H "Content-Type: application/json" \
-u <email>:<password>
req, err := http.NewRequest(http.MethodGet,
"https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets")
if err != nil {
print(err)
}
req.Header.Set("Content-Type", "application/json; charset=utf-8")
req.SetBasicAuth("<email>", "<password>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
print(err)
}
defer resp.Body.Close()
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
print(err)
}
fmt.Print(string(body))
require 'net/http'
require 'uri'
require 'json'
uri = URI('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets')
http = Net::HTTP.new(uri.host, uri.port)
req = Net::HTTP::Get.new(uri.path)
req['Content-Type'] = "application/json"
request.basic_auth '<email>', '<password>'
res = http.request(req)
puts JSON.parse(res.body)
fetch("https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets", {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": `Basic ${base64.encode(<email>:<password>)}`
},
})
.then((resp) => resp.json())
.then((json) => {
console.log(json);
})
.catch(err => console.error(err));
import requests
from base64 import b64encode
data = requests.get('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets', headers={'content-type': 'application/json', 'Authorization' : 'Basic %s' % b64encode(b"<email>:<password>").decode("ascii")})
print(data.json())
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/workspaces/{workspace_id}/timesheets".to_string())
.header(CONTENT_TYPE, "application/json")
.send()
.await?
.json()
.await?;
println!("{:#?}", json);
Ok(())
}
Parameters
Path
name | type | required | description |
---|---|---|---|
workspace_id | integer | true | Numeric ID of the workspace |
Query
name | type | required | description |
---|---|---|---|
member_ids | integer | false | Numeric ID of the members, comma-separated |
approver_ids | integer | false | Numeric ID of the approvers, comma-separated |
timesheet_setup_ids | integer | false | Numeric ID for timesheet setup, comma-separated. |
statuses | integer | false | Timesheet status, comma-separated. |
before | integer | false | Timesheets starting before this date (YYYY-MM-DD). |
after | integer | false | Timesheets starting after this date (YYYY-MM-DD). |
page | integer | false | Page number, default 1. |
per_page | integer | false | Number of items per page, default 20. Also defaults to 20 if provided an greater than 1000. |
sort_field | string | false | Field used for sorting, default start_date. |
sort_order | string | false | Sort order. |
Response
200
Name | Type | Description |
---|---|---|
items | Array of object | - |
items
Name | Type | Description |
---|---|---|
data | Array of object | - |
page | integer | - |
per_page | integer | - |
total_count | integer | - |
data
Name | Type | Description |
---|---|---|
approved_or_rejected_at | string | - |
approved_or_rejected_id | integer | - |
approved_or_rejected_name | string | - |
approver_id | integer | - |
approver_name | string | - |
approvers | Array of object | - |
end_date | string | - |
errors | Array of object | - |
member_id | integer | - |
member_name | string | - |
period_editable | boolean | - |
period_end | string | - |
period_locked | boolean | - |
period_start | string | - |
periodicity | string | - |
permissions | string | - |
rejection_comment | string | - |
reminder_day | string | - |
reminder_sent_at | string | - |
reminder_time | string | - |
start_date | string | - |
status | string | - |
submitted_at | string | - |
timesheet_setup_id | integer | - |
working_hours_in_minutes | integer | - |
workspace_id | integer | - |
approvers
Name | Type | Description |
---|---|---|
name | string | - |
user_id | integer | - |
errors
Name | Type | Description |
---|---|---|
code | string | - |
message | string | - |
400
Possible error messages:
- Workspace not found
- Invalid ID
- Invalid date
- Invalid status
402
Approvals are a premium feature
403
User does not have access to this resource
500
Internal Server Error
PUT Update timesheets
https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date}
Updates a timesheet.
- cURL
- Go
- Ruby
- JavaScript
- Python
- Rust
curl -X PUT https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date} \
-H "Content-Type: application/json" \
-d '\{"rejection_comment":"string","status":"string"\}' \
-u <email>:<password>
bytes, err := json.Marshal('\{"rejection_comment":"string","status":"string"\}')
if err != nil {
print(err)
}
req, err := http.NewRequest(http.MethodPut,
"https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date}", bytes.NewBuffer(bytes))
if err != nil {
print(err)
}
req.Header.Set("Content-Type", "application/json; charset=utf-8")
req.SetBasicAuth("<email>", "<password>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
print(err)
}
defer resp.Body.Close()
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
print(err)
}
fmt.Print(string(body))
require 'net/http'
require 'uri'
require 'json'
uri = URI('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date}')
http = Net::HTTP.new(uri.host, uri.port)
req = Net::HTTP::Put.new(uri.path)
req['Content-Type'] = "application/json"
req.body = \{"rejection_comment":"string","status":"string"\}.to_json
request.basic_auth '<email>', '<password>'
res = http.request(req)
puts JSON.parse(res.body)
fetch("https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date}", {
method: "PUT",
body: \{"rejection_comment":"string","status":"string"\},
headers: {
"Content-Type": "application/json",
"Authorization": `Basic ${base64.encode(<email>:<password>)}`
},
})
.then((resp) => resp.json())
.then((json) => {
console.log(json);
})
.catch(err => console.error(err));
import requests
from base64 import b64encode
data = requests.put('https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date}', json=\{"rejection_comment":"string","status":"string"\}, headers={'content-type': 'application/json', 'Authorization' : 'Basic %s' % b64encode(b"<email>:<password>").decode("ascii")})
print(data.json())
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::PUT, "https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/timesheets/{setup_id}/{start_date}".to_string())
.json(&serde_json::json!(\{"rejection_comment":"string","status":"string"\}))
.header(CONTENT_TYPE, "application/json")
.send()
.await?
.json()
.await?;
println!("{:#?}", json);
Ok(())
}
Parameters
Path
name | type | required | description |
---|---|---|---|
workspace_id | integer | true | Numeric ID of the workspace |
setup_id | integer | true | Numeric ID of the timesheet setup. |
start_date | string | true | Start date (YYYY-MM-DD) of the timesheet. |
Body
Name | Type | Description |
---|---|---|
rejection_comment | string | - |
status | string | - |
Response
200
Name | Type | Description |
---|---|---|
approved_or_rejected_at | string | - |
approved_or_rejected_id | integer | - |
approved_or_rejected_name | string | - |
approver_id | integer | - |
approver_name | string | - |
approvers | Array of object | - |
end_date | string | - |
errors | Array of object | - |
member_id | integer | - |
member_name | string | - |
period_editable | boolean | - |
period_end | string | - |
period_locked | boolean | - |
period_start | string | - |
periodicity | string | - |
permissions | string | - |
rejection_comment | string | - |
reminder_day | string | - |
reminder_sent_at | string | - |
reminder_time | string | - |
start_date | string | - |
status | string | - |
submitted_at | string | - |
timesheet_setup_id | integer | - |
working_hours_in_minutes | integer | - |
workspace_id | integer | - |
approvers
Name | Type | Description |
---|---|---|
name | string | - |
user_id | integer | - |
errors
Name | Type | Description |
---|---|---|
code | string | - |
message | string | - |
400
Possible error messages:
- Workspace not found
- Invalid ID
- Invalid date
- Invalid status
- Invalid status for rejection comment
- Invalid timesheet transition
402
Approvals are a premium feature
403
User does not have access to this resource
500
Internal Server Error