āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā ā š shadcn/directory/clerk/clerk-docs/reference/backend/oauth-applications/update ā āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā
update()'
description: Use Clerk's JS Backend SDK to update an OAuth application.
sdk: js-backendUpdates an OAuthApplication by its ID.
function update(params: UpdateOAuthApplicationParams): Promise<OAuthApplication>
UpdateOAuthApplicationParamsThe ID of the OAuth application to update.
namestringThe name of the OAuth application.
redirectUris?string[] | null | undefinedAn array of redirect URIs for the OAuth application.
scopes?string[] | null | undefinedScopes for the OAuth application. Available scopes are profile, email, public_metadata, private_metadata. Defaults to profile email. Provide the requested scopes as a string, separated by spaces.
consentScreenEnabled?boolean | null | undefinedSpecifies whether the consent screen should be displayed in the authentication flow. Cannot be disabled for dynamically registered OAuth applications. Defaults to true.
public?boolean | null | undefinedIndicates whether the client is public. If true, the Proof Key of Code Exchange (PKCE) flow can be used. </Properties>
const oauthApplicationId = 'oauthapp_123'
const response = await clerkClient.oauthApplications.update({
oauthApplicationId: oauthApplicationId,
name: 'test',
redirectUris: [''],
scopes: 'profile email public_metadata private_metadata',
public: true,
})
This method in the SDK is a wrapper around the BAPI endpoint PATCH/oauth_applications/{oauth_application_id}. See the BAPI reference{{ target: '_blank' }} for more information.
ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā