CONNECT APP
Build with Toggl Track
Productivity
- API key
MCP
Give your agent Toggl Track tools
Every Toggl Track action is exposed as an MCP tool on Pipedream's remote server. Point a client at it with your end user's ID and Connect resolves that user's Toggl Track account for each tool call — you store no tokens.
// accessToken: mint a short-lived token with the Connect SDK — see the MCP guide
const transport = new StreamableHTTPClientTransport(
new URL("https://remote.mcp.pipedream.net/v3"),
{
requestInit: {
headers: {
Authorization: `Bearer ${accessToken}`,
"x-pd-project-id": "{project_id}",
"x-pd-environment": "production",
"x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
"x-pd-app-slug": "toggl",
},
},
},
)
const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)
const { tools } = await mcp.listTools()
// e.g. run Create Client:
const result = await mcp.callTool({
name: "toggl-create-client",
arguments: {
workspaceId: 10,
name: "Name",
},
})# access_token: mint a short-lived token with the Connect SDK — see the MCP guide
headers = {
"Authorization": f"Bearer {access_token}",
"x-pd-project-id": "{project_id}",
"x-pd-environment": "production",
"x-pd-external-user-id": "{external_user_id}", # any stable ID for this user in your system
"x-pd-app-slug": "toggl",
}
async with streamablehttp_client("https://remote.mcp.pipedream.net/v3", headers=headers) as (read, write, _):
async with ClientSession(read, write) as session:
await session.initialize()
tools = await session.list_tools()
# e.g. run Create Client:
result = await session.call_tool("toggl-create-client", {
"workspaceId": 10,
"name": "Name",
})API PROXY
Call the Toggl Track API directly
For an endpoint with no pre-built tool, the Connect proxy forwards your request to the Toggl Track API with the connected user's credentials attached. You store no tokens and write no refresh logic.
const resp = await pd.proxy.get({
externalUserId: "{external_user_id}", // any stable ID for this user in your system
accountId: "apn_xxxxxxx",
url: "https://api.track.toggl.com/api/v9/me",
})
// Any allowed Toggl Track endpoint works here. Pipedream attaches the
// connected account's credentials to the outgoing request.# The path segment is the target URL, URL-safe base64 encoded:
# https://api.track.toggl.com/api/v9/me
curl "https://api.pipedream.com/v1/connect/{project_id}/proxy/aHR0cHM6Ly9hcGkudHJhY2sudG9nZ2wuY29tL2FwaS92OS9tZQ?external_user_id={external_user_id}&account_id=apn_xxxxxxx" \
-H "Authorization: Bearer {access_token}" \
-H "x-pd-environment: production"SDK
Run Toggl Track actions from your backend
Connect a user's Toggl Track account once, then run Create Client on their behalf from your own code — TypeScript, Python, or plain HTTP.
import { PipedreamClient } from "@pipedream/sdk"
const pd = new PipedreamClient({
projectId: process.env.PIPEDREAM_PROJECT_ID!,
clientId: process.env.PIPEDREAM_CLIENT_ID!,
clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
projectEnvironment: "production",
})
const result = await pd.actions.run({
id: "toggl-create-client",
externalUserId: "{external_user_id}", // any stable ID for this user in your system
configuredProps: {
toggl: { authProvisionId: "apn_xxxxxxx" },
workspaceId: 10,
name: "Name",
},
})from pipedream import Pipedream
pd = Pipedream(
client_id="{oauth_client_id}",
client_secret="{oauth_client_secret}",
project_id="{project_id}",
project_environment="production",
)
result = pd.actions.run(
id="toggl-create-client",
external_user_id="{external_user_id}", # any stable ID for this user in your system
configured_props={
"toggl": {"authProvisionId": "apn_xxxxxxx"},
"workspaceId": 10,
"name": "Name",
},
)curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
-H "Content-Type: application/json" \
-H "X-PD-Environment: production" \
-H "Authorization: Bearer {access_token}" \
-d '{
"external_user_id": "{external_user_id}",
"id": "toggl-create-client",
"configured_props": {
"toggl": { "authProvisionId": "apn_xxxxxxx" },
"workspaceId": 10,
"name": "Name"
}
}'TOOLS
Toggl Track actions
On-demand operations your product or agent can configure and run on behalf of a connected user.
-
Create Client
actionCreate a new client in Toggl. See the documentationWritev0.0.4 -
Create Project
actionCreate a new project in Toggl. See the documentationWritev0.0.4 -
Export Detailed Time Entries
actionExport a complete Toggl Track detailed report as CSV in one request. Use this for monthly or other large reports that may exceed the execution time of paginated JSON searches. The CSV contains only records visible to the connected user. CSV export may require a paid Toggl Track plan. See the documentationRead-onlyv0.0.2 -
Get Current Time Entry
actionGet the time entry that is running now. [See docs here]https://developers.track.toggl.com/docs/api/time_entries#get-get-current-time-entry)Read-onlyv0.0.9 -
Get Project Task Time Summary
actionGet how much time was tracked on each task of one Toggl Track project over a date range, with task names, plus the time tracked on the project without a task. Use it when a user asks how much time each task of a project took, e.g. "how long did each task on Website Redesign take last week?". Use List Workspace Projects first to get the project ID. For per-user or per-project totals use Get Time Entry Summary, and for the individual time entries use Search Detailed Time Entries; both accept a project filter. A date range is required: either a Date Preset (resolved in the connected user's Toggl timezone and first day of week) or both Start Date and End Date. ReturnsdateRange,totalSeconds,tasks(each withtaskId,taskNameandseconds, most time first) anduntaskedSeconds. Example: workspaceId=1234567, projectId=123456789, datePreset="last_week" → each task's tracked seconds for last week. See the documentationRead-onlyv0.0.1 -
Get Time Entries
actionGet the last thousand time entries. See docs hereRead-onlyv0.0.11 -
Get Time Entry
actionGet details about a specific time entry. See docs hereRead-onlyv0.0.9 -
Get Time Entry Summary
actionReturn Toggl-computed summary report groups and totals by user, client, or project. For time per task on one project, use Get Project Task Time Summary. Results are limited by the connected user's Toggl permissions. See the documentationRead-onlyv0.0.2 -
List Project Tasks
actionList the tasks under one Toggl Track project, with each task's estimated seconds and all-time tracked seconds. Use it when a user asks what tasks a project has. Use List Workspace Projects first to get the project ID; there is no workspace-wide task listing, and this action does not return time entries (use Get Project Task Time Summary for time per task over a date range). Returns an array of tasks with id, name, project_id, workspace_id, active, estimated_seconds and tracked_seconds, empty when the project has none. Example: workspaceId=1234567, projectId=123456789, active=true → the project's active tasks with their estimated and tracked seconds. See the documentationRead-onlyv0.0.1 -
List Time Entry ID Options
actionRetrieves available options for the Time Entry ID field.Read-onlyv0.0.3 -
List Workspace ID Options
actionRetrieves available options for the Workspace ID field.Read-onlyv0.0.3 -
List Workspace Projects
actionList the projects in a Toggl Track workspace, optionally filtered by active status or a name fragment. Use it to find a project ID before calling List Project Tasks or Get Project Task Time Summary, or to answer "what projects do we have". To find a workspace ID, use List Workspace ID Options; this action does not return time entries or tracked hours (use Get Time Entry Summary or Search Detailed Time Entries with a project filter for those). Returns at most 1000 projects, each withidplus the selected fields (default: name, client_id, active, billable, color, start_date, end_date, created_at). Example: workspaceId=1234567, name="Website", active="true" → matching projects with id, name, client_id, active, billable. See the documentationRead-onlyv0.0.1 -
List Workspace Users
actionList users visible to the connected Toggl Track account in a workspace. Optionally filter by a full or partial name or email address. Use the returneduserIdas a User IDs value in Search Detailed Time Entries, Get Time Entry Summary, or Export Detailed Time Entries. See the documentationRead-onlyv0.0.2 -
Search Detailed Time Entries
actionSearch workspace-wide Toggl Track time entries with structured filters and provider-computed totals. Follows Toggl Reports API cursors up to an explicit cap and returns deterministic JSON without model rewriting. Only present the entries as a complete report whencompleteis true; otherwise use Export Detailed Time Entries. For time per task on one project, use Get Project Task Time Summary. Results are limited by the connected user's Toggl permissions. See the documentationRead-onlyv1.0.1 -
Update Client
actionUpdates an existing client in Toggl. See the documentationWritev0.0.4 -
Update Project
actionUpdates an existing project in Toggl. See the documentationWritev0.0.4
EVENTS
Toggl Track triggers
Event sources your backend can deploy for users and receive through a webhook.
-
New Start Time Entry (Instant)
triggerEmit new event when a time entry is started. See docs hereInstantv0.0.6 -
New Time Entry (Instant)
triggerEmit new event when a time entry is created. See docs hereInstantv0.0.6 -
New Update Time Entry (Instant)
triggerEmit new event when a time entry is updated. See docs hereInstantv0.0.6 -
New Webhook Event (Instant)
triggerEmit new event on receive a webhook event. See docs hereInstantv0.0.6
- App slug
- toggl
- Authentication
- API key
- Categories
- Productivity
- Actions
- 16
- Triggers
- 4
- API proxy
- Available