Skip to content
Swingback, home

API reference

Members

Members are your workspace's team, each an owner or an admin. The API lists them; you invite members and change their roles in the dashboard, under Settings → Team.

The examples read your API key and your workspace's base URL from two shell variables. Set them once, with your workspace's id in place of ws_... (API keys says where to find both):

Terminal
export SWINGBACK_API_KEY="s_live_..."
export SWINGBACK_API="https://api.swingback.dev/v1/workspaces/ws_..."
Download the OpenAPI specJSON

List members#

GET/v1/workspaces/{workspace_id}/members

Any API key: Read or Read and write

Returns the workspace's team members, the earliest to join first.

Path parameters

  • workspace_idstringrequired

    Your workspace's id, shown under Settings → Sign-in.

    Starts with ws_

Query parameters

  • limitinteger

    How many items to return in the page.

    From 1 to 100Defaults to 25

  • cursorstring

    The previous page's next_cursor, to get the next page.

    At most 1,024 characters

Responses

Example

Request
curl "$SWINGBACK_API/members" \
  -H "Authorization: Bearer $SWINGBACK_API_KEY"
Response · 200 OK
{
  "data": [
    {
      "id": "mem_01h455vb4pex5vsknk084sn02q",
      "account": {
        "id": "acct_01h455vb4pex5vsknk084sn02q",
        "avatar_url": null,
        "email": "sam@acme.example.com",
        "name": "Sam Lee"
      },
      "role": "owner",
      "created_at": "2026-09-28T14:03:12.482Z"
    }
  ],
  "next_cursor": null,
  "has_more": false
}

The member object#

Fields

  • idstring

    Starts with mem_

  • accountobject

    A team member's account. Its id is what a changelog entry's author_ids take.

    Child fields (4)
    • idstring

      Starts with acct_

    • avatar_urlstringnullable

      At most 2,048 characters

    • emailstring · email
    • namestringnullable

      At most 100 characters

  • rolestring

    owner or admin. Only owners manage owners and roles, the slug, the custom domain, billing and exports, and delete the workspace.

    One ofowneradmin
  • created_atstring · date-time

    When the member joined the workspace.

Example

The member object
{
  "id": "mem_01h455vb4pex5vsknk084sn02q",
  "account": {
    "id": "acct_01h455vb4pex5vsknk084sn02q",
    "avatar_url": null,
    "email": "sam@acme.example.com",
    "name": "Sam Lee"
  },
  "role": "owner",
  "created_at": "2026-09-28T14:03:12.482Z"
}

Search pages, sections and code: a setting, an event, a method.