Skip to content
Download Beeper

List contacts

client.accounts.contacts.list(stringaccountID, ContactListParams { cursor, direction, limit, query } query?, RequestOptionsoptions?): CursorSearch<User { id, cannotMessage, email, 5 more } >
GET/v1/accounts/{accountID}/contacts/list

List merged contacts for a specific account with cursor-based pagination.

ParametersExpand Collapse
accountID: string

Account ID this resource belongs to.

query: ContactListParams { cursor, direction, limit, query }
cursor?: string

Opaque pagination cursor; do not inspect. Use together with 'direction'.

direction?: "after" | "before"

Pagination direction used with 'cursor': 'before' fetches older results, 'after' fetches newer results. Defaults to 'before' when only 'cursor' is provided.

Accepts one of the following:
"after"
"before"
limit?: number

Maximum contacts to return per page.

minimum1
maximum200
query?: string

Optional search query for blended contact lookup.

minLength1
ReturnsExpand Collapse
User { id, cannotMessage, email, 5 more }

User the account belongs to.

id: string

Stable Beeper user ID. Use as the primary key when referencing a person.

cannotMessage?: boolean

True if Beeper cannot initiate messages to this user (e.g., blocked, network restriction, or no DM path). The user may still message you.

email?: string

Email address if known. Not guaranteed verified.

fullName?: string

Display name as shown in clients (e.g., 'Alice Example'). May include emojis.

imgURL?: string

Avatar image URL if available. May be temporary or local-only to this device; download promptly if durable access is needed.

isSelf?: boolean

True if this user represents the authenticated account's own identity.

phoneNumber?: string

User's phone number in E.164 format (e.g., '+14155552671'). Omit if unknown.

username?: string

Human-readable handle if available (e.g., '@alice'). May be network-specific and not globally unique.

List contacts

import BeeperDesktop from '@beeper/desktop-api';

const client = new BeeperDesktop();

// Automatically fetches more pages as needed.
for await (const user of client.accounts.contacts.list('accountID')) {
  console.log(user.id);
}
{
  "hasMore": true,
  "items": [
    {
      "id": "id",
      "cannotMessage": true,
      "email": "email",
      "fullName": "fullName",
      "imgURL": "imgURL",
      "isSelf": true,
      "phoneNumber": "phoneNumber",
      "username": "username"
    }
  ],
  "newestCursor": "newestCursor",
  "oldestCursor": "oldestCursor"
}
Returns Examples
{
  "hasMore": true,
  "items": [
    {
      "id": "id",
      "cannotMessage": true,
      "email": "email",
      "fullName": "fullName",
      "imgURL": "imgURL",
      "isSelf": true,
      "phoneNumber": "phoneNumber",
      "username": "username"
    }
  ],
  "newestCursor": "newestCursor",
  "oldestCursor": "oldestCursor"
}