Skip to main content
Docs

createBulk()

Creates multiple WaitlistEntrys in bulk for the given email addresses.

If an email address is already on the waitlist, no new entry will be created and the existing waitlist entry will be returned.

function createBulk(params: WaitlistEntryBulkCreateParams): Promise<WaitlistEntry[]>

Parameters

createBulk() accepts the following parameters:

  • Name
    emailAddress
    Type
    string
    Description

    The email address to add to the waitlist.

  • Name
    notify?
    Type
    boolean
    Description

    Whether to send an email notification to the user. Defaults to false.

Note

Using clerkClient varies based on your framework. Refer to the JS Backend SDK overviewClerk Icon for usage details, including guidance on how to access the userId and other propertiesClerk Icon.

// Each object in the array represents a single waitlist entry
const params = [
  {
    emailAddress: 'user1@example.com',
  },
  {
    emailAddress: 'user2@example.com',
    notify: true,
  },
]

const response = await clerkClient.waitlistEntries.createBulk(params)

Backend API (BAPI) endpoint

This method in the SDK is a wrapper around the BAPI endpoint POST/waitlist_entries/bulk. See the BAPI reference for more information.

Feedback

What did you think of this content?

Last updated on

GitHubEdit on GitHub