integrate-sdk 0.8.30-dev.0 → 0.8.31-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/dist/adapters/auto-routes.js +435 -0
  2. package/dist/adapters/index.js +435 -0
  3. package/dist/adapters/nextjs.js +435 -0
  4. package/dist/adapters/node.js +435 -0
  5. package/dist/adapters/svelte-kit.js +435 -0
  6. package/dist/adapters/tanstack-start.js +435 -0
  7. package/dist/index.js +455 -0
  8. package/dist/oauth.js +435 -0
  9. package/dist/server.js +445 -0
  10. package/dist/src/client.d.ts +11 -1
  11. package/dist/src/client.d.ts.map +1 -1
  12. package/dist/src/index.d.ts +20 -0
  13. package/dist/src/index.d.ts.map +1 -1
  14. package/dist/src/integrations/calcom-client.d.ts +355 -0
  15. package/dist/src/integrations/calcom-client.d.ts.map +1 -0
  16. package/dist/src/integrations/calcom.d.ts +39 -0
  17. package/dist/src/integrations/calcom.d.ts.map +1 -0
  18. package/dist/src/integrations/figma-client.d.ts +327 -0
  19. package/dist/src/integrations/figma-client.d.ts.map +1 -0
  20. package/dist/src/integrations/figma.d.ts +37 -0
  21. package/dist/src/integrations/figma.d.ts.map +1 -0
  22. package/dist/src/integrations/gworkspace-client.d.ts +392 -0
  23. package/dist/src/integrations/gworkspace-client.d.ts.map +1 -0
  24. package/dist/src/integrations/gworkspace.d.ts +37 -0
  25. package/dist/src/integrations/gworkspace.d.ts.map +1 -0
  26. package/dist/src/integrations/hubspot-client.d.ts +367 -0
  27. package/dist/src/integrations/hubspot-client.d.ts.map +1 -0
  28. package/dist/src/integrations/hubspot.d.ts +37 -0
  29. package/dist/src/integrations/hubspot.d.ts.map +1 -0
  30. package/dist/src/integrations/intercom-client.d.ts +414 -0
  31. package/dist/src/integrations/intercom-client.d.ts.map +1 -0
  32. package/dist/src/integrations/intercom.d.ts +37 -0
  33. package/dist/src/integrations/intercom.d.ts.map +1 -0
  34. package/dist/src/integrations/onedrive-client.d.ts +338 -0
  35. package/dist/src/integrations/onedrive-client.d.ts.map +1 -0
  36. package/dist/src/integrations/onedrive.d.ts +37 -0
  37. package/dist/src/integrations/onedrive.d.ts.map +1 -0
  38. package/dist/src/integrations/polar-client.d.ts +297 -0
  39. package/dist/src/integrations/polar-client.d.ts.map +1 -0
  40. package/dist/src/integrations/polar.d.ts +39 -0
  41. package/dist/src/integrations/polar.d.ts.map +1 -0
  42. package/dist/src/integrations/ramp-client.d.ts +341 -0
  43. package/dist/src/integrations/ramp-client.d.ts.map +1 -0
  44. package/dist/src/integrations/ramp.d.ts +39 -0
  45. package/dist/src/integrations/ramp.d.ts.map +1 -0
  46. package/dist/src/integrations/whatsapp-client.d.ts +320 -0
  47. package/dist/src/integrations/whatsapp-client.d.ts.map +1 -0
  48. package/dist/src/integrations/whatsapp.d.ts +39 -0
  49. package/dist/src/integrations/whatsapp.d.ts.map +1 -0
  50. package/dist/src/integrations/youtube-client.d.ts +459 -0
  51. package/dist/src/integrations/youtube-client.d.ts.map +1 -0
  52. package/dist/src/integrations/youtube.d.ts +37 -0
  53. package/dist/src/integrations/youtube.d.ts.map +1 -0
  54. package/dist/src/server.d.ts +10 -0
  55. package/dist/src/server.d.ts.map +1 -1
  56. package/package.json +1 -1
package/dist/oauth.js CHANGED
@@ -2882,6 +2882,421 @@ var init_todoist = __esm(() => {
2882
2882
  ];
2883
2883
  });
