First-party app
Hubstaff Hubstaff

Hubstaff

Read the organizations, projects, members, teams, clients, tasks, activities and timesheets that make up a Hubstaff organization, and write back time entries and tasks.

stable Project ManagementHuman ResourcesProductivity

About

Hubstaff ships in the w6w first-party pack. It declares 19 actions, 2 health checks, and the host runs its code in a sandbox that never sees the credential.

App id
io.w6w.hubstaff
Version
0.1.1
Author
w6w
Licence
MIT
Categories
Project Management · Human Resources · Productivity

Overview

Hubstaff is time tracking and workforce management: members track hours against projects and tasks, those hours roll up into timesheets, and organizations review, approve and invoice them.

This app covers the read surface a time-tracking integration needs — organizations, users, projects, members, teams, clients, tasks, activities and timesheets, each listed one cursor page at a time — and the three writes the API v2 actually offers for them: creating a manual time entry, creating a task, and moving a timesheet through its approval states.

Authentication is an Organization access token (hsoat_…), a long-lived org-wide secret an admin creates in the Hubstaff app and assigns to a member. There is no browser flow and no token exchange, so the whole credential story is one Authorization: Bearer header. Health checks cover Hubstaff’s own status page (the API & Mobile component that speaks for api.hubstaff.com) and the organization’s rate-limit headroom.

Build with Hubstaff

Three routes to the same 19 actions. The Workflow tab is generated from Hubstaff's own manifest and carries its real ids, so it is copy-pasteable; the Code and CLI examples are the same call for any action on any app, so every app-specific value in them is a blank you fill in.

List Activities

activity-list

List an organization's tracked activity blocks (GET /v2/organizations/{organization_id}/activities).

Get Client

client-get

Get one client by ID (GET /v2/clients/{client_id}).

List Clients

client-list

List an organization's clients (GET /v2/organizations/{organization_id}/clients).

List Members

member-list

List an organization's memberships (GET /v2/organizations/{organization_id}/members).

Get Organization

organization-get

Get one organization by ID (GET /v2/organizations/{organization_id}).

List Organizations

organization-list

List the organizations the connected member is an active member of (GET /v2/organizations).

List Project Activities

project-activity-list

List the tracked activity blocks on one project (GET /v2/projects/{project_id}/activities).

Get Project

project-get

Get one project by ID (GET /v2/projects/{project_id}).

List Projects

project-list

List an organization's projects (GET /v2/organizations/{organization_id}/projects).

Create Task

task-create

Create a task in a project (POST /v2/projects/{project_id}/tasks).

Get Task

task-get

Get one task by ID (GET /v2/tasks/{task_id}).

List Tasks

task-list

List an organization's tasks (GET /v2/organizations/{organization_id}/tasks).

Get Team

team-get

Get one team by ID (GET /v2/teams/{team_id}).

List Teams

team-list

List an organization's teams (GET /v2/organizations/{organization_id}/teams).

Create Time Entry

time-entry-create

Add a manual time entry for a member (POST /v2/users/{user_id}/time_entries).

List Timesheets

timesheet-list

List an organization's timesheets (GET /v2/organizations/{organization_id}/timesheets).

Update Timesheet Status

timesheet-update-status

Set a timesheet's approval status (PUT /v2/timesheets/{timesheet_id}).

Get User

user-get

Get one user by ID (GET /v2/users/{user_id}).

Get Current User

user-me

Get the member the connected Organization access token acts as (GET /v2/users/me).

A workflow step names the app and the action, and the editor fills in the connection when you pick one. This is the Step shape from the workflow spec, carrying Hubstaff's real ids.

{
  "manifestVersion": "2",
  "name": "hubstaff-example",
  "steps": [
    {
      "id": "activity-list",
      "uses": {
        "app": "io.w6w.hubstaff",
        "action": "activity-list",
        "connection": "conn_YOUR_CONNECTION_ID"
      },
      "with": {
        "organization_id": "<organization_id>"
      }
    }
  ]
}

