From 604def1235434c05a142715efe6c5830f2aac416 Mon Sep 17 00:00:00 2001 From: d-klotz Date: Tue, 10 Feb 2026 18:52:49 -0300 Subject: [PATCH 1/3] feat(zoho-auth): add prompt=consent to auth URI --- packages/v1-ready/zoho-crm/src/api.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/v1-ready/zoho-crm/src/api.ts b/packages/v1-ready/zoho-crm/src/api.ts index e4a8396..ce8469a 100644 --- a/packages/v1-ready/zoho-crm/src/api.ts +++ b/packages/v1-ready/zoho-crm/src/api.ts @@ -72,7 +72,7 @@ export class Api extends OAuth2Requester { this.baseUrl = `${locationConfig.api}/crm/v8`; this.tokenUri = `${locationConfig.accounts}/oauth/v2/token`; this.authorizationUri = encodeURI( - `${locationConfig.accounts}/oauth/v2/auth?scope=${this.scope}&client_id=${this.client_id}&redirect_uri=${this.redirect_uri}&response_type=code&access_type=offline` + `${locationConfig.accounts}/oauth/v2/auth?scope=${this.scope}&client_id=${this.client_id}&redirect_uri=${this.redirect_uri}&response_type=code&access_type=offline&prompt=consent` ); this.access_token = get(params, 'access_token', null); this.refresh_token = get(params, 'refresh_token', null); @@ -114,7 +114,7 @@ export class Api extends OAuth2Requester { this.baseUrl = `${locationConfig.api}/crm/v8`; this.tokenUri = `${locationConfig.accounts}/oauth/v2/token`; this.authorizationUri = encodeURI( - `${locationConfig.accounts}/oauth/v2/auth?scope=${this.scope}&client_id=${this.client_id}&redirect_uri=${this.redirect_uri}&response_type=code&access_type=offline` + `${locationConfig.accounts}/oauth/v2/auth?scope=${this.scope}&client_id=${this.client_id}&redirect_uri=${this.redirect_uri}&response_type=code&access_type=offline&prompt=consent` ); } From 188fcaefe52e3ab742fdfdc438d19988162836fc Mon Sep 17 00:00:00 2001 From: d-klotz Date: Tue, 10 Feb 2026 19:04:08 -0300 Subject: [PATCH 2/3] docs(zoho-crm): update ZOHO_CRM_SCOPE for additional permissions --- packages/v1-ready/zoho-crm/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/v1-ready/zoho-crm/README.md b/packages/v1-ready/zoho-crm/README.md index f33ef9d..bcd06e6 100644 --- a/packages/v1-ready/zoho-crm/README.md +++ b/packages/v1-ready/zoho-crm/README.md @@ -52,7 +52,7 @@ If you've already done this, skip to the next section. ```shell ZOHO_CRM_CLIENT_ID=your_client_id ZOHO_CRM_CLIENT_SECRET=your_client_secret - ZOHO_CRM_SCOPE=ZohoCRM.users.ALL ZohoCRM.org.ALL ZohoCRM.settings.roles.ALL ZohoCRM.settings.profiles.ALL ZohoCRM.modules.contacts.ALL ZohoCRM.modules.leads.ALL ZohoCRM.modules.accounts.ALL ZohoCRM.modules.calls.ALL + ZOHO_CRM_SCOPE=ZOHO_CRM_SCOPE=ZohoCRM.org.ALL ZohoCRM.users.ALL ZohoCRM.settings.roles.ALL ZohoCRM.settings.profiles.ALL ZohoCRM.modules.contacts.ALL ZohoCRM.modules.accounts.ALL ZohoCRM.modules.leads.ALL ZohoCRM.notifications.ALL ZohoCRM.modules.notes.ALL ZohoCRM.modules.calls.ALL REDIRECT_URI=http://localhost:3000/redirect ``` From f9c132288b21e6c3031b8f71e161bb4276076ee6 Mon Sep 17 00:00:00 2001 From: d-klotz Date: Tue, 10 Feb 2026 19:22:56 -0300 Subject: [PATCH 3/3] feat(zoho-auth): log token response for debugging --- packages/v1-ready/zoho-crm/src/api.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/v1-ready/zoho-crm/src/api.ts b/packages/v1-ready/zoho-crm/src/api.ts index ce8469a..aada8d7 100644 --- a/packages/v1-ready/zoho-crm/src/api.ts +++ b/packages/v1-ready/zoho-crm/src/api.ts @@ -133,6 +133,7 @@ export class Api extends OAuth2Requester { }; const response = await this._post(options, false); + console.log('[Zoho API] Token response:', JSON.stringify(response)); await this.setTokens(response); return response; }