2884
2884
 
2885
+ // src/integrations/whatsapp.ts
2886
+ function whatsappIntegration(config = {}) {
2887
+ const oauth = {
2888
+ provider: "whatsapp",
2889
+ clientId: config.clientId ?? getEnv("WHATSAPP_CLIENT_ID"),
2890
+ clientSecret: config.clientSecret ?? getEnv("WHATSAPP_CLIENT_SECRET"),
2891
+ scopes: config.scopes || ["business_management", "whatsapp_business_messaging", "whatsapp_business_management"],
2892
+ redirectUri: config.redirectUri,
2893
+ config: {
2894
+ businessAccountId: config.businessAccountId,
2895
+ ...config
2896
+ }
2897
+ };
2898
+ return {
2899
+ id: "whatsapp",
2900
+ tools: [...WHATSAPP_TOOLS],
2901
+ oauth,
2902
+ async onInit(_client) {
2903
+ console.log("WhatsApp Business integration initialized");
2904
+ },
2905
+ async onAfterConnect(_client) {
2906
+ console.log("WhatsApp Business integration connected");
2907
+ }
2908
+ };
2909
+ }
2910
+ var WHATSAPP_TOOLS;
2911
+ var init_whatsapp = __esm(() => {
2912
+ WHATSAPP_TOOLS = [
2913
+ "whatsapp_send_message",
2914
+ "whatsapp_send_template",
2915
+ "whatsapp_send_media",
2916
+ "whatsapp_list_templates",
2917
+ "whatsapp_get_phone_numbers",
2918
+ "whatsapp_get_message_status",
2919
+ "whatsapp_mark_read",
2920
+ "whatsapp_get_profile"
2921
+ ];
2922
+ });
2923
+
2924
+ // src/integrations/calcom.ts
2925
+ function calcomIntegration(config = {}) {
2926
+ const oauth = {
2927
+ provider: "calcom",
2928
+ clientId: config.clientId ?? getEnv("CALCOM_CLIENT_ID"),
2929
+ clientSecret: config.clientSecret ?? getEnv("CALCOM_CLIENT_SECRET"),
2930
+ scopes: config.scopes || ["read:bookings", "write:bookings", "read:event-types", "read:schedules"],
2931
+ redirectUri: config.redirectUri,
2932
+ config: {
2933
+ apiBaseUrl: config.apiBaseUrl || "https://api.cal.com/v1",
2934
+ ...config
2935
+ }
2936
+ };
2937
+ return {
2938
+ id: "calcom",
2939
+ tools: [...CALCOM_TOOLS],
2940
+ oauth,
2941
+ async onInit(_client) {
2942
+ console.log("Cal.com integration initialized");
2943
+ },
2944
+ async onAfterConnect(_client) {
2945
+ console.log("Cal.com integration connected");
2946
+ }
2947
+ };
2948
+ }
2949
+ var CALCOM_TOOLS;
2950
+ var init_calcom = __esm(() => {
2951
+ CALCOM_TOOLS = [
2952
+ "calcom_list_bookings",
2953
+ "calcom_get_booking",
2954
+ "calcom_create_booking",
2955
+ "calcom_cancel_booking",
2956
+ "calcom_reschedule_booking",
2957
+ "calcom_list_event_types",
2958
+ "calcom_get_availability",
2959
+ "calcom_list_schedules",
2960
+ "calcom_get_me"
2961
+ ];
2962
+ });
2963
+
2964
+ // src/integrations/ramp.ts
2965
+ function rampIntegration(config = {}) {
2966
+ const oauth = {
2967
+ provider: "ramp",
2968
+ clientId: config.clientId ?? getEnv("RAMP_CLIENT_ID"),
2969
+ clientSecret: config.clientSecret ?? getEnv("RAMP_CLIENT_SECRET"),
2970
+ scopes: config.scopes || ["transactions:read", "cards:read", "users:read"],
2971
+ redirectUri: config.redirectUri,
2972
+ config: {
2973
+ apiBaseUrl: config.apiBaseUrl || "https://api.ramp.com/v1",
2974
+ ...config
2975
+ }
2976
+ };
2977
+ return {
2978
+ id: "ramp",
2979
+ tools: [...RAMP_TOOLS],
2980
+ oauth,
2981
+ async onInit(_client) {
2982
+ console.log("Ramp integration initialized");
2983
+ },
2984
+ async onAfterConnect(_client) {
2985
+ console.log("Ramp integration connected");
2986
+ }
2987
+ };
2988
+ }
2989
+ var RAMP_TOOLS;
2990
+ var init_ramp = __esm(() => {
2991
+ RAMP_TOOLS = [
2992
+ "ramp_list_transactions",
2993
+ "ramp_get_transaction",
2994
+ "ramp_list_cards",
2995
+ "ramp_get_card",
2996
+ "ramp_list_users",
2997
+ "ramp_get_user",
2998
+ "ramp_list_departments",
2999
+ "ramp_list_reimbursements",
3000
+ "ramp_get_spend_limits"
3001
+ ];
3002
+ });
3003
+
3004
+ // src/integrations/onedrive.ts
3005
+ function onedriveIntegration(config = {}) {
3006
+ const oauth = {
3007
+ provider: "onedrive",
3008
+ clientId: config.clientId ?? getEnv("ONEDRIVE_CLIENT_ID"),
3009
+ clientSecret: config.clientSecret ?? getEnv("ONEDRIVE_CLIENT_SECRET"),
3010
+ scopes: config.scopes || ["Files.Read", "Files.ReadWrite", "offline_access"],
3011
+ redirectUri: config.redirectUri,
3012
+ config: {
3013
+ ...config
3014
+ }
3015
+ };
3016
+ return {
3017
+ id: "onedrive",
3018
+ tools: [...ONEDRIVE_TOOLS],
3019
+ oauth,
3020
+ async onInit(_client) {
3021
+ console.log("OneDrive integration initialized");
3022
+ },
3023
+ async onAfterConnect(_client) {
3024
+ console.log("OneDrive integration connected");
3025
+ }
3026
+ };
3027
+ }
3028
+ var ONEDRIVE_TOOLS;
3029
+ var init_onedrive = __esm(() => {
3030
+ ONEDRIVE_TOOLS = [
3031
+ "onedrive_list_files",
3032
+ "onedrive_get_file",
3033
+ "onedrive_download_file",
3034
+ "onedrive_upload_file",
3035
+ "onedrive_delete_file",
3036
+ "onedrive_search_files",
3037
+ "onedrive_share_file",
3038
+ "onedrive_word_get_content",
3039
+ "onedrive_excel_get_worksheets",
3040
+ "onedrive_excel_get_range",
3041
+ "onedrive_excel_update_range",
3042
+ "onedrive_powerpoint_get_slides"
3043
+ ];
3044
+ });
3045
+
3046
+ // src/integrations/gworkspace.ts
3047
+ function gworkspaceIntegration(config = {}) {
3048
+ const oauth = {
3049
+ provider: "gworkspace",
3050
+ clientId: config.clientId ?? getEnv("GWORKSPACE_CLIENT_ID"),
3051
+ clientSecret: config.clientSecret ?? getEnv("GWORKSPACE_CLIENT_SECRET"),
3052
+ scopes: config.scopes || [
3053
+ "https://www.googleapis.com/auth/spreadsheets",
3054
+ "https://www.googleapis.com/auth/documents",
3055
+ "https://www.googleapis.com/auth/presentations",
3056
+ "https://www.googleapis.com/auth/drive.readonly"
3057
+ ],
3058
+ redirectUri: config.redirectUri,
3059
+ config: {
3060
+ ...config
3061
+ }
3062
+ };
3063
+ return {
3064
+ id: "gworkspace",
3065
+ tools: [...GWORKSPACE_TOOLS],
3066
+ oauth,
3067
+ async onInit(_client) {
3068
+ console.log("Google Workspace integration initialized");
3069
+ },
3070
+ async onAfterConnect(_client) {
3071
+ console.log("Google Workspace integration connected");
3072
+ }
3073
+ };
3074
+ }
3075
+ var GWORKSPACE_TOOLS;
3076
+ var init_gworkspace = __esm(() => {
3077
+ GWORKSPACE_TOOLS = [
3078
+ "gworkspace_sheets_list",
3079
+ "gworkspace_sheets_get",
3080
+ "gworkspace_sheets_get_values",
3081
+ "gworkspace_sheets_update_values",
3082
+ "gworkspace_sheets_create",
3083
+ "gworkspace_docs_list",
3084
+ "gworkspace_docs_get",
3085
+ "gworkspace_docs_create",
3086
+ "gworkspace_slides_list",
3087
+ "gworkspace_slides_get",
3088
+ "gworkspace_slides_get_page",
3089
+ "gworkspace_slides_create"
3090
+ ];
3091
+ });
3092
+
3093
+ // src/integrations/polar.ts
3094
+ function polarIntegration(config = {}) {
3095
+ const oauth = {
3096
+ provider: "polar",
3097
+ clientId: config.clientId ?? getEnv("POLAR_CLIENT_ID"),
3098
+ clientSecret: config.clientSecret ?? getEnv("POLAR_CLIENT_SECRET"),
3099
+ scopes: config.scopes || ["products:read", "subscriptions:read", "customers:read", "orders:read", "benefits:read"],
3100
+ redirectUri: config.redirectUri,
3101
+ config: {
3102
+ apiBaseUrl: config.apiBaseUrl || "https://api.polar.sh",
3103
+ ...config
3104
+ }
3105
+ };
3106
+ return {
3107
+ id: "polar",
3108
+ tools: [...POLAR_TOOLS],
3109
+ oauth,
3110
+ async onInit(_client) {
3111
+ console.log("Polar integration initialized");
3112
+ },
3113
+ async onAfterConnect(_client) {
3114
+ console.log("Polar integration connected");
3115
+ }
3116
+ };
3117
+ }
3118
+ var POLAR_TOOLS;
3119
+ var init_polar = __esm(() => {
3120
+ POLAR_TOOLS = [
3121
+ "polar_list_products",
3122
+ "polar_get_product",
3123
+ "polar_list_subscriptions",
3124
+ "polar_get_subscription",
3125
+ "polar_list_customers",
3126
+ "polar_get_customer",
3127
+ "polar_list_orders",
3128
+ "polar_get_order",
3129
+ "polar_list_benefits"
3130
+ ];
3131
+ });
3132
+
3133
+ // src/integrations/figma.ts
3134
+ function figmaIntegration(config = {}) {
3135
+ const oauth = {
3136
+ provider: "figma",
3137
+ clientId: config.clientId ?? getEnv("FIGMA_CLIENT_ID"),
3138
+ clientSecret: config.clientSecret ?? getEnv("FIGMA_CLIENT_SECRET"),
3139
+ scopes: config.scopes || ["files:read", "file_comments:write"],
3140
+ redirectUri: config.redirectUri,
3141
+ config: {
3142
+ ...config
3143
+ }
3144
+ };
3145
+ return {
3146
+ id: "figma",
3147
+ tools: [...FIGMA_TOOLS],
3148
+ oauth,
3149
+ async onInit(_client) {
3150
+ console.log("Figma integration initialized");
3151
+ },
3152
+ async onAfterConnect(_client) {
3153
+ console.log("Figma integration connected");
3154
+ }
3155
+ };
3156
+ }
3157
+ var FIGMA_TOOLS;
3158
+ var init_figma = __esm(() => {
3159
+ FIGMA_TOOLS = [
3160
+ "figma_get_file",
3161
+ "figma_get_file_nodes",
3162
+ "figma_get_images",
3163
+ "figma_get_comments",
3164
+ "figma_post_comment",
3165
+ "figma_list_projects",
3166
+ "figma_get_project_files",
3167
+ "figma_get_file_versions",
3168
+ "figma_get_team_components"
3169
+ ];
3170
+ });
3171
+
3172
+ // src/integrations/intercom.ts
3173
+ function intercomIntegration(config = {}) {
3174
+ const oauth = {
3175
+ provider: "intercom",
3176
+ clientId: config.clientId ?? getEnv("INTERCOM_CLIENT_ID"),
3177
+ clientSecret: config.clientSecret ?? getEnv("INTERCOM_CLIENT_SECRET"),
3178
+ scopes: config.scopes || [],
3179
+ redirectUri: config.redirectUri,
3180
+ config: {
3181
+ ...config
3182
+ }
3183
+ };
3184
+ return {
3185
+ id: "intercom",
3186
+ tools: [...INTERCOM_TOOLS],
3187
+ oauth,
3188
+ async onInit(_client) {
3189
+ console.log("Intercom integration initialized");
3190
+ },
3191
+ async onAfterConnect(_client) {
3192
+ console.log("Intercom integration connected");
3193
+ }
3194
+ };
3195
+ }
3196
+ var INTERCOM_TOOLS;
3197
+ var init_intercom = __esm(() => {
3198
+ INTERCOM_TOOLS = [
3199
+ "intercom_list_contacts",
3200
+ "intercom_get_contact",
3201
+ "intercom_create_contact",
3202
+ "intercom_list_conversations",
3203
+ "intercom_get_conversation",
3204
+ "intercom_reply_conversation",
3205
+ "intercom_list_companies",
3206
+ "intercom_get_company",
3207
+ "intercom_search_contacts"
3208
+ ];
3209
+ });
3210
+
3211
+ // src/integrations/hubspot.ts
3212
+ function hubspotIntegration(config = {}) {
3213
+ const oauth = {
3214
+ provider: "hubspot",
3215
+ clientId: config.clientId ?? getEnv("HUBSPOT_CLIENT_ID"),
3216
+ clientSecret: config.clientSecret ?? getEnv("HUBSPOT_CLIENT_SECRET"),
3217
+ scopes: config.scopes || [
3218
+ "crm.objects.contacts.read",
3219
+ "crm.objects.contacts.write",
3220
+ "crm.objects.companies.read",
3221
+ "crm.objects.companies.write",
3222
+ "crm.objects.deals.read",
3223
+ "crm.objects.deals.write",
3224
+ "tickets"
3225
+ ],
3226
+ redirectUri: config.redirectUri,
3227
+ config: {
3228
+ ...config
3229
+ }
3230
+ };
3231
+ return {
3232
+ id: "hubspot",
3233
+ tools: [...HUBSPOT_TOOLS],
3234
+ oauth,
3235
+ async onInit(_client) {
3236
+ console.log("HubSpot integration initialized");
3237
+ },
3238
+ async onAfterConnect(_client) {
3239
+ console.log("HubSpot integration connected");
3240
+ }
3241
+ };
3242
+ }
3243
+ var HUBSPOT_TOOLS;
3244
+ var init_hubspot = __esm(() => {
3245
+ HUBSPOT_TOOLS = [
3246
+ "hubspot_list_contacts",
3247
+ "hubspot_get_contact",
3248
+ "hubspot_create_contact",
3249
+ "hubspot_update_contact",
3250
+ "hubspot_list_companies",
3251
+ "hubspot_get_company",
3252
+ "hubspot_create_company",
3253
+ "hubspot_list_deals",
3254
+ "hubspot_get_deal",
3255
+ "hubspot_create_deal",
3256
+ "hubspot_list_tickets",
3257
+ "hubspot_get_ticket"
3258
+ ];
3259
+ });
3260
+
3261
+ // src/integrations/youtube.ts
3262
+ function youtubeIntegration(config = {}) {
3263
+ const oauth = {
3264
+ provider: "youtube",
3265
+ clientId: config.clientId ?? getEnv("YOUTUBE_CLIENT_ID"),
3266
+ clientSecret: config.clientSecret ?? getEnv("YOUTUBE_CLIENT_SECRET"),
3267
+ scopes: config.scopes || ["https://www.googleapis.com/auth/youtube.readonly"],
3268
+ redirectUri: config.redirectUri,
3269
+ config: {
3270
+ ...config
3271
+ }
3272
+ };
3273
+ return {
3274
+ id: "youtube",
3275
+ tools: [...YOUTUBE_TOOLS],
3276
+ oauth,
3277
+ async onInit(_client) {
3278
+ console.log("YouTube integration initialized");
3279
+ },
3280
+ async onAfterConnect(_client) {
3281
+ console.log("YouTube integration connected");
3282
+ }
3283
+ };
3284
+ }
3285
+ var YOUTUBE_TOOLS;
3286
+ var init_youtube = __esm(() => {
3287
+ YOUTUBE_TOOLS = [
3288
+ "youtube_search",
3289
+ "youtube_get_video",
3290
+ "youtube_list_playlists",
3291
+ "youtube_get_playlist",
3292
+ "youtube_list_playlist_items",
3293
+ "youtube_get_channel",
3294
+ "youtube_list_subscriptions",
3295
+ "youtube_list_comments",
3296
+ "youtube_get_captions"
3297
+ ];
3298
+ });
3299
+
2885
3300
  // src/integrations/generic.ts
