From 1ce59ca06b26ec76eb2abdf05b88c6206ecd4400 Mon Sep 17 00:00:00 2001 From: Archit Date: Wed, 25 Mar 2026 17:30:11 +0700 Subject: [PATCH] chore: add source parameter to CustomAuth Made-with: Cursor --- src/login.ts | 2 ++ src/utils/interfaces.ts | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/src/login.ts b/src/login.ts index 21b6478a..a0176609 100644 --- a/src/login.ts +++ b/src/login.ts @@ -74,6 +74,7 @@ export class CustomAuth { serverTimeOffset = 0, nodeDetails, checkCommitment = true, + source = "customauth", }: CustomAuthArgs) { if (!web3AuthClientId) throw new Error("Please provide a valid web3AuthClientId in constructor"); if (!network) throw new Error("Please provide a valid network in constructor"); @@ -105,6 +106,7 @@ export class CustomAuth { legacyMetadataHost: metadataUrl, keyType, buildEnv, + source, }); Torus.setAPIKey(apiKey); this.torus = torus; diff --git a/src/utils/interfaces.ts b/src/utils/interfaces.ts index 859d8aac..f31bb39f 100644 --- a/src/utils/interfaces.ts +++ b/src/utils/interfaces.ts @@ -247,6 +247,12 @@ export interface CustomAuthArgs { * @defaultValue true */ checkCommitment?: boolean; + + /** + * Source of the login + * @defaultValue "customauth" + */ + source?: string; } export interface InitParams {