g2bAPI Reference
Work

List workspaces and threads

Returns the repositories, branches, threads, and latest runs visible to the caller.

GET
/v1/work

Returns the repositories, branches, threads, and latest runs visible to the caller.

Authorization

bearerAuth
AuthorizationBearer <token>

Create an API key in g2b Settings, then send it as a Bearer token.

In: header

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/v1/work"
{  "projects": [    {      "id": "string",      "name": "string",      "repository": "string",      "branch": "string",      "threads": [        {          "id": "string",          "project_id": "string",          "status": "setup",          "prompt": null,          "harness": "string",          "model": "string",          "reasoning_effort": "string",          "sandbox_status": "initializing",          "additions": -9007199254740991,          "deletions": -9007199254740991,          "latest_run": null,          "created_at": "2019-08-24T14:15:22Z",          "updated_at": "2019-08-24T14:15:22Z"        }      ]    }  ]}
{  "error": {    "code": "string",    "message": "string"  }}
{  "error": "Unauthorized"}
{  "error": {    "code": "string",    "message": "string"  }}
{  "error": {    "code": "string",    "message": "string"  }}