Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/oura_api/src/utilsOAuth.ts>generateAuthUrl

Typescript project to interact with v2 of the Oura Ring API
Latest
function generateAuthUrl
import { generateAuthUrl } from "https://deno.land/x/oura_api@1.0.1/src/utilsOAuth.ts";

Generates the authorization URL for the Oura P.OAuth2 flow.

Parameters

clientId: string
  • Your Oura API client ID.
scopes: string[]
  • An array of scopes to request access to (e.g., ['email', 'daily']).
optional
redirectUri: string
  • The redirect URI where Oura will send the user after authorization.
optional
state: string
  • An optional state parameter for security and session management.

Returns

string

The authorization URL.