Add projects to or remove them from the Resource Planner
Makes the listed projects available in the Resource Planner, or takes them out, and tells the Resource Planner service.
Projects already in the requested state are skipped (no write, no event). Answers 200 with an empty TAF list whose Properties.UpdatedProjectsCount counts only the projects actually changed. What the Resource Planner service does with a deactivation (keep or drop the project's plans) is RP-side, unknown.
Use it to:
- Choose which projects are planned in the Resource Planner
Behaviour:
- Idempotent.
- Projects already in the requested state are skipped: a repeat call changes nothing and raises no events (UpdatedProjectsCount 0).
- Safe to retry.
- On failure: Projects processed before a failing write keep their new flag and their events were published.
- Consistency: eventual for the Resource Planner; immediate in TimeLog
- Batch: Unknown IDs are skipped silently; a failing write aborts the rest with 500 after earlier projects were switched.
Call first: GET /v2/projects
Not yet documented: behaviour → side effects; examples; request → query params → projectsIds.
curl -X PUT "https://app3.timelog.com/your-account/api/v2/projects/resource-planner?projectsIds=example_string" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{
"IsAddingToResourcePlanner": true
}'
import requests
import json
url = "https://app3.timelog.com/your-account/api/v2/projects/resource-planner?projectsIds=example_string"
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_TOKEN"
}
data = {
"IsAddingToResourcePlanner": true
}
response = requests.put(url, headers=headers, json=data)
print(response.json())
const response = await fetch("https://app3.timelog.com/your-account/api/v2/projects/resource-planner?projectsIds=example_string", {
method: "PUT",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_TOKEN"
},
body: JSON.stringify({
"IsAddingToResourcePlanner": true
})
});
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"net/http"
"bytes"
"encoding/json"
)
func main() {
data := []byte(`{
"IsAddingToResourcePlanner": true
}`)
req, err := http.NewRequest("PUT", "https://app3.timelog.com/your-account/api/v2/projects/resource-planner?projectsIds=example_string", bytes.NewBuffer(data))
if err != nil {
panic(err)
}
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println("Response Status:", resp.Status)
}
require 'net/http'
require 'json'
uri = URI('https://app3.timelog.com/your-account/api/v2/projects/resource-planner?projectsIds=example_string')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Put.new(uri)
request['Content-Type'] = 'application/json'
request['Authorization'] = 'Bearer YOUR_API_TOKEN'
request.body = '{
"IsAddingToResourcePlanner": true
}'
response = http.request(request)
puts response.body
{
"Properties": {
"UpdatedProjectsCount": "example_string"
},
"Links": [
{
"Href": "example_string",
"Rel": "example_string"
}
],
"Actions": [
{}
]
}
{
"error": "Unauthorized",
"message": "Authentication required. Please provide a valid API token",
"code": 401
}
{
"code": "UnsupportedApiVersion",
"error": "No route providing a controller name with API version '2' was found to match HTTP method 'PUT' and request URI 'https://app{server-number}.timelog.com/{account}/api/v2/projects/resource-planner'.",
"traceId": "…",
"type": "https://docs.api-versioning.org/problems#unsupported",
"title": "Unsupported API version",
"status": 405,
"detail": "The requested resource with API version '2' does not support HTTP method 'PUT'."
}
{
"error": "Internal Server Error",
"message": "An unexpected error occurred on the server",
"code": 500,
"requestId": "req_1234567890"
}
/v2/projects/resource-planner
Target server for requests. Edit to use your own host.
OAuth 2.0 bearer token, sent as Authorization: Bearer <token>. JWT and reference tokens are both accepted. The token must carry the required scope (default tlp).
The token's sub claim is the acting user. A token WITHOUT sub (client-credentials) acts as the system service user. If the sub user cannot log in (inactive, locked, deleted), the request is rejected with 401 — it is no longer let through without a user.
> Not yet documented: how to obtain a token.
> Not yet documented: token lifetime.
Authorization: Bearer <token>. JWT and reference tokens are both accepted. The token must carry the required scope (default tlp).
The token's sub claim is the acting user. A token WITHOUT sub (client-credentials) acts as the system service user. If the sub user cannot log in (inactive, locked, deleted), the request is rejected with 401 — it is no longer let through without a user.
> Not yet documented: how to obtain a token.
> Not yet documented: token lifetime.Comma-separated project IDs. All are parsed before any write (a non-integer entry fails the call with 500 before anything changes); unknown IDs are skipped. Omitted → 405 (captured).
Several values: one string, separated by ,.
The media type of the request body
true = make the projects available in the Resource Planner (IsAvailableInResourcePlanner on); false = take them out. Non-nullable: omitted = false, and the NotNull rule cannot fail — {} takes every listed project OUT of the Resource Planner. Default: false — removes the projects (see description) - The project already has the requested value — Skipped: no write, no event, not counted in UpdatedProjectsCount. - Omitted — false.
Request Preview
Response
Response will appear here after sending the request
Authentication
Bearer token. OAuth 2.0 bearer token, sent as Authorization: Bearer <token>. JWT and reference tokens are both accepted. The token must carry the required scope (default tlp).
The token's sub claim is the acting user. A token WITHOUT sub (client-credentials) acts as the system service user. If the sub user cannot log in (inactive, locked, deleted), the request is rejected with 401 — it is no longer let through without a user.
Not yet documented: how to obtain a token.
Not yet documented: token lifetime.
Query Parameters
Comma-separated project IDs. All are parsed before any write (a non-integer entry fails the call with 500 before anything changes); unknown IDs are skipped. Omitted → 405 (captured).
Several values: one string, separated by ,.
Body
true = make the projects available in the Resource Planner (IsAvailableInResourcePlanner on); false = take them out. Non-nullable: omitted = false, and the NotNull rule cannot fail — {} takes every listed project OUT of the Resource Planner.
Default: false — removes the projects (see description)
-
The project already has the requested value — Skipped: no write, no event, not counted in UpdatedProjectsCount.
-
Omitted — false.
Responses
How many projects a /v2/projects bulk write processed or changed.