Skip to content
Join our SlackContact usGet started

List Subjects

client.subjects.list(SubjectListParams { limit, offset } query?, RequestOptionsoptions?): SubjectListResponse { has_more, subjects }
get/subjects

List Subjects

ParametersExpand Collapse
query: SubjectListParams { limit, offset }
limit?: number
maximum100
minimum1
offset?: number
minimum0
ReturnsExpand Collapse
SubjectListResponse { has_more, subjects }
has_more: boolean
subjects: Array<SubjectResource { id, created_at, email, 3 more } >
id: string

The ID of the subject.

created_at: string

The date and time the subject was created.

formatdate-time
email: string | null

The email of the subject.

formatemail
external_id: string | null

The ID of the subject in your system. You may pass it to the API in place of the subject ID.

metadata: Record<string, string>

Additional metadata about the subject. You may use this to store any custom data about the subject.

name: string | null

The name of the subject. Used for display in the dashboard.

List Subjects
import Lark from 'lark-billing';

const client = new Lark({
  apiKey: 'My API Key',
});

const subjects = await client.subjects.list();

console.log(subjects.has_more);
{
  "has_more": true,
  "subjects": [
    {
      "id": "subj_VyX6Q96h5avMho8O7QWlKeXE",
      "created_at": "2025-11-01T00:00:00Z",
      "email": "john.doe@example.com",
      "external_id": "user_1234567890",
      "metadata": {},
      "name": "John Doe"
    }
  ]
}
Returns Examples
{
  "has_more": true,
  "subjects": [
    {
      "id": "subj_VyX6Q96h5avMho8O7QWlKeXE",
      "created_at": "2025-11-01T00:00:00Z",
      "email": "john.doe@example.com",
      "external_id": "user_1234567890",
      "metadata": {},
      "name": "John Doe"
    }
  ]
}