Skip to main content

createRedirectUrl()

Creates a new redirect URL for the instance.

Returns the created RedirectUrl object.

function createRedirectUrl(params: CreateRedirectUrlParams): Promise<RedirectUrl>
  • Name
    url
    Type
    string
    Description

    The full URL value prefixed with https:// or a custom scheme. For example, https://my-app.com/oauth-callback or my-app://oauth-callback.

Note

Using clerkClient varies based on the SDK you're using. Refer to the overview for usage details, including guidance on how to access the userId and other properties.

const response = await clerkClient.redirectUrls.createRedirectUrl({
  url: 'https://example.com',
})

Backend API (BAPI) endpoint

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

Feedback

What did you think of this content?

Last updated on