> ## Documentation Index
> Fetch the complete documentation index at: https://docs.postsyncer.com/llms.txt
> Use this file to discover all available pages before exploring further.

# List team members

> List a workspace's teammates, the people invited who haven't accepted yet, and the roles they can have.

> [!NOTE]
>
> Needs `team:read`, and a role in the workspace that can see the team: owners and managers can. See [Permissions](https://docs.postsyncer.com/essentials/authentication.md#permissions).

Gives the workspace's team, newest first, in `data`: each person's account `id`, name, email address, photo, role, and `is_active`, which is `false` while an invitation isn't accepted yet. The workspace owner is in the list too. `roles` lists the roles someone can be [invited](https://docs.postsyncer.com/api-reference/team/invite.md) as or [moved to](https://docs.postsyncer.com/api-reference/team/update.md); Owner isn't one of them. Not paged.

`workspace_id` is required. It reads the team only: it keeps nothing and emails no one. Every plan can list its team, Free included.

## Errors

| Status | `error` | When | Retry? |
| - | - | - | - |
| 401 | | No API key, or not a valid one. | No: fix the key. |
| 403 | | The key lacks `team:read`, or its user is inactive. | No: grant it in Settings → API. |
| 403 | | Your role in the workspace can't see the team. | No. |
| 422 | | No `workspace_id`, or one the key can't reach. | No: fix the request. |
| 429 | | More than 60 requests a minute. | Yes, after `Retry-After` seconds. |

## Related

* [Invite a team member](https://docs.postsyncer.com/api-reference/team/invite.md): add someone.
* [Update a team member](https://docs.postsyncer.com/api-reference/team/update.md): change a role, or send an invitation again.


## OpenAPI

````yaml GET /team-members
openapi: 3.0.3
info:
  title: PostSyncer API
  description: >-
    Post to 12 social networks from your code: posts, media, comments,
    analytics, webhooks and more.
  version: 1.0.0
servers:
  - url: https://postsyncer.com/api/v1
security:
  - bearerAuth: []
tags:
  - name: Workspaces
    description: The workspaces the key can reach.
  - name: Accounts
    description: Connected social accounts, links to connect more, and disconnecting them.
  - name: Posts
    description: Drafts, scheduled and published posts, approvals and a post's history.
  - name: Post settings
    description: A post's auto-plug, comment moderation and contact collection.
  - name: Media
    description: >-
      The media library: file uploads, URL imports, and reading videos and
      social posts' files.
  - name: Folders
    description: Folders that organise the media library.
  - name: Comments
    description: >-
      Comments on your posts: reading, replying, editing, hiding, deleting and
      syncing them.
  - name: Reviews
    description: Google Business Profile reviews and your replies to them.
  - name: Analytics
    description: Workspace, account and post performance.
  - name: Brand
    description: >-
      A workspace's brand: identity, voice, look, accounts, competitors,
      learnings and rules.
  - name: Labels
    description: Labels used to tag posts.
  - name: Campaigns
    description: Campaigns used to group posts.
  - name: Snippets
    description: Saved snippets and hashtag groups to drop into posts.
  - name: Webhooks
    description: Signed webhook endpoints that get your notification events.
  - name: Billing
    description: >-
      The owner's plan, invoices and the links that pay for, change or cancel
      it.
  - name: Team
    description: A workspace's teammates and invitations, and their roles.
  - name: Notifications
    description: >-
      Your bell and notification settings, and the workspace's Slack, Discord
      and Telegram channels.
  - name: Blog-to-social
    description: Blog feeds that turn a workspace's new articles into posts.
  - name: Products
    description: Products the workspace's posts can promote.
  - name: Contacts
    description: People who commented on the workspace's posts, and the lists they are on.
  - name: Profile
    description: 'The key''s user: their name and sign-in email.'
  - name: API keys
    description: 'Your API keys: listing and deleting them.'
  - name: Agent sign-up
    description: >-
      An AI agent signs a person up with a code emailed to them, and gets their
      first key. No key needed.
paths:
  /team-members:
    get:
      tags:
        - Team
      summary: List team members
      description: >-
        Needs `team:read`. Your role in the workspace must also let you see the
        team: owners and managers can. Gives the workspace's members and the
        people invited who haven't accepted yet, newest first, in `data`, and
        the roles someone can be invited as or moved to in `roles`. Not paged.
        Every plan can list its team, Free included.
      operationId: listTeamMembers
      parameters:
        - name: workspace_id
          in: query
          required: true
          description: The workspace. It must be one the key can reach.
          schema:
            type: integer
            example: 12
      responses:
        '200':
          description: The team and the roles.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TeamMemberList'
              examples:
                default:
                  summary: An invitation, a manager and the owner
                  value:
                    data:
                      - id: 58
                        workspace_id: 12
                        name: mara
                        email: mara@haldencoffee.com
                        avatar_url: >-
                          https://ui-avatars.com/api/?name=mara&color=FFFFFF&background=6366F1
                        role:
                          name: APP_CONTENT_CREATOR
                          label: Content Creator
                          description: >-
                            Can create and edit posts, products, campaigns,
                            labels, snippets, comments, and manage media
                            library. Can view analytics and calendar. Has view
                            access to accounts but cannot manage them. Posts
                            require approval before publishing.
                          has_approval_permission: false
                          has_publishing_permission: false
                        is_active: false
                      - id: 41
                        workspace_id: 12
                        name: Tom Okafor
                        email: tom@haldencoffee.com
                        avatar_url: >-
                          https://ui-avatars.com/api/?name=Tom+Okafor&color=FFFFFF&background=6366F1
                        role:
                          name: APP_MANAGER
                          label: Manager
                          description: >-
                            Can manage team members, accounts, contacts, and
                            workspace settings. Has full access to create, edit,
                            delete, and publish posts, products, campaigns,
                            labels, snippets, comments, and media library. Can
                            view analytics and calendar. Cannot access billing
                            or create new workspaces.
                          has_approval_permission: true
                          has_publishing_permission: true
                        is_active: true
                      - id: 7
                        workspace_id: 12
                        name: Lena Halden
                        email: lena@haldencoffee.com
                        avatar_url: >-
                          https://ui-avatars.com/api/?name=Lena+Halden&color=FFFFFF&background=6366F1
                        role:
                          name: APP_OWNER
                          label: Owner
                          description: >-
                            Has full control over the workspace including
                            billing, team management, and all workspace
                            settings. Can create, edit, and delete all content,
                            accounts, contacts, products, campaigns, labels,
                            snippets, comments, and manage the media library.
                            Has access to analytics and calendar. Can create
                            additional workspaces.
                          has_approval_permission: true
                          has_publishing_permission: true
                        is_active: true
                    roles:
                      - name: APP_MANAGER
                        label: Manager
                        description: >-
                          Can manage team members, accounts, contacts, and
                          workspace settings. Has full access to create, edit,
                          delete, and publish posts, products, campaigns,
                          labels, snippets, comments, and media library. Can
                          view analytics and calendar. Cannot access billing or
                          create new workspaces.
                        has_approval_permission: true
                        has_publishing_permission: true
                      - name: APP_CONTENT_MANAGER
                        label: Content Manager
                        description: >-
                          Can create, edit, and publish posts, products,
                          campaigns, labels, snippets, comments, and manage
                          media library. Can view analytics and calendar. Has
                          view access to accounts but cannot manage them. Can
                          approve posts from content creators.
                        has_approval_permission: true
                        has_publishing_permission: true
                      - name: APP_CONTENT_CREATOR
                        label: Content Creator
                        description: >-
                          Can create and edit posts, products, campaigns,
                          labels, snippets, comments, and manage media library.
                          Can view analytics and calendar. Has view access to
                          accounts but cannot manage them. Posts require
                          approval before publishing.
                        has_approval_permission: false
                        has_publishing_permission: false
                      - name: APP_CLIENT
                        label: Client
                        description: >-
                          Has view-only access to posts, products, campaigns,
                          labels, snippets, comments, analytics, and calendar.
                          Can approve posts but cannot create, edit, or publish
                          content. Cannot access team management, accounts,
                          contacts, or workspace settings.
                        has_approval_permission: true
                        has_publishing_permission: false
        '401':
          $ref: '#/components/responses/Unauthorized401'
        '403':
          description: >-
            The key lacks `team:read`, its user is inactive, or your role in the
            workspace can't see the team.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                missing_permission:
                  summary: The key lacks team:read
                  value:
                    message: >-
                      This API key does not have the "team:read" permission.
                      Edit the key in PostSyncer under Settings → API to grant
                      it.
                role:
                  summary: The role can't view team members
                  value:
                    message: >-
                      Your role in the workspace "Halden Coffee" does not allow
                      you to view team members. Ask the workspace owner or a
                      manager to do it, or to change your role.
                inactive_account:
                  summary: The key's user is inactive
                  value:
                    message: Your account is inactive.
        '422':
          description: No `workspace_id`, or one the key can't reach.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationError'
              examples:
                workspace_id:
                  summary: Not a workspace the key can reach
                  value:
                    message: Invalid workspace ID.
                    errors:
                      workspace_id:
                        - Invalid workspace ID.
                workspace_id_missing:
                  summary: No workspace_id
                  value:
                    message: The workspace id field is required.
                    errors:
                      workspace_id:
                        - The workspace id field is required.
        '429':
          $ref: '#/components/responses/RateLimited429'
      x-codeSamples:
        - lang: bash
          label: cURL
          source: |-
            curl --request GET \
              --url 'https://postsyncer.com/api/v1/team-members?workspace_id=12' \
              --header 'Authorization: Bearer <token>'
        - lang: javascript
          label: JavaScript
          source: >-
            const options = {method: 'GET', headers: {Authorization: 'Bearer
            <token>'}};


            fetch('https://postsyncer.com/api/v1/team-members?workspace_id=12',
            options)
              .then(res => res.json())
              .then(res => console.log(res))
              .catch(err => console.error(err));
        - lang: python
          label: Python
          source: |-
            import requests

            url = "https://postsyncer.com/api/v1/team-members?workspace_id=12"

            headers = {"Authorization": "Bearer <token>"}

            response = requests.get(url, headers=headers)

            print(response.text)
        - lang: php
          label: PHP
          source: |-
            <?php

            $curl = curl_init();

            curl_setopt_array($curl, [
              CURLOPT_URL => "https://postsyncer.com/api/v1/team-members?workspace_id=12",
              CURLOPT_RETURNTRANSFER => true,
              CURLOPT_ENCODING => "",
              CURLOPT_MAXREDIRS => 10,
              CURLOPT_TIMEOUT => 30,
              CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
              CURLOPT_CUSTOMREQUEST => "GET",
              CURLOPT_HTTPHEADER => [
                "Authorization: Bearer <token>"
              ],
            ]);

            $response = curl_exec($curl);
            $err = curl_error($curl);

            curl_close($curl);

            if ($err) {
              echo "cURL Error #:" . $err;
            } else {
              echo $response;
            }
components:
  schemas:
    TeamMemberList:
      type: object
      description: A workspace's team and the roles its people can have.
      required:
        - data
        - roles
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/TeamMember'
          description: Members and invitations not accepted yet, newest first.
        roles:
          type: array
          items:
            $ref: '#/components/schemas/TeamRole'
          description: >-
            The roles someone can be invited as or moved to. Owner is not one of
            them.
    Error:
      type: object
      description: >-
        An error answer. Every one has `message`, in plain words; some add an
        `error` code and fields of their own.
      required:
        - message
      properties:
        message:
          type: string
          description: What went wrong and what to do about it.
        error:
          type: string
          description: >-
            A code a few errors add, such as `rate_limited`. See [Handle
            errors](/essentials/error-handling#answers-with-an-error-code).
    ValidationError:
      type: object
      description: '422: the request didn''t pass validation, and nothing changed.'
      required:
        - message
        - errors
      properties:
        message:
          type: string
          description: >-
            The first error and, when there are more, how many: `(and 1 more
            error)`, `(and 2 more errors)`.
        errors:
          type: object
          description: >-
            The messages, by field. A field inside a list is named with dots:
            `accounts.0.id`.
          additionalProperties:
            type: array
            items:
              type: string
    TeamMember:
      type: object
      description: A teammate, or someone invited who hasn't accepted yet.
      required:
        - id
        - workspace_id
        - name
        - email
        - avatar_url
        - role
        - is_active
      properties:
        id:
          type: integer
          description: 'The person''s account id: the `{id}` to update or remove them.'
        workspace_id:
          type: integer
        name:
          type: string
          description: >-
            Their name. Until they set one, it is the email address's part
            before the @.
        email:
          type: string
          format: email
        avatar_url:
          type: string
          description: Their photo, or a picture of their initials.
        role:
          $ref: '#/components/schemas/TeamRole'
        is_active:
          type: boolean
          description: False while the invitation isn't accepted yet.
    TeamRole:
      type: object
      description: A role in a workspace.
      required:
        - name
        - label
        - description
        - has_approval_permission
        - has_publishing_permission
      properties:
        name:
          type: string
          enum:
            - APP_OWNER
            - APP_MANAGER
            - APP_CONTENT_MANAGER
            - APP_CONTENT_CREATOR
            - APP_CLIENT
          description: >-
            The role to send as `role`. `APP_OWNER` is the workspace owner's,
            and is never given.
        label:
          type: string
          description: The role as the app names it.
        description:
          type: string
          description: What the role can do.
        has_approval_permission:
          type: boolean
          description: Whether the role can approve posts.
        has_publishing_permission:
          type: boolean
          description: Whether the role can publish without approval.
  responses:
    Unauthorized401:
      description: No API key, or not a valid one.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            unauthenticated:
              summary: No valid API key
              value:
                message: Unauthenticated.
    RateLimited429:
      description: >-
        More than 60 requests in a minute from this key's user (the API and the
        MCP server share the count). Wait `Retry-After` seconds.
      headers:
        Retry-After:
          description: Seconds until requests are allowed again.
          schema:
            type: integer
        X-RateLimit-Limit:
          description: Requests allowed a minute.
          schema:
            type: integer
        X-RateLimit-Remaining:
          description: Requests left this minute.
          schema:
            type: integer
        X-RateLimit-Reset:
          description: When requests are allowed again, as a Unix timestamp.
          schema:
            type: integer
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            too_many_attempts:
              summary: Too many requests
              value:
                message: Too Many Attempts.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.