2886
3301
  function genericOAuthIntegration(config) {
2887
3302
  const providerUpper = config.provider.toUpperCase().replace(/[^A-Z0-9]/g, "_");
@@ -7380,6 +7795,8 @@ var init_ai = __esm(() => {
7380
7795
  var exports_server = {};
7381
7796
  __export(exports_server, {
7382
7797
  zendeskIntegration: () => zendeskIntegration,
7798
+ youtubeIntegration: () => youtubeIntegration,
7799
+ whatsappIntegration: () => whatsappIntegration,
7383
7800
  vercelIntegration: () => vercelIntegration,
7384
7801
  todoistIntegration: () => todoistIntegration,
7385
7802
  toSvelteKitHandler: () => toSvelteKitHandler,
@@ -7388,11 +7805,17 @@ __export(exports_server, {
7388
7805
  stripeIntegration: () => stripeIntegration,
7389
7806
  storeCodeVerifier: () => storeCodeVerifier,
7390
7807
  slackIntegration: () => slackIntegration,
7808
+ rampIntegration: () => rampIntegration,
7809
+ polarIntegration: () => polarIntegration,
7391
7810
  outlookIntegration: () => outlookIntegration,
7811
+ onedriveIntegration: () => onedriveIntegration,
7392
7812
  notionIntegration: () => notionIntegration,
7393
7813
  linearIntegration: () => linearIntegration,
7814
+ intercomIntegration: () => intercomIntegration,
7815
+ hubspotIntegration: () => hubspotIntegration,
7394
7816
  handleOpenAIResponse: () => handleOpenAIResponse,
7395
7817
  handleAnthropicMessage: () => handleAnthropicMessage,
7818
+ gworkspaceIntegration: () => gworkspaceIntegration,
7396
7819
  gmailIntegration: () => gmailIntegration,
7397
7820
  githubIntegration: () => githubIntegration,
7398
7821
  getVercelAITools: () => getVercelAITools,
@@ -7402,9 +7825,11 @@ __export(exports_server, {
7402
7825
  getAnthropicTools: () => getAnthropicTools,
7403
7826
  genericOAuthIntegration: () => genericOAuthIntegration,
7404
7827
  gcalIntegration: () => gcalIntegration,
7828
+ figmaIntegration: () => figmaIntegration,
7405
7829
  executeGoogleFunctionCalls: () => executeGoogleFunctionCalls,
7406
7830
  createSimpleIntegration: () => createSimpleIntegration,
7407
7831
  createMCPServer: () => createMCPServer,
7832
+ calcomIntegration: () => calcomIntegration,
7408
7833
  airtableIntegration: () => airtableIntegration,
7409
7834
  POST: () => POST,
7410
7835
  GET: () => GET
@@ -7932,6 +8357,16 @@ var init_server = __esm(() => {
7932
8357
  init_outlook();
7933
8358
  init_airtable();
7934
8359
  init_todoist();
8360
+ init_whatsapp();
8361
+ init_calcom();
8362
+ init_ramp();
8363
+ init_onedrive();
8364
+ init_gworkspace();
8365
+ init_polar();
8366
+ init_figma();
8367
+ init_intercom();
8368
+ init_hubspot();
8369
+ init_youtube();
7935
8370
  init_generic();
7936
8371
  init_vercel_ai();
7937
8372
  init_openai();