import { Turnkey } from "@turnkey/sdk-server";const turnkeyClient = new Turnkey({ apiBaseUrl: "https://api.turnkey.com", apiPublicKey: process.env.API_PUBLIC_KEY!, apiPrivateKey: process.env.API_PRIVATE_KEY!, defaultOrganizationId: process.env.ORGANIZATION_ID!,});const response = await turnkeyClient.apiClient().createOauthProviders({ userId: "<string> (The ID of the User to add an Oauth provider to)", oauthProviders: [{ // A list of Oauth providers., providerName: "<string> (Human-readable name to identify a Provider.)", oidcToken: "<string> (Base64 encoded OIDC token)", oidcClaims: { // oidcClaims field, iss: "<string> (The issuer identifier from the OIDC token (iss claim))", sub: "<string> (The subject identifier from the OIDC token (sub claim))", aud: "<string> (The audience from the OIDC token (aud claim))", }, }]});
import { Turnkey } from "@turnkey/sdk-server";const turnkeyClient = new Turnkey({ apiBaseUrl: "https://api.turnkey.com", apiPublicKey: process.env.API_PUBLIC_KEY!, apiPrivateKey: process.env.API_PRIVATE_KEY!, defaultOrganizationId: process.env.ORGANIZATION_ID!,});const response = await turnkeyClient.apiClient().createOauthProviders({ userId: "<string> (The ID of the User to add an Oauth provider to)", oauthProviders: [{ // A list of Oauth providers., providerName: "<string> (Human-readable name to identify a Provider.)", oidcToken: "<string> (Base64 encoded OIDC token)", oidcClaims: { // oidcClaims field, iss: "<string> (The issuer identifier from the OIDC token (iss claim))", sub: "<string> (The subject identifier from the OIDC token (sub claim))", aud: "<string> (The audience from the OIDC token (aud claim))", }, }]});