diff --git a/src/modules/integrations/screens/ZohoAuth.tsx b/src/modules/integrations/screens/ZohoAuth.tsx index 2ee17e2..ad6c379 100644 --- a/src/modules/integrations/screens/ZohoAuth.tsx +++ b/src/modules/integrations/screens/ZohoAuth.tsx @@ -73,6 +73,10 @@ const getScopeForService = (_serviceKey?: ServiceKey): string => { 'ZohoCRM.modules.READ', //settings 'ZohoCRM.settings.READ', + //crm bulk read scope + 'ZohoCRM.bulk.READ', + //notification access + 'ZohoCRM.notifications.ALL', // Zoho Books (use granular scopes if preferred instead of FullAccess) 'ZohoBooks.FullAccess.READ', // Zoho People @@ -171,8 +175,8 @@ const ZohoAuth: React.FC = ({ // Backend exchange mode: only log and return the authorization code to the caller const handleAuthorizationCode = useCallback(async (authCode: string) => { console.log('[ZohoAuth] Authorization code received:', authCode); - console.log('[ZohoAuth] Send this code to your backend to exchange for tokens.'); - const response = await manageToken.manageToken({ authorization_code: authCode, id: user?.id, service_name: 'zoho', access_token: accessToken }); + console.log('[ZohoAuth] Send this code to your backend to exchange for tokens.',user); + const response = await manageToken.manageToken({ authorization_code: authCode, id: user?.uuid, service_name: 'zoho', access_token: accessToken }); console.log('[ZohoAuth] Response from manageToken:', response); // Return the code via onAuthSuccess using the existing shape onAuthSuccess?.({ diff --git a/src/services/http.ts b/src/services/http.ts index 26b9cde..5da2b8b 100644 --- a/src/services/http.ts +++ b/src/services/http.ts @@ -8,8 +8,8 @@ import { clearSelectedService } from '@/modules/integrations/store/integrationsS let pendingRequest: any = null; const http = create({ - // baseURL: 'http://192.168.1.24:4000', - baseURL: 'http://160.187.167.216', + baseURL: 'http://192.168.1.23:4000', + // baseURL: 'http://160.187.167.216', timeout: 10000, });