Here are some of the things you can do

  • List Activities

    read
    activity-list
  • Get Client

    read
    client-get
  • List Clients

    read
    client-list
  • List Members

    read
    member-list
  • Get Organization

    read
    organization-get

+14 more actions available

Every app-specific value here is a blank you have to fill in. An app action is reached through the connection that authenticates it, so the address is a connection id, not the app id — and connections belong to your account, so a public page cannot know yours. Create one for Hubstaff, then fill in the three blanks: conn_YOUR_CONNECTION_ID, the action key, and the parameters that action declares. The call itself is real — the shape is transcribed from the studio's own snippet builder, which prints the same kind of blanks — but nothing in it is specific to Hubstaff. The Workflow tab is where this app's real ids are.

Install
npm install @w6w/sdk
yarn add @w6w/sdk
pnpm add @w6w/sdk
deno add npm:@w6w/sdk
Code
import { W6wClient, isActionRun } from "@w6w/sdk";

// Reads W6W_BASE_URL and W6W_TOKEN from the environment when omitted.
const client = new W6wClient();

const envelope = await client.run({
  urn: "conn_YOUR_CONNECTION_ID",
  action: "activity-list",
  payload: {
    organization_id: "<value>",
    // time_slot_start: "<value>",
    // time_slot_stop: "<value>",
    // user_ids: "<value>",
    // project_ids: "<value>",
    // task_ids: "<value>",
    // time_zone: "<value>",
    // include: "<value>",
    // page_start_id: "<value>",
    // page_limit: "<value>",
  },
});

if (isActionRun(envelope)) console.log(envelope.value);
Install the CLI
npm install -g @w6w/cli
CLI
w6w run conn_YOUR_CONNECTION_ID --action activity-list --payload '{"organization_id":"<value>"}'

Give an AI agent Hubstaff — without giving it Hubstaff's credentials. One MCP endpoint exposes every app, function and workflow the caller is entitled to, as tools it can discover and run. Access is granted per team while we onboard.

One tool call
{
  "name": "w6w_invoke",
  "arguments": {
    "ref": "app:io.w6w.hubstaff#activity-list",
    "input": {
      "organization_id": "<organization_id>"
    }
  }
}

Every tool names its target with a single ref. The app: form above doesn't name a connection at all — the host resolves which of the caller's Hubstaff connections to sign with, and refuses rather than guesses when the answer is ambiguous.

What the agent gets

Credentials it can't read

The token is attached host-side, at the moment of the call. It is never a tool argument, never in the model's context, and never in a transcript — so a prompt injection has nothing to exfiltrate.

A tool surface scoped to the caller

Tools are derived per end user from what that person has actually connected and is entitled to — not one shared bot identity carrying the union of everyone's access.

A durable workflow in one call

Multi-step work runs on the workflow engine and returns a run handle the agent can poll — retries, branching and state survive the conversation that started them.

Health-aware discovery

Hubstaff's declared health checks are on the surface too, so an agent can tell "the vendor is down" from "your credential expired" before it burns a retry on either.

The MCP surface is part of the hosted platform. Hubstaff itself is MIT, and the runtime that executes it is source-available (FSL).

Request MCP access

Health checks

Hubstaff declares its own checks, so its health is a property of the app rather than something the host guesses at.

service

Hubstaff API status

The `API & Mobile` component of status.hubstaff.com (Better Stack), the one monitor that covers api.hubstaff.com. Informational: the monitor also stands for the mobile clients, and the page's other five components cover unrelated Hubstaff products.

quota

API request-rate headroom

Requests remaining in the current window, read from the X-Rate-Limit-Limit / X-Rate-Limit-Remaining / X-Rate-Limit-Reset response headers on a cheap GET /v2/organizations. Hubstaff documents 120 requests/minute per access token by default, lower on activities and screenshots.