@@ -11,10 +11,10 @@ const { logger } = require('~/config');
1111 */
1212const getAvailableIntegrations = async ( req , res ) => {
1313 const startTime = Date . now ( ) ;
14- logger . info ( '=== getAvailableIntegrations: Starting request ===' ) ;
14+ logger . debug ( '=== getAvailableIntegrations: Starting request ===' ) ;
1515
1616 try {
17- logger . info ( 'Calling PipedreamApps.getAvailableIntegrations()' ) ;
17+ logger . debug ( 'Calling PipedreamApps.getAvailableIntegrations()' ) ;
1818 const integrations = await PipedreamApps . getAvailableIntegrations ( ) ;
1919
2020 // Return the integrations array directly (not wrapped in response object)
@@ -42,8 +42,8 @@ const getUserIntegrations = async (req, res) => {
4242 const startTime = Date . now ( ) ;
4343 const userId = req . user ?. id ;
4444
45- logger . info ( '=== getUserIntegrations: Starting request ===' ) ;
46- logger . info ( `User ID: ${ userId } ` ) ;
45+ logger . debug ( '=== getUserIntegrations: Starting request ===' ) ;
46+ logger . debug ( `User ID: ${ userId } ` ) ;
4747
4848 try {
4949 if ( ! userId ) {
@@ -54,10 +54,10 @@ const getUserIntegrations = async (req, res) => {
5454 } ) ;
5555 }
5656
57- logger . info ( `Calling PipedreamUserIntegrations.getUserIntegrations(${ userId } )` ) ;
57+ logger . debug ( `Calling PipedreamUserIntegrations.getUserIntegrations(${ userId } )` ) ;
5858 const integrations = await PipedreamUserIntegrations . getUserIntegrations ( userId ) ;
5959
60- logger . info ( `Retrieved ${ integrations ?. length || 0 } user integrations` ) ;
60+ logger . debug ( `Retrieved ${ integrations ?. length || 0 } user integrations` ) ;
6161 if ( integrations ?. length > 0 ) {
6262 logger . info (
6363 'User integrations summary:' ,
@@ -71,7 +71,7 @@ const getUserIntegrations = async (req, res) => {
7171 ) ;
7272 }
7373
74- logger . info ( `getUserIntegrations completed in ${ Date . now ( ) - startTime } ms` ) ;
74+ logger . debug ( `getUserIntegrations completed in ${ Date . now ( ) - startTime } ms` ) ;
7575
7676 // Return the integrations array directly (not wrapped in response object)
7777 res . json ( integrations ) ;
@@ -99,9 +99,9 @@ const createConnectToken = async (req, res) => {
9999 const startTime = Date . now ( ) ;
100100 const userId = req . user ?. id ;
101101
102- logger . info ( '=== createConnectToken: Starting request ===' ) ;
103- logger . info ( `User ID: ${ userId } ` ) ;
104- logger . info ( 'Request body:' , req . body ) ;
102+ logger . debug ( '=== createConnectToken: Starting request ===' ) ;
103+ logger . debug ( `User ID: ${ userId } ` ) ;
104+ logger . debug ( 'Request body:' , req . body ) ;
105105
106106 try {
107107 if ( ! userId ) {
@@ -159,8 +159,8 @@ const createConnectToken = async (req, res) => {
159159const handleConnectionCallback = async ( req , res ) => {
160160 const startTime = Date . now ( ) ;
161161
162- logger . info ( '=== handleConnectionCallback: Starting request ===' ) ;
163- logger . info ( 'Request body:' , req . body ) ;
162+ logger . debug ( '=== handleConnectionCallback: Starting request ===' ) ;
163+ logger . debug ( 'Request body:' , req . body ) ;
164164
165165 try {
166166 const { account_id, external_user_id, app } = req . body ;
@@ -225,8 +225,8 @@ const deleteIntegration = async (req, res) => {
225225 const userId = req . user ?. id ;
226226 const { integrationId } = req . params ;
227227
228- logger . info ( '=== deleteIntegration: Starting request ===' ) ;
229- logger . info ( `User ID: ${ userId } , Integration ID: ${ integrationId } ` ) ;
228+ logger . debug ( '=== deleteIntegration: Starting request ===' ) ;
229+ logger . debug ( `User ID: ${ userId } , Integration ID: ${ integrationId } ` ) ;
230230
231231 try {
232232 if ( ! userId ) {
@@ -282,8 +282,8 @@ const getMCPConfig = async (req, res) => {
282282 const startTime = Date . now ( ) ;
283283 const userId = req . user ?. id ;
284284
285- logger . info ( '=== getMCPConfig: Starting request ===' ) ;
286- logger . info ( `User ID: ${ userId } ` ) ;
285+ logger . debug ( '=== getMCPConfig: Starting request ===' ) ;
286+ logger . debug ( `User ID: ${ userId } ` ) ;
287287
288288 try {
289289 if ( ! userId ) {
@@ -331,12 +331,12 @@ const getMCPConfig = async (req, res) => {
331331const getIntegrationStatus = async ( req , res ) => {
332332 const startTime = Date . now ( ) ;
333333
334- logger . info ( '=== getIntegrationStatus: Starting request ===' ) ;
334+ logger . debug ( '=== getIntegrationStatus: Starting request ===' ) ;
335335
336336 try {
337337 const isEnabled = PipedreamConnect . isEnabled ( ) ;
338338
339- logger . info ( 'Integration status check:' , {
339+ logger . debug ( 'Integration status check:' , {
340340 enabled : isEnabled ,
341341 nodeEnv : process . env . NODE_ENV ,
342342 pipedreamEnabled : process . env . ENABLE_PIPEDREAM_INTEGRATION ,
@@ -354,7 +354,7 @@ const getIntegrationStatus = async (req, res) => {
354354 } ,
355355 } ;
356356
357- logger . info ( `getIntegrationStatus completed in ${ Date . now ( ) - startTime } ms` ) ;
357+ logger . debug ( `getIntegrationStatus completed in ${ Date . now ( ) - startTime } ms` ) ;
358358 res . json ( response ) ;
359359 } catch ( error ) {
360360 logger . error ( '=== getIntegrationStatus: Error occurred ===' ) ;
@@ -380,8 +380,8 @@ const getAppDetails = async (req, res) => {
380380 const userId = req . user ?. id ;
381381 const { appSlug } = req . params ;
382382
383- logger . info ( '=== getAppDetails: Starting request ===' ) ;
384- logger . info ( `User ID: ${ userId } , App Slug: ${ appSlug } ` ) ;
383+ logger . debug ( '=== getAppDetails: Starting request ===' ) ;
384+ logger . debug ( `User ID: ${ userId } , App Slug: ${ appSlug } ` ) ;
385385
386386 try {
387387 if ( ! userId ) {
@@ -400,24 +400,24 @@ const getAppDetails = async (req, res) => {
400400 } ) ;
401401 }
402402
403- logger . info ( `Calling PipedreamApps.getAppDetails(${ appSlug } )` ) ;
403+ logger . debug ( `Calling PipedreamApps.getAppDetails(${ appSlug } )` ) ;
404404 const appDetails = await PipedreamApps . getAppDetails ( appSlug ) ;
405405
406406 // Enhanced logging to inspect the appDetails object structure
407- logger . info (
407+ logger . debug (
408408 `AppDetails object received from service for ${ appSlug } :` ,
409409 JSON . stringify ( appDetails , null , 2 ) ,
410410 ) ;
411411 if ( appDetails ) {
412- logger . info (
412+ logger . debug (
413413 `Fields in appDetails for ${ appSlug } : id: ${ ! ! appDetails . id } , name_slug: ${ ! ! appDetails . name_slug } , name: ${ ! ! appDetails . name } , img_src: ${ ! ! appDetails . img_src } ` ,
414414 ) ;
415415 } else {
416416 logger . warn ( `appDetails object from service is null or undefined for ${ appSlug } ` ) ;
417417 }
418418
419- logger . info ( `Retrieved app details for ${ appSlug } ` ) ;
420- logger . info ( `getAppDetails completed in ${ Date . now ( ) - startTime } ms` ) ;
419+ logger . debug ( `Retrieved app details for ${ appSlug } ` ) ;
420+ logger . debug ( `getAppDetails completed in ${ Date . now ( ) - startTime } ms` ) ;
421421
422422 res . json ( {
423423 success : true ,
@@ -450,8 +450,8 @@ const getAppComponents = async (req, res) => {
450450 const { appSlug } = req . params ;
451451 const { type } = req . query ; // 'actions', 'triggers', or undefined for both
452452
453- logger . info ( '=== getAppComponents: Starting request ===' ) ;
454- logger . info ( `User ID: ${ userId } , App Slug: ${ appSlug } , Type: ${ type } ` ) ;
453+ logger . debug ( '=== getAppComponents: Starting request ===' ) ;
454+ logger . debug ( `User ID: ${ userId } , App Slug: ${ appSlug } , Type: ${ type } ` ) ;
455455
456456 try {
457457 if ( ! userId ) {
@@ -470,10 +470,10 @@ const getAppComponents = async (req, res) => {
470470 } ) ;
471471 }
472472
473- logger . info ( `Calling PipedreamComponents.getAppComponents(${ appSlug } , ${ type } )` ) ;
473+ logger . debug ( `Calling PipedreamComponents.getAppComponents(${ appSlug } , ${ type } )` ) ;
474474 const components = await PipedreamComponents . getAppComponents ( appSlug , type ) ;
475475
476- logger . info (
476+ logger . debug (
477477 `Retrieved ${ components ?. actions ?. length || 0 } actions and ${ components ?. triggers ?. length || 0 } triggers for ${ appSlug } ` ,
478478 ) ;
479479 logger . info ( `getAppComponents completed in ${ Date . now ( ) - startTime } ms` ) ;
@@ -508,9 +508,9 @@ const configureComponent = async (req, res) => {
508508 const startTime = Date . now ( ) ;
509509 const userId = req . user ?. id ;
510510
511- logger . info ( '=== configureComponent: Starting request ===' ) ;
512- logger . info ( `User ID: ${ userId } ` ) ;
513- logger . info ( 'Request body:' , req . body ) ;
511+ logger . debug ( '=== configureComponent: Starting request ===' ) ;
512+ logger . debug ( `User ID: ${ userId } ` ) ;
513+ logger . debug ( 'Request body:' , req . body ) ;
514514
515515 try {
516516 if ( ! userId ) {
@@ -539,8 +539,8 @@ const configureComponent = async (req, res) => {
539539 dynamicPropsId,
540540 } ) ;
541541
542- logger . info ( 'Component configured successfully' ) ;
543- logger . info ( `configureComponent completed in ${ Date . now ( ) - startTime } ms` ) ;
542+ logger . debug ( 'Component configured successfully' ) ;
543+ logger . debug ( `configureComponent completed in ${ Date . now ( ) - startTime } ms` ) ;
544544
545545 res . json ( {
546546 success : true ,
@@ -571,9 +571,9 @@ const runAction = async (req, res) => {
571571 const startTime = Date . now ( ) ;
572572 const userId = req . user ?. id ;
573573
574- logger . info ( '=== runAction: Starting request ===' ) ;
575- logger . info ( `User ID: ${ userId } ` ) ;
576- logger . info ( 'Request body:' , req . body ) ;
574+ logger . debug ( '=== runAction: Starting request ===' ) ;
575+ logger . debug ( `User ID: ${ userId } ` ) ;
576+ logger . debug ( 'Request body:' , req . body ) ;
577577
578578 try {
579579 if ( ! userId ) {
@@ -633,9 +633,9 @@ const deployTrigger = async (req, res) => {
633633 const startTime = Date . now ( ) ;
634634 const userId = req . user ?. id ;
635635
636- logger . info ( '=== deployTrigger: Starting request ===' ) ;
637- logger . info ( `User ID: ${ userId } ` ) ;
638- logger . info ( 'Request body:' , req . body ) ;
636+ logger . debug ( '=== deployTrigger: Starting request ===' ) ;
637+ logger . debug ( `User ID: ${ userId } ` ) ;
638+ logger . debug ( 'Request body:' , req . body ) ;
639639
640640 try {
641641 if ( ! userId ) {
@@ -664,7 +664,7 @@ const deployTrigger = async (req, res) => {
664664 } ) ;
665665 }
666666
667- logger . info ( `Calling PipedreamComponents.deployTrigger` ) ;
667+ logger . debug ( `Calling PipedreamComponents.deployTrigger` ) ;
668668 const deployment = await PipedreamComponents . deployTrigger ( userId , {
669669 componentId,
670670 configuredProps,
@@ -673,8 +673,8 @@ const deployTrigger = async (req, res) => {
673673 dynamicPropsId,
674674 } ) ;
675675
676- logger . info ( 'Trigger deployed successfully' ) ;
677- logger . info ( `deployTrigger completed in ${ Date . now ( ) - startTime } ms` ) ;
676+ logger . debug ( 'Trigger deployed successfully' ) ;
677+ logger . debug ( `deployTrigger completed in ${ Date . now ( ) - startTime } ms` ) ;
678678
679679 res . json ( {
680680 success : true ,
0 commit comments