Skip to content
Docs

When a hire asks before using a tool

GET
/api/workspaces/{ws}/hires/{id}/tools/{connection}/approvals

The tools the hire has on the connection (at its access level), each with its own rule (default: "always", "sometimes" with the rule saying when, or "never"), whether asking is locked (money moving), and the hire's setting ("ask", "auto" or null). A call that needs approval doesn't run: the approver is asked in the thread, and Roster makes exactly that call once it's approved. 404 when the hire isn't on the connection.

Authorization

session
cookiebetter-auth.session_token<token>

Set by POST /api/auth/sign-in/email.

Path Parameters

ws*string

The workspace id (from GET /api/me).

id*string

The id of what the path names: a hire, a connection, a skill, a shared file, a department, a position, a goal or an approval.

connection*string

The connection's id (from GET /api/workspaces/:ws/connections).

Response Body

The hire's tools on the connection.

application/json
Example Request
curl -X GET 'https://app.useroster.work/api/workspaces/string/hires/string/tools/string/approvals'
Example Response
{  "tools": [    {      "name": "create_event",      "label": "create event",      "description": "Add an event to a calendar, optionally inviting people.",      "mutates": true,      "default": "sometimes",      "rule": "when it invites someone outside your team",      "locked": false,      "setting": null    }  ]}