Skip to content

Commit

Permalink
feat: allow use getClientToken on server
Browse files Browse the repository at this point in the history
- allow use node-fetch as fetcher prop on server
  • Loading branch information
Jerimo17 authored and kodiakhq[bot] committed Dec 15, 2022
1 parent 364ef34 commit 2a7a1bb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/getClientToken.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { DesktopIAPOptions, ClientFetcher } from "./types";
import { DesktopIAPOptions, ClientFetcher, Fetcher } from "./types";

const oauthTokenBaseUrl = new URL("https://www.googleapis.com/oauth2/v4/token");

export async function getClientToken(
options: DesktopIAPOptions,
refreshToken: string,
fetcher: ClientFetcher = fetch,
fetcher: ClientFetcher | Fetcher = fetch,
): Promise<string> {
const body = {
client_id: options.clientId,
Expand Down

0 comments on commit 2a7a1bb

Please sign in to comment.