@zernio/node 0.2.517 → 0.2.519

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.
package/src/client.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import packageJson from '../package.json';
2
+ import { createClient, createConfig, type Client } from '@hey-api/client-fetch';
2
3
  import {
3
- client,
4
4
  activateSequence,
5
5
  activateWorkflow,
6
6
  addBroadcastRecipients,
@@ -214,6 +214,7 @@ import {
214
214
  getInboxVolume,
215
215
  getInstagramAccountInsights,
216
216
  getInstagramDemographics,
217
+ getInstagramFollowStatus,
217
218
  getInstagramFollowerHistory,
218
219
  getInstagramIceBreakers,
219
220
  getInstagramPublishingLimit,
@@ -595,6 +596,13 @@ export interface ClientOptions {
595
596
  export class Zernio {
596
597
  private _options: ClientOptions;
597
598
 
599
+ /**
600
+ * HTTP client owned by this instance. Every namespace method below is bound
601
+ * to it, so two Zernio instances in the same process never see each other's
602
+ * credentials.
603
+ */
604
+ private _client!: Client;
605
+
598
606
  /**
599
607
  * API key used for authentication.
600
608
  */
@@ -605,276 +613,293 @@ export class Zernio {
605
613
  */
606
614
  baseURL: string;
607
615
 
616
+ /**
617
+ * Routes a generated operation through this instance's client, preserving the
618
+ * operation's own signature. Reads `_client` when the method is called, not
619
+ * when it is bound, because class fields initialize before the constructor
620
+ * body runs.
621
+ */
622
+ private _bind<F>(operation: F): F {
623
+ return ((options?: Record<string, unknown>) => {
624
+ const withClient = { ...options };
625
+ if (withClient['client'] === undefined) {
626
+ withClient['client'] = this._client;
627
+ }
628
+ return (operation as (opts: unknown) => unknown)(withClient);
629
+ }) as F;
630
+ }
631
+
608
632
  /**
609
633
  * validate API
610
634
  */
611
635
  validate = {
612
- validatePostLength: validatePostLength,
613
- validatePost: validatePost,
614
- validateMedia: validateMedia,
615
- validateSubreddit: validateSubreddit,
636
+ validatePostLength: this._bind(validatePostLength),
637
+ validatePost: this._bind(validatePost),
638
+ validateMedia: this._bind(validateMedia),
639
+ validateSubreddit: this._bind(validateSubreddit),
616
640
  };
617
641
 
618
642
  /**
619
643
  * Analytics API - Get performance metrics
620
644
  */
621
645
  analytics = {
622
- getAnalytics: getAnalytics,
623
- getYouTubeChannelInsights: getYouTubeChannelInsights,
624
- getLinkedInOrgAggregateAnalytics: getLinkedInOrgAggregateAnalytics,
625
- getTikTokAccountInsights: getTikTokAccountInsights,
626
- getYouTubeDailyViews: getYouTubeDailyViews,
627
- getYouTubeVideoRetention: getYouTubeVideoRetention,
628
- getFacebookPageInsights: getFacebookPageInsights,
629
- getFacebookPostEarnings: getFacebookPostEarnings,
630
- getInstagramAccountInsights: getInstagramAccountInsights,
631
- getInstagramFollowerHistory: getInstagramFollowerHistory,
632
- getInstagramDemographics: getInstagramDemographics,
633
- getYouTubeDemographics: getYouTubeDemographics,
634
- getDailyMetrics: getDailyMetrics,
635
- getBestTimeToPost: getBestTimeToPost,
636
- getContentDecay: getContentDecay,
637
- getPostingFrequency: getPostingFrequency,
638
- getPostTimeline: getPostTimeline,
639
- getGoogleBusinessPerformance: getGoogleBusinessPerformance,
640
- getGoogleBusinessSearchKeywords: getGoogleBusinessSearchKeywords,
641
- syncExternalPosts: syncExternalPosts,
642
- getLinkedInAggregateAnalytics: getLinkedInAggregateAnalytics,
643
- getLinkedInPostAnalytics: getLinkedInPostAnalytics,
644
- getLinkedInPostReactions: getLinkedInPostReactions,
645
- getFacebookPostReactions: getFacebookPostReactions,
646
+ getAnalytics: this._bind(getAnalytics),
647
+ getYouTubeChannelInsights: this._bind(getYouTubeChannelInsights),
648
+ getLinkedInOrgAggregateAnalytics: this._bind(getLinkedInOrgAggregateAnalytics),
649
+ getTikTokAccountInsights: this._bind(getTikTokAccountInsights),
650
+ getYouTubeDailyViews: this._bind(getYouTubeDailyViews),
651
+ getYouTubeVideoRetention: this._bind(getYouTubeVideoRetention),
652
+ getFacebookPageInsights: this._bind(getFacebookPageInsights),
653
+ getFacebookPostEarnings: this._bind(getFacebookPostEarnings),
654
+ getInstagramAccountInsights: this._bind(getInstagramAccountInsights),
655
+ getInstagramFollowerHistory: this._bind(getInstagramFollowerHistory),
656
+ getInstagramDemographics: this._bind(getInstagramDemographics),
657
+ getYouTubeDemographics: this._bind(getYouTubeDemographics),
658
+ getDailyMetrics: this._bind(getDailyMetrics),
659
+ getBestTimeToPost: this._bind(getBestTimeToPost),
660
+ getContentDecay: this._bind(getContentDecay),
661
+ getPostingFrequency: this._bind(getPostingFrequency),
662
+ getPostTimeline: this._bind(getPostTimeline),
663
+ getGoogleBusinessPerformance: this._bind(getGoogleBusinessPerformance),
664
+ getGoogleBusinessSearchKeywords: this._bind(getGoogleBusinessSearchKeywords),
665
+ syncExternalPosts: this._bind(syncExternalPosts),
666
+ getLinkedInAggregateAnalytics: this._bind(getLinkedInAggregateAnalytics),
667
+ getLinkedInPostAnalytics: this._bind(getLinkedInPostAnalytics),
668
+ getLinkedInPostReactions: this._bind(getLinkedInPostReactions),
669
+ getFacebookPostReactions: this._bind(getFacebookPostReactions),
646
670
  };
647
671
 
648
672
  /**
649
673
  * inboxanalytics API
650
674
  */
651
675
  inboxanalytics = {
652
- getInboxVolume: getInboxVolume,
653
- getInboxHeatmap: getInboxHeatmap,
654
- getInboxSourceBreakdown: getInboxSourceBreakdown,
655
- getInboxResponseTime: getInboxResponseTime,
656
- getInboxTopAccounts: getInboxTopAccounts,
657
- listInboxConversationAnalytics: listInboxConversationAnalytics,
658
- getInboxConversationAnalytics: getInboxConversationAnalytics,
676
+ getInboxVolume: this._bind(getInboxVolume),
677
+ getInboxHeatmap: this._bind(getInboxHeatmap),
678
+ getInboxSourceBreakdown: this._bind(getInboxSourceBreakdown),
679
+ getInboxResponseTime: this._bind(getInboxResponseTime),
680
+ getInboxTopAccounts: this._bind(getInboxTopAccounts),
681
+ listInboxConversationAnalytics: this._bind(listInboxConversationAnalytics),
682
+ getInboxConversationAnalytics: this._bind(getInboxConversationAnalytics),
659
683
  };
660
684
 
661
685
  /**
662
686
  * Account Groups API - Organize accounts into groups
663
687
  */
664
688
  accountGroups = {
665
- listAccountGroups: listAccountGroups,
666
- createAccountGroup: createAccountGroup,
667
- updateAccountGroup: updateAccountGroup,
668
- deleteAccountGroup: deleteAccountGroup,
689
+ listAccountGroups: this._bind(listAccountGroups),
690
+ createAccountGroup: this._bind(createAccountGroup),
691
+ updateAccountGroup: this._bind(updateAccountGroup),
692
+ deleteAccountGroup: this._bind(deleteAccountGroup),
669
693
  };
670
694
 
671
695
  /**
672
696
  * Media API - Upload and manage media files
673
697
  */
674
698
  media = {
675
- getMediaPresignedUrl: getMediaPresignedUrl,
699
+ getMediaPresignedUrl: this._bind(getMediaPresignedUrl),
676
700
  };
677
701
 
678
702
  /**
679
703
  * Reddit API - Search and feed
680
704
  */
681
705
  reddit = {
682
- searchReddit: searchReddit,
683
- getRedditFeed: getRedditFeed,
706
+ searchReddit: this._bind(searchReddit),
707
+ getRedditFeed: this._bind(getRedditFeed),
684
708
  };
685
709
 
686
710
  /**
687
711
  * Usage API - Get usage statistics
688
712
  */
689
713
  usage = {
690
- getBilling: getBilling,
691
- getXApiPricing: getXApiPricing,
692
- getUsage: getUsage,
693
- getUsageStats: getUsageStats,
694
- getCallsUsage: getCallsUsage,
695
- getSmsUsage: getSmsUsage,
714
+ getBilling: this._bind(getBilling),
715
+ getXApiPricing: this._bind(getXApiPricing),
716
+ getUsage: this._bind(getUsage),
717
+ getUsageStats: this._bind(getUsageStats),
718
+ getCallsUsage: this._bind(getCallsUsage),
719
+ getSmsUsage: this._bind(getSmsUsage),
696
720
  };
697
721
 
698
722
  /**
699
723
  * Posts API - Create, schedule, and manage social media posts
700
724
  */
701
725
  posts = {
702
- listPosts: listPosts,
703
- createPost: createPost,
704
- getPost: getPost,
705
- updatePost: updatePost,
706
- deletePost: deletePost,
707
- bulkUploadPosts: bulkUploadPosts,
708
- retryPost: retryPost,
709
- unpublishPost: unpublishPost,
710
- editPost: editPost,
711
- updatePostMetadata: updatePostMetadata,
726
+ listPosts: this._bind(listPosts),
727
+ createPost: this._bind(createPost),
728
+ getPost: this._bind(getPost),
729
+ updatePost: this._bind(updatePost),
730
+ deletePost: this._bind(deletePost),
731
+ bulkUploadPosts: this._bind(bulkUploadPosts),
732
+ retryPost: this._bind(retryPost),
733
+ unpublishPost: this._bind(unpublishPost),
734
+ editPost: this._bind(editPost),
735
+ updatePostMetadata: this._bind(updatePostMetadata),
712
736
  };
713
737
 
714
738
  /**
715
739
  * Users API - User management
716
740
  */
717
741
  users = {
718
- listUsers: listUsers,
719
- getUser: getUser,
742
+ listUsers: this._bind(listUsers),
743
+ getUser: this._bind(getUser),
720
744
  };
721
745
 
722
746
  /**
723
747
  * Profiles API - Manage workspace profiles
724
748
  */
725
749
  profiles = {
726
- listProfiles: listProfiles,
727
- createProfile: createProfile,
728
- getProfile: getProfile,
729
- updateProfile: updateProfile,
730
- deleteProfile: deleteProfile,
750
+ listProfiles: this._bind(listProfiles),
751
+ createProfile: this._bind(createProfile),
752
+ getProfile: this._bind(getProfile),
753
+ updateProfile: this._bind(updateProfile),
754
+ deleteProfile: this._bind(deleteProfile),
731
755
  };
732
756
 
733
757
  /**
734
758
  * Accounts API - Manage connected social media accounts
735
759
  */
736
760
  accounts = {
737
- listAccounts: listAccounts,
738
- getFollowerStats: getFollowerStats,
739
- updateAccount: updateAccount,
740
- moveAccountToProfile: moveAccountToProfile,
741
- deleteAccount: deleteAccount,
742
- getAllAccountsHealth: getAllAccountsHealth,
743
- getAccountHealth: getAccountHealth,
744
- getTikTokCreatorInfo: getTikTokCreatorInfo,
745
- getGoogleBusinessReviews: getGoogleBusinessReviews,
746
- batchGetGoogleBusinessReviews: batchGetGoogleBusinessReviews,
747
- replyToGoogleBusinessReview: replyToGoogleBusinessReview,
748
- deleteGoogleBusinessReviewReply: deleteGoogleBusinessReviewReply,
749
- getLinkedInMentions: getLinkedInMentions,
750
- getSlackSettings: getSlackSettings,
751
- updateSlackSettings: updateSlackSettings,
761
+ listAccounts: this._bind(listAccounts),
762
+ getFollowerStats: this._bind(getFollowerStats),
763
+ updateAccount: this._bind(updateAccount),
764
+ moveAccountToProfile: this._bind(moveAccountToProfile),
765
+ deleteAccount: this._bind(deleteAccount),
766
+ getAllAccountsHealth: this._bind(getAllAccountsHealth),
767
+ getAccountHealth: this._bind(getAccountHealth),
768
+ getInstagramFollowStatus: this._bind(getInstagramFollowStatus),
769
+ getTikTokCreatorInfo: this._bind(getTikTokCreatorInfo),
770
+ getGoogleBusinessReviews: this._bind(getGoogleBusinessReviews),
771
+ batchGetGoogleBusinessReviews: this._bind(batchGetGoogleBusinessReviews),
772
+ replyToGoogleBusinessReview: this._bind(replyToGoogleBusinessReview),
773
+ deleteGoogleBusinessReviewReply: this._bind(deleteGoogleBusinessReviewReply),
774
+ getLinkedInMentions: this._bind(getLinkedInMentions),
775
+ getSlackSettings: this._bind(getSlackSettings),
776
+ updateSlackSettings: this._bind(updateSlackSettings),
752
777
  };
753
778
 
754
779
  /**
755
780
  * whatsapp API
756
781
  */
757
782
  whatsapp = {
758
- registerWhatsAppNumber: registerWhatsAppNumber,
759
- getWhatsAppMedia: getWhatsAppMedia,
760
- getWhatsAppTemplates: getWhatsAppTemplates,
761
- createWhatsAppTemplate: createWhatsAppTemplate,
762
- getWhatsAppTemplate: getWhatsAppTemplate,
763
- updateWhatsAppTemplate: updateWhatsAppTemplate,
764
- deleteWhatsAppTemplate: deleteWhatsAppTemplate,
765
- getWhatsAppBusinessProfile: getWhatsAppBusinessProfile,
766
- updateWhatsAppBusinessProfile: updateWhatsAppBusinessProfile,
767
- uploadWhatsAppProfilePhoto: uploadWhatsAppProfilePhoto,
768
- getWhatsAppDisplayName: getWhatsAppDisplayName,
769
- updateWhatsAppDisplayName: updateWhatsAppDisplayName,
770
- getWhatsappBusinessUsername: getWhatsappBusinessUsername,
771
- setWhatsappBusinessUsername: setWhatsappBusinessUsername,
772
- deleteWhatsappBusinessUsername: deleteWhatsappBusinessUsername,
773
- getWhatsappBusinessUsernameSuggestions: getWhatsappBusinessUsernameSuggestions,
774
- getWhatsAppBlockStatus: getWhatsAppBlockStatus,
775
- getWhatsAppBlockedUsers: getWhatsAppBlockedUsers,
776
- blockWhatsAppUsers: blockWhatsAppUsers,
777
- unblockWhatsAppUsers: unblockWhatsAppUsers,
778
- getWhatsAppDataset: getWhatsAppDataset,
779
- createWhatsAppDataset: createWhatsAppDataset,
780
- listWhatsAppGroupChats: listWhatsAppGroupChats,
781
- createWhatsAppGroupChat: createWhatsAppGroupChat,
782
- getWhatsAppGroupChat: getWhatsAppGroupChat,
783
- updateWhatsAppGroupChat: updateWhatsAppGroupChat,
784
- deleteWhatsAppGroupChat: deleteWhatsAppGroupChat,
785
- addWhatsAppGroupParticipants: addWhatsAppGroupParticipants,
786
- removeWhatsAppGroupParticipants: removeWhatsAppGroupParticipants,
787
- createWhatsAppGroupInviteLink: createWhatsAppGroupInviteLink,
788
- listWhatsAppGroupJoinRequests: listWhatsAppGroupJoinRequests,
789
- approveWhatsAppGroupJoinRequests: approveWhatsAppGroupJoinRequests,
790
- rejectWhatsAppGroupJoinRequests: rejectWhatsAppGroupJoinRequests,
791
- listWhatsAppConversions: listWhatsAppConversions,
792
- sendWhatsAppConversion: sendWhatsAppConversion,
783
+ registerWhatsAppNumber: this._bind(registerWhatsAppNumber),
784
+ getWhatsAppMedia: this._bind(getWhatsAppMedia),
785
+ getWhatsAppTemplates: this._bind(getWhatsAppTemplates),
786
+ createWhatsAppTemplate: this._bind(createWhatsAppTemplate),
787
+ getWhatsAppTemplate: this._bind(getWhatsAppTemplate),
788
+ updateWhatsAppTemplate: this._bind(updateWhatsAppTemplate),
789
+ deleteWhatsAppTemplate: this._bind(deleteWhatsAppTemplate),
790
+ getWhatsAppBusinessProfile: this._bind(getWhatsAppBusinessProfile),
791
+ updateWhatsAppBusinessProfile: this._bind(updateWhatsAppBusinessProfile),
792
+ uploadWhatsAppProfilePhoto: this._bind(uploadWhatsAppProfilePhoto),
793
+ getWhatsAppDisplayName: this._bind(getWhatsAppDisplayName),
794
+ updateWhatsAppDisplayName: this._bind(updateWhatsAppDisplayName),
795
+ getWhatsappBusinessUsername: this._bind(getWhatsappBusinessUsername),
796
+ setWhatsappBusinessUsername: this._bind(setWhatsappBusinessUsername),
797
+ deleteWhatsappBusinessUsername: this._bind(deleteWhatsappBusinessUsername),
798
+ getWhatsappBusinessUsernameSuggestions: this._bind(getWhatsappBusinessUsernameSuggestions),
799
+ getWhatsAppBlockStatus: this._bind(getWhatsAppBlockStatus),
800
+ getWhatsAppBlockedUsers: this._bind(getWhatsAppBlockedUsers),
801
+ blockWhatsAppUsers: this._bind(blockWhatsAppUsers),
802
+ unblockWhatsAppUsers: this._bind(unblockWhatsAppUsers),
803
+ getWhatsAppDataset: this._bind(getWhatsAppDataset),
804
+ createWhatsAppDataset: this._bind(createWhatsAppDataset),
805
+ listWhatsAppGroupChats: this._bind(listWhatsAppGroupChats),
806
+ createWhatsAppGroupChat: this._bind(createWhatsAppGroupChat),
807
+ getWhatsAppGroupChat: this._bind(getWhatsAppGroupChat),
808
+ updateWhatsAppGroupChat: this._bind(updateWhatsAppGroupChat),
809
+ deleteWhatsAppGroupChat: this._bind(deleteWhatsAppGroupChat),
810
+ addWhatsAppGroupParticipants: this._bind(addWhatsAppGroupParticipants),
811
+ removeWhatsAppGroupParticipants: this._bind(removeWhatsAppGroupParticipants),
812
+ createWhatsAppGroupInviteLink: this._bind(createWhatsAppGroupInviteLink),
813
+ listWhatsAppGroupJoinRequests: this._bind(listWhatsAppGroupJoinRequests),
814
+ approveWhatsAppGroupJoinRequests: this._bind(approveWhatsAppGroupJoinRequests),
815
+ rejectWhatsAppGroupJoinRequests: this._bind(rejectWhatsAppGroupJoinRequests),
816
+ listWhatsAppConversions: this._bind(listWhatsAppConversions),
817
+ sendWhatsAppConversion: this._bind(sendWhatsAppConversion),
793
818
  };
794
819
 
795
820
  /**
796
821
  * API Keys API - Manage API keys
797
822
  */
798
823
  apiKeys = {
799
- verifyCredential: verifyCredential,
800
- listApiKeys: listApiKeys,
801
- createApiKey: createApiKey,
802
- deleteApiKey: deleteApiKey,
824
+ verifyCredential: this._bind(verifyCredential),
825
+ listApiKeys: this._bind(listApiKeys),
826
+ createApiKey: this._bind(createApiKey),
827
+ deleteApiKey: this._bind(deleteApiKey),
803
828
  };
804
829
 
805
830
  /**
806
831
  * connectedapps API
807
832
  */
808
833
  connectedapps = {
809
- listConnectedApps: listConnectedApps,
810
- revokeConnectedApp: revokeConnectedApp,
834
+ listConnectedApps: this._bind(listConnectedApps),
835
+ revokeConnectedApp: this._bind(revokeConnectedApp),
811
836
  };
812
837
 
813
838
  /**
814
839
  * Invites API - Team invitations
815
840
  */
816
841
  invites = {
817
- createInviteToken: createInviteToken,
842
+ createInviteToken: this._bind(createInviteToken),
818
843
  };
819
844
 
820
845
  /**
821
846
  * Connect API - OAuth connection flows
822
847
  */
823
848
  connect = {
824
- getConnectUrl: getConnectUrl,
825
- handleOAuthCallback: handleOAuthCallback,
826
- connectAds: connectAds,
827
- configureTikTokAdsBrandIdentity: configureTikTokAdsBrandIdentity,
828
- getPendingOAuthData: getPendingOAuthData,
829
- connectOpenAIAdsCredentials: connectOpenAiAdsCredentials,
830
- connectWhatsAppCredentials: connectWhatsAppCredentials,
831
- listWhatsAppPhoneNumbers: listWhatsAppPhoneNumbers,
832
- completeWhatsAppPhoneSelection: completeWhatsAppPhoneSelection,
833
- getFacebookPages: getFacebookPages,
834
- updateFacebookPage: updateFacebookPage,
835
- getLinkedInOrganizations: getLinkedInOrganizations,
836
- updateLinkedInOrganization: updateLinkedInOrganization,
837
- getPinterestBoards: getPinterestBoards,
838
- updatePinterestBoards: updatePinterestBoards,
839
- createPinterestBoard: createPinterestBoard,
840
- getYoutubePlaylists: getYoutubePlaylists,
841
- updateYoutubeDefaultPlaylist: updateYoutubeDefaultPlaylist,
842
- getGmbLocations: getGmbLocations,
843
- updateGmbLocation: updateGmbLocation,
844
- assignGoogleBusinessLocation: assignGoogleBusinessLocation,
845
- getRedditSubreddits: getRedditSubreddits,
846
- updateRedditSubreddits: updateRedditSubreddits,
847
- getSubredditRules: getSubredditRules,
848
- voteRedditThing: voteRedditThing,
849
- getRedditFlairs: getRedditFlairs,
850
- setRedditPostFlair: setRedditPostFlair,
849
+ getConnectUrl: this._bind(getConnectUrl),
850
+ handleOAuthCallback: this._bind(handleOAuthCallback),
851
+ connectAds: this._bind(connectAds),
852
+ configureTikTokAdsBrandIdentity: this._bind(configureTikTokAdsBrandIdentity),
853
+ getPendingOAuthData: this._bind(getPendingOAuthData),
854
+ connectOpenAIAdsCredentials: this._bind(connectOpenAiAdsCredentials),
855
+ connectWhatsAppCredentials: this._bind(connectWhatsAppCredentials),
856
+ listWhatsAppPhoneNumbers: this._bind(listWhatsAppPhoneNumbers),
857
+ completeWhatsAppPhoneSelection: this._bind(completeWhatsAppPhoneSelection),
858
+ getFacebookPages: this._bind(getFacebookPages),
859
+ updateFacebookPage: this._bind(updateFacebookPage),
860
+ getLinkedInOrganizations: this._bind(getLinkedInOrganizations),
861
+ updateLinkedInOrganization: this._bind(updateLinkedInOrganization),
862
+ getPinterestBoards: this._bind(getPinterestBoards),
863
+ updatePinterestBoards: this._bind(updatePinterestBoards),
864
+ createPinterestBoard: this._bind(createPinterestBoard),
865
+ getYoutubePlaylists: this._bind(getYoutubePlaylists),
866
+ updateYoutubeDefaultPlaylist: this._bind(updateYoutubeDefaultPlaylist),
867
+ getGmbLocations: this._bind(getGmbLocations),
868
+ updateGmbLocation: this._bind(updateGmbLocation),
869
+ assignGoogleBusinessLocation: this._bind(assignGoogleBusinessLocation),
870
+ getRedditSubreddits: this._bind(getRedditSubreddits),
871
+ updateRedditSubreddits: this._bind(updateRedditSubreddits),
872
+ getSubredditRules: this._bind(getSubredditRules),
873
+ voteRedditThing: this._bind(voteRedditThing),
874
+ getRedditFlairs: this._bind(getRedditFlairs),
875
+ setRedditPostFlair: this._bind(setRedditPostFlair),
851
876
  facebook: {
852
- listFacebookPages: listFacebookPages,
853
- selectFacebookPage: selectFacebookPage,
877
+ listFacebookPages: this._bind(listFacebookPages),
878
+ selectFacebookPage: this._bind(selectFacebookPage),
854
879
  },
855
880
  googleBusiness: {
856
- listGoogleBusinessLocations: listGoogleBusinessLocations,
857
- selectGoogleBusinessLocation: selectGoogleBusinessLocation,
881
+ listGoogleBusinessLocations: this._bind(listGoogleBusinessLocations),
882
+ selectGoogleBusinessLocation: this._bind(selectGoogleBusinessLocation),
858
883
  },
859
884
  linkedin: {
860
- listLinkedInOrganizations: listLinkedInOrganizations,
861
- selectLinkedInOrganization: selectLinkedInOrganization,
885
+ listLinkedInOrganizations: this._bind(listLinkedInOrganizations),
886
+ selectLinkedInOrganization: this._bind(selectLinkedInOrganization),
862
887
  },
863
888
  pinterest: {
864
- listPinterestBoardsForSelection: listPinterestBoardsForSelection,
865
- selectPinterestBoard: selectPinterestBoard,
889
+ listPinterestBoardsForSelection: this._bind(listPinterestBoardsForSelection),
890
+ selectPinterestBoard: this._bind(selectPinterestBoard),
866
891
  },
867
892
  snapchat: {
868
- listSnapchatProfiles: listSnapchatProfiles,
869
- selectSnapchatProfile: selectSnapchatProfile,
893
+ listSnapchatProfiles: this._bind(listSnapchatProfiles),
894
+ selectSnapchatProfile: this._bind(selectSnapchatProfile),
870
895
  },
871
896
  bluesky: {
872
- connectBlueskyCredentials: connectBlueskyCredentials,
897
+ connectBlueskyCredentials: this._bind(connectBlueskyCredentials),
873
898
  },
874
899
  telegram: {
875
- getTelegramConnectStatus: getTelegramConnectStatus,
876
- initiateTelegramConnect: initiateTelegramConnect,
877
- completeTelegramConnect: completeTelegramConnect,
900
+ getTelegramConnectStatus: this._bind(getTelegramConnectStatus),
901
+ initiateTelegramConnect: this._bind(initiateTelegramConnect),
902
+ completeTelegramConnect: this._bind(completeTelegramConnect),
878
903
  },
879
904
  };
880
905
 
@@ -882,653 +907,653 @@ export class Zernio {
882
907
  * gmbverifications API
883
908
  */
884
909
  gmbverifications = {
885
- getGoogleBusinessVerifications: getGoogleBusinessVerifications,
886
- startGoogleBusinessVerification: startGoogleBusinessVerification,
887
- fetchGoogleBusinessVerificationOptions: fetchGoogleBusinessVerificationOptions,
888
- completeGoogleBusinessVerification: completeGoogleBusinessVerification,
910
+ getGoogleBusinessVerifications: this._bind(getGoogleBusinessVerifications),
911
+ startGoogleBusinessVerification: this._bind(startGoogleBusinessVerification),
912
+ fetchGoogleBusinessVerificationOptions: this._bind(fetchGoogleBusinessVerificationOptions),
913
+ completeGoogleBusinessVerification: this._bind(completeGoogleBusinessVerification),
889
914
  };
890
915
 
891
916
  /**
892
917
  * gmbfoodmenus API
893
918
  */
894
919
  gmbfoodmenus = {
895
- getGoogleBusinessFoodMenus: getGoogleBusinessFoodMenus,
896
- updateGoogleBusinessFoodMenus: updateGoogleBusinessFoodMenus,
920
+ getGoogleBusinessFoodMenus: this._bind(getGoogleBusinessFoodMenus),
921
+ updateGoogleBusinessFoodMenus: this._bind(updateGoogleBusinessFoodMenus),
897
922
  };
898
923
 
899
924
  /**
900
925
  * gmblocationdetails API
901
926
  */
902
927
  gmblocationdetails = {
903
- getGoogleBusinessLocationDetails: getGoogleBusinessLocationDetails,
904
- updateGoogleBusinessLocationDetails: updateGoogleBusinessLocationDetails,
928
+ getGoogleBusinessLocationDetails: this._bind(getGoogleBusinessLocationDetails),
929
+ updateGoogleBusinessLocationDetails: this._bind(updateGoogleBusinessLocationDetails),
905
930
  };
906
931
 
907
932
  /**
908
933
  * gmbmedia API
909
934
  */
910
935
  gmbmedia = {
911
- listGoogleBusinessMedia: listGoogleBusinessMedia,
912
- createGoogleBusinessMedia: createGoogleBusinessMedia,
913
- deleteGoogleBusinessMedia: deleteGoogleBusinessMedia,
936
+ listGoogleBusinessMedia: this._bind(listGoogleBusinessMedia),
937
+ createGoogleBusinessMedia: this._bind(createGoogleBusinessMedia),
938
+ deleteGoogleBusinessMedia: this._bind(deleteGoogleBusinessMedia),
914
939
  };
915
940
 
916
941
  /**
917
942
  * gmbattributes API
918
943
  */
919
944
  gmbattributes = {
920
- getGmbAttributeMetadata: getGmbAttributeMetadata,
921
- getGoogleBusinessAttributes: getGoogleBusinessAttributes,
922
- updateGoogleBusinessAttributes: updateGoogleBusinessAttributes,
945
+ getGmbAttributeMetadata: this._bind(getGmbAttributeMetadata),
946
+ getGoogleBusinessAttributes: this._bind(getGoogleBusinessAttributes),
947
+ updateGoogleBusinessAttributes: this._bind(updateGoogleBusinessAttributes),
923
948
  };
924
949
 
925
950
  /**
926
951
  * gmbplaceactions API
927
952
  */
928
953
  gmbplaceactions = {
929
- listGoogleBusinessPlaceActions: listGoogleBusinessPlaceActions,
930
- createGoogleBusinessPlaceAction: createGoogleBusinessPlaceAction,
931
- deleteGoogleBusinessPlaceAction: deleteGoogleBusinessPlaceAction,
932
- updateGoogleBusinessPlaceAction: updateGoogleBusinessPlaceAction,
954
+ listGoogleBusinessPlaceActions: this._bind(listGoogleBusinessPlaceActions),
955
+ createGoogleBusinessPlaceAction: this._bind(createGoogleBusinessPlaceAction),
956
+ deleteGoogleBusinessPlaceAction: this._bind(deleteGoogleBusinessPlaceAction),
957
+ updateGoogleBusinessPlaceAction: this._bind(updateGoogleBusinessPlaceAction),
933
958
  };
934
959
 
935
960
  /**
936
961
  * gmbservices API
937
962
  */
938
963
  gmbservices = {
939
- getGoogleBusinessServices: getGoogleBusinessServices,
940
- updateGoogleBusinessServices: updateGoogleBusinessServices,
964
+ getGoogleBusinessServices: this._bind(getGoogleBusinessServices),
965
+ updateGoogleBusinessServices: this._bind(updateGoogleBusinessServices),
941
966
  };
942
967
 
943
968
  /**
944
969
  * instagram API
945
970
  */
946
971
  instagram = {
947
- listInstagramStories: listInstagramStories,
948
- getInstagramPublishingLimit: getInstagramPublishingLimit,
949
- getInstagramStoryInsights: getInstagramStoryInsights,
972
+ listInstagramStories: this._bind(listInstagramStories),
973
+ getInstagramPublishingLimit: this._bind(getInstagramPublishingLimit),
974
+ getInstagramStoryInsights: this._bind(getInstagramStoryInsights),
950
975
  };
951
976
 
952
977
  /**
953
978
  * discord API
954
979
  */
955
980
  discord = {
956
- getDiscordSettings: getDiscordSettings,
957
- updateDiscordSettings: updateDiscordSettings,
958
- getDiscordChannels: getDiscordChannels,
959
- sendDiscordDirectMessage: sendDiscordDirectMessage,
960
- listDiscordGuildRoles: listDiscordGuildRoles,
961
- createDiscordGuildRole: createDiscordGuildRole,
962
- editDiscordGuildRole: editDiscordGuildRole,
963
- deleteDiscordGuildRole: deleteDiscordGuildRole,
964
- listDiscordGuildMembers: listDiscordGuildMembers,
965
- searchDiscordGuildMembers: searchDiscordGuildMembers,
966
- getDiscordGuildMember: getDiscordGuildMember,
967
- addDiscordMemberRole: addDiscordMemberRole,
968
- removeDiscordMemberRole: removeDiscordMemberRole,
969
- deleteDiscordMessage: deleteDiscordMessage,
970
- crosspostDiscordMessage: crosspostDiscordMessage,
971
- createDiscordThread: createDiscordThread,
972
- listDiscordPinnedMessages: listDiscordPinnedMessages,
973
- pinDiscordMessage: pinDiscordMessage,
974
- unpinDiscordMessage: unpinDiscordMessage,
975
- listDiscordScheduledEvents: listDiscordScheduledEvents,
976
- createDiscordScheduledEvent: createDiscordScheduledEvent,
977
- getDiscordScheduledEvent: getDiscordScheduledEvent,
978
- updateDiscordScheduledEvent: updateDiscordScheduledEvent,
979
- deleteDiscordScheduledEvent: deleteDiscordScheduledEvent,
981
+ getDiscordSettings: this._bind(getDiscordSettings),
982
+ updateDiscordSettings: this._bind(updateDiscordSettings),
983
+ getDiscordChannels: this._bind(getDiscordChannels),
984
+ sendDiscordDirectMessage: this._bind(sendDiscordDirectMessage),
985
+ listDiscordGuildRoles: this._bind(listDiscordGuildRoles),
986
+ createDiscordGuildRole: this._bind(createDiscordGuildRole),
987
+ editDiscordGuildRole: this._bind(editDiscordGuildRole),
988
+ deleteDiscordGuildRole: this._bind(deleteDiscordGuildRole),
989
+ listDiscordGuildMembers: this._bind(listDiscordGuildMembers),
990
+ searchDiscordGuildMembers: this._bind(searchDiscordGuildMembers),
991
+ getDiscordGuildMember: this._bind(getDiscordGuildMember),
992
+ addDiscordMemberRole: this._bind(addDiscordMemberRole),
993
+ removeDiscordMemberRole: this._bind(removeDiscordMemberRole),
994
+ deleteDiscordMessage: this._bind(deleteDiscordMessage),
995
+ crosspostDiscordMessage: this._bind(crosspostDiscordMessage),
996
+ createDiscordThread: this._bind(createDiscordThread),
997
+ listDiscordPinnedMessages: this._bind(listDiscordPinnedMessages),
998
+ pinDiscordMessage: this._bind(pinDiscordMessage),
999
+ unpinDiscordMessage: this._bind(unpinDiscordMessage),
1000
+ listDiscordScheduledEvents: this._bind(listDiscordScheduledEvents),
1001
+ createDiscordScheduledEvent: this._bind(createDiscordScheduledEvent),
1002
+ getDiscordScheduledEvent: this._bind(getDiscordScheduledEvent),
1003
+ updateDiscordScheduledEvent: this._bind(updateDiscordScheduledEvent),
1004
+ deleteDiscordScheduledEvent: this._bind(deleteDiscordScheduledEvent),
980
1005
  };
981
1006
 
982
1007
  /**
983
1008
  * slack API
984
1009
  */
985
1010
  slack = {
986
- listSlackMembers: listSlackMembers,
1011
+ listSlackMembers: this._bind(listSlackMembers),
987
1012
  };
988
1013
 
989
1014
  /**
990
1015
  * Queue API - Manage posting queue
991
1016
  */
992
1017
  queue = {
993
- listQueueSlots: listQueueSlots,
994
- createQueueSlot: createQueueSlot,
995
- updateQueueSlot: updateQueueSlot,
996
- deleteQueueSlot: deleteQueueSlot,
997
- previewQueue: previewQueue,
998
- getNextQueueSlot: getNextQueueSlot,
1018
+ listQueueSlots: this._bind(listQueueSlots),
1019
+ createQueueSlot: this._bind(createQueueSlot),
1020
+ updateQueueSlot: this._bind(updateQueueSlot),
1021
+ deleteQueueSlot: this._bind(deleteQueueSlot),
1022
+ previewQueue: this._bind(previewQueue),
1023
+ getNextQueueSlot: this._bind(getNextQueueSlot),
999
1024
  };
1000
1025
 
1001
1026
  /**
1002
1027
  * Webhooks API - Configure event webhooks
1003
1028
  */
1004
1029
  webhooks = {
1005
- getWebhookSettings: getWebhookSettings,
1006
- createWebhookSettings: createWebhookSettings,
1007
- updateWebhookSettings: updateWebhookSettings,
1008
- deleteWebhookSettings: deleteWebhookSettings,
1009
- getWebhookLogs: getWebhookLogs,
1010
- testWebhook: testWebhook,
1030
+ getWebhookSettings: this._bind(getWebhookSettings),
1031
+ createWebhookSettings: this._bind(createWebhookSettings),
1032
+ updateWebhookSettings: this._bind(updateWebhookSettings),
1033
+ deleteWebhookSettings: this._bind(deleteWebhookSettings),
1034
+ getWebhookLogs: this._bind(getWebhookLogs),
1035
+ testWebhook: this._bind(testWebhook),
1011
1036
  };
1012
1037
 
1013
1038
  /**
1014
1039
  * Logs API - Publishing logs
1015
1040
  */
1016
1041
  logs = {
1017
- listLogs: listLogs,
1042
+ listLogs: this._bind(listLogs),
1018
1043
  };
1019
1044
 
1020
1045
  /**
1021
1046
  * messages API
1022
1047
  */
1023
1048
  messages = {
1024
- listInboxConversations: listInboxConversations,
1025
- createInboxConversation: createInboxConversation,
1026
- searchInboxConversations: searchInboxConversations,
1027
- getInboxConversation: getInboxConversation,
1028
- updateInboxConversation: updateInboxConversation,
1029
- getInboxConversationMessages: getInboxConversationMessages,
1030
- sendInboxMessage: sendInboxMessage,
1031
- editInboxMessage: editInboxMessage,
1032
- deleteInboxMessage: deleteInboxMessage,
1033
- sendTypingIndicator: sendTypingIndicator,
1034
- markConversationRead: markConversationRead,
1035
- addMessageReaction: addMessageReaction,
1036
- removeMessageReaction: removeMessageReaction,
1037
- uploadMediaDirect: uploadMediaDirect,
1049
+ listInboxConversations: this._bind(listInboxConversations),
1050
+ createInboxConversation: this._bind(createInboxConversation),
1051
+ searchInboxConversations: this._bind(searchInboxConversations),
1052
+ getInboxConversation: this._bind(getInboxConversation),
1053
+ updateInboxConversation: this._bind(updateInboxConversation),
1054
+ getInboxConversationMessages: this._bind(getInboxConversationMessages),
1055
+ sendInboxMessage: this._bind(sendInboxMessage),
1056
+ editInboxMessage: this._bind(editInboxMessage),
1057
+ deleteInboxMessage: this._bind(deleteInboxMessage),
1058
+ sendTypingIndicator: this._bind(sendTypingIndicator),
1059
+ markConversationRead: this._bind(markConversationRead),
1060
+ addMessageReaction: this._bind(addMessageReaction),
1061
+ removeMessageReaction: this._bind(removeMessageReaction),
1062
+ uploadMediaDirect: this._bind(uploadMediaDirect),
1038
1063
  };
1039
1064
 
1040
1065
  /**
1041
1066
  * accountsettings API
1042
1067
  */
1043
1068
  accountsettings = {
1044
- getMessengerMenu: getMessengerMenu,
1045
- setMessengerMenu: setMessengerMenu,
1046
- deleteMessengerMenu: deleteMessengerMenu,
1047
- getInstagramIceBreakers: getInstagramIceBreakers,
1048
- setInstagramIceBreakers: setInstagramIceBreakers,
1049
- deleteInstagramIceBreakers: deleteInstagramIceBreakers,
1050
- getTelegramCommands: getTelegramCommands,
1051
- setTelegramCommands: setTelegramCommands,
1052
- deleteTelegramCommands: deleteTelegramCommands,
1069
+ getMessengerMenu: this._bind(getMessengerMenu),
1070
+ setMessengerMenu: this._bind(setMessengerMenu),
1071
+ deleteMessengerMenu: this._bind(deleteMessengerMenu),
1072
+ getInstagramIceBreakers: this._bind(getInstagramIceBreakers),
1073
+ setInstagramIceBreakers: this._bind(setInstagramIceBreakers),
1074
+ deleteInstagramIceBreakers: this._bind(deleteInstagramIceBreakers),
1075
+ getTelegramCommands: this._bind(getTelegramCommands),
1076
+ setTelegramCommands: this._bind(setTelegramCommands),
1077
+ deleteTelegramCommands: this._bind(deleteTelegramCommands),
1053
1078
  };
1054
1079
 
1055
1080
  /**
1056
1081
  * comments API
1057
1082
  */
1058
1083
  comments = {
1059
- listInboxComments: listInboxComments,
1060
- getInboxPostComments: getInboxPostComments,
1061
- replyToInboxPost: replyToInboxPost,
1062
- deleteInboxComment: deleteInboxComment,
1063
- editInboxComment: editInboxComment,
1064
- setCommentModeration: setCommentModeration,
1065
- hideInboxComment: hideInboxComment,
1066
- unhideInboxComment: unhideInboxComment,
1067
- likeInboxComment: likeInboxComment,
1068
- unlikeInboxComment: unlikeInboxComment,
1069
- sendPrivateReplyToComment: sendPrivateReplyToComment,
1084
+ listInboxComments: this._bind(listInboxComments),
1085
+ getInboxPostComments: this._bind(getInboxPostComments),
1086
+ replyToInboxPost: this._bind(replyToInboxPost),
1087
+ deleteInboxComment: this._bind(deleteInboxComment),
1088
+ editInboxComment: this._bind(editInboxComment),
1089
+ setCommentModeration: this._bind(setCommentModeration),
1090
+ hideInboxComment: this._bind(hideInboxComment),
1091
+ unhideInboxComment: this._bind(unhideInboxComment),
1092
+ likeInboxComment: this._bind(likeInboxComment),
1093
+ unlikeInboxComment: this._bind(unlikeInboxComment),
1094
+ sendPrivateReplyToComment: this._bind(sendPrivateReplyToComment),
1070
1095
  };
1071
1096
 
1072
1097
  /**
1073
1098
  * twitterengagement API
1074
1099
  */
1075
1100
  twitterengagement = {
1076
- retweetPost: retweetPost,
1077
- undoRetweet: undoRetweet,
1078
- bookmarkPost: bookmarkPost,
1079
- removeBookmark: removeBookmark,
1080
- followUser: followUser,
1081
- unfollowUser: unfollowUser,
1082
- searchTweets: searchTweets,
1083
- getTweet: getTweet,
1101
+ retweetPost: this._bind(retweetPost),
1102
+ undoRetweet: this._bind(undoRetweet),
1103
+ bookmarkPost: this._bind(bookmarkPost),
1104
+ removeBookmark: this._bind(removeBookmark),
1105
+ followUser: this._bind(followUser),
1106
+ unfollowUser: this._bind(unfollowUser),
1107
+ searchTweets: this._bind(searchTweets),
1108
+ getTweet: this._bind(getTweet),
1084
1109
  };
1085
1110
 
1086
1111
  /**
1087
1112
  * mentions API
1088
1113
  */
1089
1114
  mentions = {
1090
- listInboxMentions: listInboxMentions,
1091
- replyToMention: replyToMention,
1115
+ listInboxMentions: this._bind(listInboxMentions),
1116
+ replyToMention: this._bind(replyToMention),
1092
1117
  };
1093
1118
 
1094
1119
  /**
1095
1120
  * reviews API
1096
1121
  */
1097
1122
  reviews = {
1098
- listInboxReviews: listInboxReviews,
1099
- replyToInboxReview: replyToInboxReview,
1100
- deleteInboxReviewReply: deleteInboxReviewReply,
1123
+ listInboxReviews: this._bind(listInboxReviews),
1124
+ replyToInboxReview: this._bind(replyToInboxReview),
1125
+ deleteInboxReviewReply: this._bind(deleteInboxReviewReply),
1101
1126
  };
1102
1127
 
1103
1128
  /**
1104
1129
  * whatsappcalling API
1105
1130
  */
1106
1131
  whatsappcalling = {
1107
- getWhatsAppCallingConfig: getWhatsAppCallingConfig,
1108
- enableWhatsAppCallingLegacy: enableWhatsAppCallingLegacy,
1109
- updateWhatsAppCallingLegacy: updateWhatsAppCallingLegacy,
1110
- disableWhatsAppCallingLegacy: disableWhatsAppCallingLegacy,
1111
- getWhatsAppCallPermissions: getWhatsAppCallPermissions,
1112
- initiateWhatsAppCall: initiateWhatsAppCall,
1113
- listWhatsAppCalls: listWhatsAppCalls,
1114
- getWhatsAppCall: getWhatsAppCall,
1115
- getWhatsAppCallRecording: getWhatsAppCallRecording,
1116
- getWhatsAppCallEstimate: getWhatsAppCallEstimate,
1117
- getWhatsAppCalling: getWhatsAppCalling,
1118
- enableWhatsAppCalling: enableWhatsAppCalling,
1119
- updateWhatsAppCalling: updateWhatsAppCalling,
1120
- disableWhatsAppCalling: disableWhatsAppCalling,
1121
- startWhatsAppCallerIdVerification: startWhatsAppCallerIdVerification,
1122
- verifyWhatsAppCallerId: verifyWhatsAppCallerId,
1132
+ getWhatsAppCallingConfig: this._bind(getWhatsAppCallingConfig),
1133
+ enableWhatsAppCallingLegacy: this._bind(enableWhatsAppCallingLegacy),
1134
+ updateWhatsAppCallingLegacy: this._bind(updateWhatsAppCallingLegacy),
1135
+ disableWhatsAppCallingLegacy: this._bind(disableWhatsAppCallingLegacy),
1136
+ getWhatsAppCallPermissions: this._bind(getWhatsAppCallPermissions),
1137
+ initiateWhatsAppCall: this._bind(initiateWhatsAppCall),
1138
+ listWhatsAppCalls: this._bind(listWhatsAppCalls),
1139
+ getWhatsAppCall: this._bind(getWhatsAppCall),
1140
+ getWhatsAppCallRecording: this._bind(getWhatsAppCallRecording),
1141
+ getWhatsAppCallEstimate: this._bind(getWhatsAppCallEstimate),
1142
+ getWhatsAppCalling: this._bind(getWhatsAppCalling),
1143
+ enableWhatsAppCalling: this._bind(enableWhatsAppCalling),
1144
+ updateWhatsAppCalling: this._bind(updateWhatsAppCalling),
1145
+ disableWhatsAppCalling: this._bind(disableWhatsAppCalling),
1146
+ startWhatsAppCallerIdVerification: this._bind(startWhatsAppCallerIdVerification),
1147
+ verifyWhatsAppCallerId: this._bind(verifyWhatsAppCallerId),
1123
1148
  };
1124
1149
 
1125
1150
  /**
1126
1151
  * calls API
1127
1152
  */
1128
1153
  calls = {
1129
- listCalls: listCalls,
1130
- getCall: getCall,
1131
- getCallRecording: getCallRecording,
1154
+ listCalls: this._bind(listCalls),
1155
+ getCall: this._bind(getCall),
1156
+ getCallRecording: this._bind(getCallRecording),
1132
1157
  };
1133
1158
 
1134
1159
  /**
1135
1160
  * voice API
1136
1161
  */
1137
1162
  voice = {
1138
- createVoiceCall: createVoiceCall,
1139
- listVoiceCalls: listVoiceCalls,
1140
- getVoiceCall: getVoiceCall,
1141
- endVoiceCall: endVoiceCall,
1142
- getVoiceCallRecording: getVoiceCallRecording,
1143
- transferVoiceCall: transferVoiceCall,
1144
- getVoiceCallEstimate: getVoiceCallEstimate,
1145
- createVoiceWebSession: createVoiceWebSession,
1146
- dialVoiceWebCall: dialVoiceWebCall,
1147
- enableVoiceOnNumber: enableVoiceOnNumber,
1148
- disableVoiceOnNumber: disableVoiceOnNumber,
1163
+ createVoiceCall: this._bind(createVoiceCall),
1164
+ listVoiceCalls: this._bind(listVoiceCalls),
1165
+ getVoiceCall: this._bind(getVoiceCall),
1166
+ endVoiceCall: this._bind(endVoiceCall),
1167
+ getVoiceCallRecording: this._bind(getVoiceCallRecording),
1168
+ transferVoiceCall: this._bind(transferVoiceCall),
1169
+ getVoiceCallEstimate: this._bind(getVoiceCallEstimate),
1170
+ createVoiceWebSession: this._bind(createVoiceWebSession),
1171
+ dialVoiceWebCall: this._bind(dialVoiceWebCall),
1172
+ enableVoiceOnNumber: this._bind(enableVoiceOnNumber),
1173
+ disableVoiceOnNumber: this._bind(disableVoiceOnNumber),
1149
1174
  };
1150
1175
 
1151
1176
  /**
1152
1177
  * sms API
1153
1178
  */
1154
1179
  sms = {
1155
- sendSms: sendSms,
1156
- lookupSmsNumber: lookupSmsNumber,
1157
- listSmsOptOuts: listSmsOptOuts,
1158
- createSmsSenderId: createSmsSenderId,
1159
- listSmsSenderIds: listSmsSenderIds,
1160
- requestSmsSenderIdLimitIncrease: requestSmsSenderIdLimitIncrease,
1161
- deleteSmsSenderId: deleteSmsSenderId,
1162
- startSmsRegistration: startSmsRegistration,
1163
- listSmsRegistrations: listSmsRegistrations,
1164
- preflightSmsRegistration: preflightSmsRegistration,
1165
- deactivateSmsRegistration: deactivateSmsRegistration,
1166
- getSmsRegistration: getSmsRegistration,
1167
- verifySmsRegistrationOtp: verifySmsRegistrationOtp,
1168
- resendSmsRegistrationOtp: resendSmsRegistrationOtp,
1169
- appealSmsRegistration: appealSmsRegistration,
1170
- respondToSmsRegistrationReview: respondToSmsRegistrationReview,
1171
- uploadSmsOptInProofFile: uploadSmsOptInProofFile,
1172
- uploadSmsOptInProof: uploadSmsOptInProof,
1173
- shareSmsRegistration: shareSmsRegistration,
1174
- enableSmsOnNumber: enableSmsOnNumber,
1175
- disableSmsOnNumber: disableSmsOnNumber,
1176
- reuseSmsRegistrationForNumber: reuseSmsRegistrationForNumber,
1180
+ sendSms: this._bind(sendSms),
1181
+ lookupSmsNumber: this._bind(lookupSmsNumber),
1182
+ listSmsOptOuts: this._bind(listSmsOptOuts),
1183
+ createSmsSenderId: this._bind(createSmsSenderId),
1184
+ listSmsSenderIds: this._bind(listSmsSenderIds),
1185
+ requestSmsSenderIdLimitIncrease: this._bind(requestSmsSenderIdLimitIncrease),
1186
+ deleteSmsSenderId: this._bind(deleteSmsSenderId),
1187
+ startSmsRegistration: this._bind(startSmsRegistration),
1188
+ listSmsRegistrations: this._bind(listSmsRegistrations),
1189
+ preflightSmsRegistration: this._bind(preflightSmsRegistration),
1190
+ deactivateSmsRegistration: this._bind(deactivateSmsRegistration),
1191
+ getSmsRegistration: this._bind(getSmsRegistration),
1192
+ verifySmsRegistrationOtp: this._bind(verifySmsRegistrationOtp),
1193
+ resendSmsRegistrationOtp: this._bind(resendSmsRegistrationOtp),
1194
+ appealSmsRegistration: this._bind(appealSmsRegistration),
1195
+ respondToSmsRegistrationReview: this._bind(respondToSmsRegistrationReview),
1196
+ uploadSmsOptInProofFile: this._bind(uploadSmsOptInProofFile),
1197
+ uploadSmsOptInProof: this._bind(uploadSmsOptInProof),
1198
+ shareSmsRegistration: this._bind(shareSmsRegistration),
1199
+ enableSmsOnNumber: this._bind(enableSmsOnNumber),
1200
+ disableSmsOnNumber: this._bind(disableSmsOnNumber),
1201
+ reuseSmsRegistrationForNumber: this._bind(reuseSmsRegistrationForNumber),
1177
1202
  };
1178
1203
 
1179
1204
  /**
1180
1205
  * whatsapptemplates API
1181
1206
  */
1182
1207
  whatsapptemplates = {
1183
- getWhatsAppLibraryTemplate: getWhatsAppLibraryTemplate,
1208
+ getWhatsAppLibraryTemplate: this._bind(getWhatsAppLibraryTemplate),
1184
1209
  };
1185
1210
 
1186
1211
  /**
1187
1212
  * whatsappphonenumbers API
1188
1213
  */
1189
1214
  whatsappphonenumbers = {
1190
- getWhatsAppNumberInfo: getWhatsAppNumberInfo,
1191
- getWhatsAppPhoneNumbers: getWhatsAppPhoneNumbers,
1192
- purchaseWhatsAppPhoneNumber: purchaseWhatsAppPhoneNumber,
1193
- listWhatsAppNumberCountries: listWhatsAppNumberCountries,
1194
- searchAvailableWhatsAppNumbers: searchAvailableWhatsAppNumbers,
1195
- checkWhatsAppNumberAvailability: checkWhatsAppNumberAvailability,
1196
- getWhatsAppNumberKycForm: getWhatsAppNumberKycForm,
1197
- submitWhatsAppNumberKyc: submitWhatsAppNumberKyc,
1198
- uploadWhatsAppNumberKycDocument: uploadWhatsAppNumberKycDocument,
1199
- validateWhatsAppNumberKycAddress: validateWhatsAppNumberKycAddress,
1200
- createWhatsAppNumberKycLink: createWhatsAppNumberKycLink,
1201
- getWhatsAppNumberRemediation: getWhatsAppNumberRemediation,
1202
- remediateWhatsAppNumber: remediateWhatsAppNumber,
1203
- getWhatsAppPhoneNumber: getWhatsAppPhoneNumber,
1204
- releaseWhatsAppPhoneNumber: releaseWhatsAppPhoneNumber,
1215
+ getWhatsAppNumberInfo: this._bind(getWhatsAppNumberInfo),
1216
+ getWhatsAppPhoneNumbers: this._bind(getWhatsAppPhoneNumbers),
1217
+ purchaseWhatsAppPhoneNumber: this._bind(purchaseWhatsAppPhoneNumber),
1218
+ listWhatsAppNumberCountries: this._bind(listWhatsAppNumberCountries),
1219
+ searchAvailableWhatsAppNumbers: this._bind(searchAvailableWhatsAppNumbers),
1220
+ checkWhatsAppNumberAvailability: this._bind(checkWhatsAppNumberAvailability),
1221
+ getWhatsAppNumberKycForm: this._bind(getWhatsAppNumberKycForm),
1222
+ submitWhatsAppNumberKyc: this._bind(submitWhatsAppNumberKyc),
1223
+ uploadWhatsAppNumberKycDocument: this._bind(uploadWhatsAppNumberKycDocument),
1224
+ validateWhatsAppNumberKycAddress: this._bind(validateWhatsAppNumberKycAddress),
1225
+ createWhatsAppNumberKycLink: this._bind(createWhatsAppNumberKycLink),
1226
+ getWhatsAppNumberRemediation: this._bind(getWhatsAppNumberRemediation),
1227
+ remediateWhatsAppNumber: this._bind(remediateWhatsAppNumber),
1228
+ getWhatsAppPhoneNumber: this._bind(getWhatsAppPhoneNumber),
1229
+ releaseWhatsAppPhoneNumber: this._bind(releaseWhatsAppPhoneNumber),
1205
1230
  };
1206
1231
 
1207
1232
  /**
1208
1233
  * phonenumbers API
1209
1234
  */
1210
1235
  phonenumbers = {
1211
- listPhoneNumbers: listPhoneNumbers,
1212
- getPhoneNumber: getPhoneNumber,
1213
- releasePhoneNumber: releasePhoneNumber,
1214
- purchasePhoneNumber: purchasePhoneNumber,
1215
- listPhoneNumberCountries: listPhoneNumberCountries,
1216
- searchAvailablePhoneNumbers: searchAvailablePhoneNumbers,
1217
- checkPhoneNumberAvailability: checkPhoneNumberAvailability,
1218
- getPhoneNumberKycForm: getPhoneNumberKycForm,
1219
- submitPhoneNumberKyc: submitPhoneNumberKyc,
1220
- viewPhoneNumberKycDocument: viewPhoneNumberKycDocument,
1221
- uploadPhoneNumberKycDocument: uploadPhoneNumberKycDocument,
1222
- validatePhoneNumberKycAddress: validatePhoneNumberKycAddress,
1223
- createPhoneNumberKycLink: createPhoneNumberKycLink,
1224
- createPhoneNumberPortIn: createPhoneNumberPortIn,
1225
- listPhoneNumberPortIns: listPhoneNumberPortIns,
1226
- checkPhoneNumberPortability: checkPhoneNumberPortability,
1227
- uploadPhoneNumberPortInDocument: uploadPhoneNumberPortInDocument,
1228
- getPhoneNumberPortInRequirements: getPhoneNumberPortInRequirements,
1229
- getPhoneNumberPortInOrderRequirements: getPhoneNumberPortInOrderRequirements,
1230
- cancelPhoneNumberPortIn: cancelPhoneNumberPortIn,
1231
- reviewPhoneNumberKycPacket: reviewPhoneNumberKycPacket,
1232
- getPhoneNumberRemediation: getPhoneNumberRemediation,
1233
- remediatePhoneNumber: remediatePhoneNumber,
1234
- replyToPhoneNumberReviewer: replyToPhoneNumberReviewer,
1235
- respondToPhoneNumberReviewer: respondToPhoneNumberReviewer,
1236
+ listPhoneNumbers: this._bind(listPhoneNumbers),
1237
+ getPhoneNumber: this._bind(getPhoneNumber),
1238
+ releasePhoneNumber: this._bind(releasePhoneNumber),
1239
+ purchasePhoneNumber: this._bind(purchasePhoneNumber),
1240
+ listPhoneNumberCountries: this._bind(listPhoneNumberCountries),
1241
+ searchAvailablePhoneNumbers: this._bind(searchAvailablePhoneNumbers),
1242
+ checkPhoneNumberAvailability: this._bind(checkPhoneNumberAvailability),
1243
+ getPhoneNumberKycForm: this._bind(getPhoneNumberKycForm),
1244
+ submitPhoneNumberKyc: this._bind(submitPhoneNumberKyc),
1245
+ viewPhoneNumberKycDocument: this._bind(viewPhoneNumberKycDocument),
1246
+ uploadPhoneNumberKycDocument: this._bind(uploadPhoneNumberKycDocument),
1247
+ validatePhoneNumberKycAddress: this._bind(validatePhoneNumberKycAddress),
1248
+ createPhoneNumberKycLink: this._bind(createPhoneNumberKycLink),
1249
+ createPhoneNumberPortIn: this._bind(createPhoneNumberPortIn),
1250
+ listPhoneNumberPortIns: this._bind(listPhoneNumberPortIns),
1251
+ checkPhoneNumberPortability: this._bind(checkPhoneNumberPortability),
1252
+ uploadPhoneNumberPortInDocument: this._bind(uploadPhoneNumberPortInDocument),
1253
+ getPhoneNumberPortInRequirements: this._bind(getPhoneNumberPortInRequirements),
1254
+ getPhoneNumberPortInOrderRequirements: this._bind(getPhoneNumberPortInOrderRequirements),
1255
+ cancelPhoneNumberPortIn: this._bind(cancelPhoneNumberPortIn),
1256
+ reviewPhoneNumberKycPacket: this._bind(reviewPhoneNumberKycPacket),
1257
+ getPhoneNumberRemediation: this._bind(getPhoneNumberRemediation),
1258
+ remediatePhoneNumber: this._bind(remediatePhoneNumber),
1259
+ replyToPhoneNumberReviewer: this._bind(replyToPhoneNumberReviewer),
1260
+ respondToPhoneNumberReviewer: this._bind(respondToPhoneNumberReviewer),
1236
1261
  };
1237
1262
 
1238
1263
  /**
1239
1264
  * whatsappsandbox API
1240
1265
  */
1241
1266
  whatsappsandbox = {
1242
- listWhatsAppSandboxSessions: listWhatsAppSandboxSessions,
1243
- createWhatsAppSandboxSession: createWhatsAppSandboxSession,
1244
- deleteWhatsAppSandboxSession: deleteWhatsAppSandboxSession,
1267
+ listWhatsAppSandboxSessions: this._bind(listWhatsAppSandboxSessions),
1268
+ createWhatsAppSandboxSession: this._bind(createWhatsAppSandboxSession),
1269
+ deleteWhatsAppSandboxSession: this._bind(deleteWhatsAppSandboxSession),
1245
1270
  };
1246
1271
 
1247
1272
  /**
1248
1273
  * whatsappflows API
1249
1274
  */
1250
1275
  whatsappflows = {
1251
- listWhatsAppFlows: listWhatsAppFlows,
1252
- createWhatsAppFlow: createWhatsAppFlow,
1253
- getWhatsAppFlow: getWhatsAppFlow,
1254
- updateWhatsAppFlow: updateWhatsAppFlow,
1255
- deleteWhatsAppFlow: deleteWhatsAppFlow,
1256
- getWhatsAppFlowJson: getWhatsAppFlowJson,
1257
- uploadWhatsAppFlowJson: uploadWhatsAppFlowJson,
1258
- getWhatsAppFlowPreview: getWhatsAppFlowPreview,
1259
- listWhatsAppFlowVersions: listWhatsAppFlowVersions,
1260
- publishWhatsAppFlow: publishWhatsAppFlow,
1261
- deprecateWhatsAppFlow: deprecateWhatsAppFlow,
1262
- sendWhatsAppFlowMessage: sendWhatsAppFlowMessage,
1263
- listWhatsAppFlowResponses: listWhatsAppFlowResponses,
1276
+ listWhatsAppFlows: this._bind(listWhatsAppFlows),
1277
+ createWhatsAppFlow: this._bind(createWhatsAppFlow),
1278
+ getWhatsAppFlow: this._bind(getWhatsAppFlow),
1279
+ updateWhatsAppFlow: this._bind(updateWhatsAppFlow),
1280
+ deleteWhatsAppFlow: this._bind(deleteWhatsAppFlow),
1281
+ getWhatsAppFlowJson: this._bind(getWhatsAppFlowJson),
1282
+ uploadWhatsAppFlowJson: this._bind(uploadWhatsAppFlowJson),
1283
+ getWhatsAppFlowPreview: this._bind(getWhatsAppFlowPreview),
1284
+ listWhatsAppFlowVersions: this._bind(listWhatsAppFlowVersions),
1285
+ publishWhatsAppFlow: this._bind(publishWhatsAppFlow),
1286
+ deprecateWhatsAppFlow: this._bind(deprecateWhatsAppFlow),
1287
+ sendWhatsAppFlowMessage: this._bind(sendWhatsAppFlowMessage),
1288
+ listWhatsAppFlowResponses: this._bind(listWhatsAppFlowResponses),
1264
1289
  };
1265
1290
 
1266
1291
  /**
1267
1292
  * contacts API
1268
1293
  */
1269
1294
  contacts = {
1270
- listContacts: listContacts,
1271
- createContact: createContact,
1272
- getContact: getContact,
1273
- updateContact: updateContact,
1274
- deleteContact: deleteContact,
1275
- getContactChannels: getContactChannels,
1276
- bulkCreateContacts: bulkCreateContacts,
1295
+ listContacts: this._bind(listContacts),
1296
+ createContact: this._bind(createContact),
1297
+ getContact: this._bind(getContact),
1298
+ updateContact: this._bind(updateContact),
1299
+ deleteContact: this._bind(deleteContact),
1300
+ getContactChannels: this._bind(getContactChannels),
1301
+ bulkCreateContacts: this._bind(bulkCreateContacts),
1277
1302
  };
1278
1303
 
1279
1304
  /**
1280
1305
  * customfields API
1281
1306
  */
1282
1307
  customfields = {
1283
- setContactFieldValue: setContactFieldValue,
1284
- clearContactFieldValue: clearContactFieldValue,
1285
- listCustomFields: listCustomFields,
1286
- createCustomField: createCustomField,
1287
- updateCustomField: updateCustomField,
1288
- deleteCustomField: deleteCustomField,
1308
+ setContactFieldValue: this._bind(setContactFieldValue),
1309
+ clearContactFieldValue: this._bind(clearContactFieldValue),
1310
+ listCustomFields: this._bind(listCustomFields),
1311
+ createCustomField: this._bind(createCustomField),
1312
+ updateCustomField: this._bind(updateCustomField),
1313
+ deleteCustomField: this._bind(deleteCustomField),
1289
1314
  };
1290
1315
 
1291
1316
  /**
1292
1317
  * broadcasts API
1293
1318
  */
1294
1319
  broadcasts = {
1295
- listBroadcasts: listBroadcasts,
1296
- createBroadcast: createBroadcast,
1297
- getBroadcast: getBroadcast,
1298
- updateBroadcast: updateBroadcast,
1299
- deleteBroadcast: deleteBroadcast,
1300
- sendBroadcast: sendBroadcast,
1301
- scheduleBroadcast: scheduleBroadcast,
1302
- cancelBroadcast: cancelBroadcast,
1303
- listBroadcastRecipients: listBroadcastRecipients,
1304
- addBroadcastRecipients: addBroadcastRecipients,
1320
+ listBroadcasts: this._bind(listBroadcasts),
1321
+ createBroadcast: this._bind(createBroadcast),
1322
+ getBroadcast: this._bind(getBroadcast),
1323
+ updateBroadcast: this._bind(updateBroadcast),
1324
+ deleteBroadcast: this._bind(deleteBroadcast),
1325
+ sendBroadcast: this._bind(sendBroadcast),
1326
+ scheduleBroadcast: this._bind(scheduleBroadcast),
1327
+ cancelBroadcast: this._bind(cancelBroadcast),
1328
+ listBroadcastRecipients: this._bind(listBroadcastRecipients),
1329
+ addBroadcastRecipients: this._bind(addBroadcastRecipients),
1305
1330
  };
1306
1331
 
1307
1332
  /**
1308
1333
  * workflows API
1309
1334
  */
1310
1335
  workflows = {
1311
- listWorkflows: listWorkflows,
1312
- createWorkflow: createWorkflow,
1313
- getWorkflow: getWorkflow,
1314
- updateWorkflow: updateWorkflow,
1315
- deleteWorkflow: deleteWorkflow,
1316
- activateWorkflow: activateWorkflow,
1317
- pauseWorkflow: pauseWorkflow,
1318
- listWorkflowExecutions: listWorkflowExecutions,
1319
- triggerWorkflow: triggerWorkflow,
1320
- listWorkflowExecutionEvents: listWorkflowExecutionEvents,
1321
- duplicateWorkflow: duplicateWorkflow,
1322
- listWorkflowVersions: listWorkflowVersions,
1323
- getWorkflowVersion: getWorkflowVersion,
1324
- restoreWorkflowVersion: restoreWorkflowVersion,
1336
+ listWorkflows: this._bind(listWorkflows),
1337
+ createWorkflow: this._bind(createWorkflow),
1338
+ getWorkflow: this._bind(getWorkflow),
1339
+ updateWorkflow: this._bind(updateWorkflow),
1340
+ deleteWorkflow: this._bind(deleteWorkflow),
1341
+ activateWorkflow: this._bind(activateWorkflow),
1342
+ pauseWorkflow: this._bind(pauseWorkflow),
1343
+ listWorkflowExecutions: this._bind(listWorkflowExecutions),
1344
+ triggerWorkflow: this._bind(triggerWorkflow),
1345
+ listWorkflowExecutionEvents: this._bind(listWorkflowExecutionEvents),
1346
+ duplicateWorkflow: this._bind(duplicateWorkflow),
1347
+ listWorkflowVersions: this._bind(listWorkflowVersions),
1348
+ getWorkflowVersion: this._bind(getWorkflowVersion),
1349
+ restoreWorkflowVersion: this._bind(restoreWorkflowVersion),
1325
1350
  };
1326
1351
 
1327
1352
  /**
1328
1353
  * sequences API
1329
1354
  */
1330
1355
  sequences = {
1331
- listSequences: listSequences,
1332
- createSequence: createSequence,
1333
- getSequence: getSequence,
1334
- updateSequence: updateSequence,
1335
- deleteSequence: deleteSequence,
1336
- activateSequence: activateSequence,
1337
- pauseSequence: pauseSequence,
1338
- enrollContacts: enrollContacts,
1339
- unenrollContact: unenrollContact,
1340
- listSequenceEnrollments: listSequenceEnrollments,
1356
+ listSequences: this._bind(listSequences),
1357
+ createSequence: this._bind(createSequence),
1358
+ getSequence: this._bind(getSequence),
1359
+ updateSequence: this._bind(updateSequence),
1360
+ deleteSequence: this._bind(deleteSequence),
1361
+ activateSequence: this._bind(activateSequence),
1362
+ pauseSequence: this._bind(pauseSequence),
1363
+ enrollContacts: this._bind(enrollContacts),
1364
+ unenrollContact: this._bind(unenrollContact),
1365
+ listSequenceEnrollments: this._bind(listSequenceEnrollments),
1341
1366
  };
1342
1367
 
1343
1368
  /**
1344
1369
  * commentautomations API
1345
1370
  */
1346
1371
  commentautomations = {
1347
- listCommentAutomations: listCommentAutomations,
1348
- createCommentAutomation: createCommentAutomation,
1349
- getCommentAutomation: getCommentAutomation,
1350
- updateCommentAutomation: updateCommentAutomation,
1351
- deleteCommentAutomation: deleteCommentAutomation,
1352
- listCommentAutomationLogs: listCommentAutomationLogs,
1372
+ listCommentAutomations: this._bind(listCommentAutomations),
1373
+ createCommentAutomation: this._bind(createCommentAutomation),
1374
+ getCommentAutomation: this._bind(getCommentAutomation),
1375
+ updateCommentAutomation: this._bind(updateCommentAutomation),
1376
+ deleteCommentAutomation: this._bind(deleteCommentAutomation),
1377
+ listCommentAutomationLogs: this._bind(listCommentAutomationLogs),
1353
1378
  };
1354
1379
 
1355
1380
  /**
1356
1381
  * adcampaigns API
1357
1382
  */
1358
1383
  adcampaigns = {
1359
- listAds: listAds,
1360
- listAdKeywords: listAdKeywords,
1361
- listAdCampaigns: listAdCampaigns,
1362
- createAdCampaign: createAdCampaign,
1363
- updateAdCampaignStatus: updateAdCampaignStatus,
1364
- updateAdCampaign: updateAdCampaign,
1365
- deleteAdCampaign: deleteAdCampaign,
1366
- bulkUpdateAdCampaignStatus: bulkUpdateAdCampaignStatus,
1367
- duplicateAdCampaign: duplicateAdCampaign,
1368
- duplicateAdSet: duplicateAdSet,
1369
- duplicateAd: duplicateAd,
1370
- getAdSetDetails: getAdSetDetails,
1371
- updateAdSet: updateAdSet,
1372
- updateAdSetStatus: updateAdSetStatus,
1373
- getAdTree: getAdTree,
1374
- getAdsTimeline: getAdsTimeline,
1375
- getAd: getAd,
1376
- updateAd: updateAd,
1377
- deleteAd: deleteAd,
1378
- updateAdStatus: updateAdStatus,
1379
- boostPost: boostPost,
1380
- createStandaloneAd: createStandaloneAd,
1384
+ listAds: this._bind(listAds),
1385
+ listAdKeywords: this._bind(listAdKeywords),
1386
+ listAdCampaigns: this._bind(listAdCampaigns),
1387
+ createAdCampaign: this._bind(createAdCampaign),
1388
+ updateAdCampaignStatus: this._bind(updateAdCampaignStatus),
1389
+ updateAdCampaign: this._bind(updateAdCampaign),
1390
+ deleteAdCampaign: this._bind(deleteAdCampaign),
1391
+ bulkUpdateAdCampaignStatus: this._bind(bulkUpdateAdCampaignStatus),
1392
+ duplicateAdCampaign: this._bind(duplicateAdCampaign),
1393
+ duplicateAdSet: this._bind(duplicateAdSet),
1394
+ duplicateAd: this._bind(duplicateAd),
1395
+ getAdSetDetails: this._bind(getAdSetDetails),
1396
+ updateAdSet: this._bind(updateAdSet),
1397
+ updateAdSetStatus: this._bind(updateAdSetStatus),
1398
+ getAdTree: this._bind(getAdTree),
1399
+ getAdsTimeline: this._bind(getAdsTimeline),
1400
+ getAd: this._bind(getAd),
1401
+ updateAd: this._bind(updateAd),
1402
+ deleteAd: this._bind(deleteAd),
1403
+ updateAdStatus: this._bind(updateAdStatus),
1404
+ boostPost: this._bind(boostPost),
1405
+ createStandaloneAd: this._bind(createStandaloneAd),
1381
1406
  };
1382
1407
 
1383
1408
  /**
1384
1409
  * adinsights API
1385
1410
  */
1386
1411
  adinsights = {
1387
- getCampaignAnalytics: getCampaignAnalytics,
1388
- generateKeywordIdeas: generateKeywordIdeas,
1389
- generateKeywordHistoricalMetrics: generateKeywordHistoricalMetrics,
1390
- queryAdInsights: queryAdInsights,
1391
- createAdInsightsReport: createAdInsightsReport,
1392
- getAdInsightsReport: getAdInsightsReport,
1393
- getAdAnalytics: getAdAnalytics,
1412
+ getCampaignAnalytics: this._bind(getCampaignAnalytics),
1413
+ generateKeywordIdeas: this._bind(generateKeywordIdeas),
1414
+ generateKeywordHistoricalMetrics: this._bind(generateKeywordHistoricalMetrics),
1415
+ queryAdInsights: this._bind(queryAdInsights),
1416
+ createAdInsightsReport: this._bind(createAdInsightsReport),
1417
+ getAdInsightsReport: this._bind(getAdInsightsReport),
1418
+ getAdAnalytics: this._bind(getAdAnalytics),
1394
1419
  };
1395
1420
 
1396
1421
  /**
1397
1422
  * adcreatives API
1398
1423
  */
1399
1424
  adcreatives = {
1400
- generateAdPreviews: generateAdPreviews,
1401
- getAdPreviews: getAdPreviews,
1402
- listAdCreatives: listAdCreatives,
1403
- createAdCreative: createAdCreative,
1404
- getAdCreative: getAdCreative,
1405
- updateAdCreative: updateAdCreative,
1406
- deleteAdCreative: deleteAdCreative,
1407
- uploadAdImage: uploadAdImage,
1408
- listAdImages: listAdImages,
1409
- listAdCatalogs: listAdCatalogs,
1410
- listAdCatalogProductSets: listAdCatalogProductSets,
1425
+ generateAdPreviews: this._bind(generateAdPreviews),
1426
+ getAdPreviews: this._bind(getAdPreviews),
1427
+ listAdCreatives: this._bind(listAdCreatives),
1428
+ createAdCreative: this._bind(createAdCreative),
1429
+ getAdCreative: this._bind(getAdCreative),
1430
+ updateAdCreative: this._bind(updateAdCreative),
1431
+ deleteAdCreative: this._bind(deleteAdCreative),
1432
+ uploadAdImage: this._bind(uploadAdImage),
1433
+ listAdImages: this._bind(listAdImages),
1434
+ listAdCatalogs: this._bind(listAdCatalogs),
1435
+ listAdCatalogProductSets: this._bind(listAdCatalogProductSets),
1411
1436
  };
1412
1437
 
1413
1438
  /**
1414
1439
  * trackingtags API
1415
1440
  */
1416
1441
  trackingtags = {
1417
- getAdTrackingTags: getAdTrackingTags,
1418
- updateAdTrackingTags: updateAdTrackingTags,
1419
- listTrackingTags: listTrackingTags,
1420
- createTrackingTag: createTrackingTag,
1421
- getTrackingTag: getTrackingTag,
1422
- updateTrackingTag: updateTrackingTag,
1423
- listTrackingTagSharedAccounts: listTrackingTagSharedAccounts,
1424
- addTrackingTagSharedAccount: addTrackingTagSharedAccount,
1425
- removeTrackingTagSharedAccount: removeTrackingTagSharedAccount,
1426
- getTrackingTagStats: getTrackingTagStats,
1442
+ getAdTrackingTags: this._bind(getAdTrackingTags),
1443
+ updateAdTrackingTags: this._bind(updateAdTrackingTags),
1444
+ listTrackingTags: this._bind(listTrackingTags),
1445
+ createTrackingTag: this._bind(createTrackingTag),
1446
+ getTrackingTag: this._bind(getTrackingTag),
1447
+ updateTrackingTag: this._bind(updateTrackingTag),
1448
+ listTrackingTagSharedAccounts: this._bind(listTrackingTagSharedAccounts),
1449
+ addTrackingTagSharedAccount: this._bind(addTrackingTagSharedAccount),
1450
+ removeTrackingTagSharedAccount: this._bind(removeTrackingTagSharedAccount),
1451
+ getTrackingTagStats: this._bind(getTrackingTagStats),
1427
1452
  };
1428
1453
 
1429
1454
  /**
1430
1455
  * adaccounts API
1431
1456
  */
1432
1457
  adaccounts = {
1433
- getAdComments: getAdComments,
1434
- listAdsBusinessCenters: listAdsBusinessCenters,
1435
- getAdsActivityLog: getAdsActivityLog,
1436
- listAdStudies: listAdStudies,
1437
- listMetaBusinesses: listMetaBusinesses,
1438
- listAdLabels: listAdLabels,
1439
- listHighDemandPeriods: listHighDemandPeriods,
1440
- listValueRuleSets: listValueRuleSets,
1441
- createValueRuleSet: createValueRuleSet,
1442
- getValueRuleSet: getValueRuleSet,
1443
- updateValueRuleSet: updateValueRuleSet,
1444
- deleteValueRuleSet: deleteValueRuleSet,
1445
- getAdAccountFinance: getAdAccountFinance,
1446
- listAdAccounts: listAdAccounts,
1447
- updateAdAccount: updateAdAccount,
1448
- getDsaDefaults: getDsaDefaults,
1449
- getDsaRecommendations: getDsaRecommendations,
1458
+ getAdComments: this._bind(getAdComments),
1459
+ listAdsBusinessCenters: this._bind(listAdsBusinessCenters),
1460
+ getAdsActivityLog: this._bind(getAdsActivityLog),
1461
+ listAdStudies: this._bind(listAdStudies),
1462
+ listMetaBusinesses: this._bind(listMetaBusinesses),
1463
+ listAdLabels: this._bind(listAdLabels),
1464
+ listHighDemandPeriods: this._bind(listHighDemandPeriods),
1465
+ listValueRuleSets: this._bind(listValueRuleSets),
1466
+ createValueRuleSet: this._bind(createValueRuleSet),
1467
+ getValueRuleSet: this._bind(getValueRuleSet),
1468
+ updateValueRuleSet: this._bind(updateValueRuleSet),
1469
+ deleteValueRuleSet: this._bind(deleteValueRuleSet),
1470
+ getAdAccountFinance: this._bind(getAdAccountFinance),
1471
+ listAdAccounts: this._bind(listAdAccounts),
1472
+ updateAdAccount: this._bind(updateAdAccount),
1473
+ getDsaDefaults: this._bind(getDsaDefaults),
1474
+ getDsaRecommendations: this._bind(getDsaRecommendations),
1450
1475
  };
1451
1476
 
1452
1477
  /**
1453
1478
  * reachandfrequency API
1454
1479
  */
1455
1480
  reachandfrequency = {
1456
- createRfPrediction: createRfPrediction,
1457
- getRfPrediction: getRfPrediction,
1458
- cancelRfReservation: cancelRfReservation,
1459
- reserveRfPrediction: reserveRfPrediction,
1481
+ createRfPrediction: this._bind(createRfPrediction),
1482
+ getRfPrediction: this._bind(getRfPrediction),
1483
+ cancelRfReservation: this._bind(cancelRfReservation),
1484
+ reserveRfPrediction: this._bind(reserveRfPrediction),
1460
1485
  };
1461
1486
 
1462
1487
  /**
1463
1488
  * leadgen API
1464
1489
  */
1465
1490
  leadgen = {
1466
- listLeads: listLeads,
1467
- listLeadForms: listLeadForms,
1468
- createLeadForm: createLeadForm,
1469
- getLeadForm: getLeadForm,
1470
- archiveLeadForm: archiveLeadForm,
1471
- listFormLeads: listFormLeads,
1472
- createTestLead: createTestLead,
1491
+ listLeads: this._bind(listLeads),
1492
+ listLeadForms: this._bind(listLeadForms),
1493
+ createLeadForm: this._bind(createLeadForm),
1494
+ getLeadForm: this._bind(getLeadForm),
1495
+ archiveLeadForm: this._bind(archiveLeadForm),
1496
+ listFormLeads: this._bind(listFormLeads),
1497
+ createTestLead: this._bind(createTestLead),
1473
1498
  };
1474
1499
 
1475
1500
  /**
1476
1501
  * adtargeting API
1477
1502
  */
1478
1503
  adtargeting = {
1479
- searchAdInterests: searchAdInterests,
1480
- searchAdTargeting: searchAdTargeting,
1481
- estimateAdReach: estimateAdReach,
1482
- getLinkedInBidPricing: getLinkedInBidPricing,
1483
- getLinkedInSupplyForecast: getLinkedInSupplyForecast,
1504
+ searchAdInterests: this._bind(searchAdInterests),
1505
+ searchAdTargeting: this._bind(searchAdTargeting),
1506
+ estimateAdReach: this._bind(estimateAdReach),
1507
+ getLinkedInBidPricing: this._bind(getLinkedInBidPricing),
1508
+ getLinkedInSupplyForecast: this._bind(getLinkedInSupplyForecast),
1484
1509
  };
1485
1510
 
1486
1511
  /**
1487
1512
  * adaudiences API
1488
1513
  */
1489
1514
  adaudiences = {
1490
- listAdAudiences: listAdAudiences,
1491
- createAdAudience: createAdAudience,
1492
- getAdAudience: getAdAudience,
1493
- updateAdAudience: updateAdAudience,
1494
- deleteAdAudience: deleteAdAudience,
1495
- addUsersToAdAudience: addUsersToAdAudience,
1515
+ listAdAudiences: this._bind(listAdAudiences),
1516
+ createAdAudience: this._bind(createAdAudience),
1517
+ getAdAudience: this._bind(getAdAudience),
1518
+ updateAdAudience: this._bind(updateAdAudience),
1519
+ deleteAdAudience: this._bind(deleteAdAudience),
1520
+ addUsersToAdAudience: this._bind(addUsersToAdAudience),
1496
1521
  };
1497
1522
 
1498
1523
  /**
1499
1524
  * conversions API
1500
1525
  */
1501
1526
  conversions = {
1502
- getConversionsQuality: getConversionsQuality,
1503
- sendConversions: sendConversions,
1504
- adjustConversions: adjustConversions,
1505
- listConversionDestinations: listConversionDestinations,
1506
- createConversionDestination: createConversionDestination,
1507
- getConversionDestination: getConversionDestination,
1508
- updateConversionDestination: updateConversionDestination,
1509
- deleteConversionDestination: deleteConversionDestination,
1510
- listConversionAssociations: listConversionAssociations,
1511
- addConversionAssociations: addConversionAssociations,
1512
- removeConversionAssociations: removeConversionAssociations,
1513
- getConversionMetrics: getConversionMetrics,
1527
+ getConversionsQuality: this._bind(getConversionsQuality),
1528
+ sendConversions: this._bind(sendConversions),
1529
+ adjustConversions: this._bind(adjustConversions),
1530
+ listConversionDestinations: this._bind(listConversionDestinations),
1531
+ createConversionDestination: this._bind(createConversionDestination),
1532
+ getConversionDestination: this._bind(getConversionDestination),
1533
+ updateConversionDestination: this._bind(updateConversionDestination),
1534
+ deleteConversionDestination: this._bind(deleteConversionDestination),
1535
+ listConversionAssociations: this._bind(listConversionAssociations),
1536
+ addConversionAssociations: this._bind(addConversionAssociations),
1537
+ removeConversionAssociations: this._bind(removeConversionAssociations),
1538
+ getConversionMetrics: this._bind(getConversionMetrics),
1514
1539
  };
1515
1540
 
1516
1541
  /**
1517
1542
  * messagingads API
1518
1543
  */
1519
1544
  messagingads = {
1520
- createMessagingAd: createMessagingAd,
1521
- createCallAd: createCallAd,
1522
- createCtwaAd: createCtwaAd,
1545
+ createMessagingAd: this._bind(createMessagingAd),
1546
+ createCallAd: this._bind(createCallAd),
1547
+ createCtwaAd: this._bind(createCtwaAd),
1523
1548
  };
1524
1549
 
1525
1550
  /**
1526
1551
  * verify API
1527
1552
  */
1528
1553
  verify = {
1529
- createVerification: createVerification,
1530
- getVerification: getVerification,
1531
- checkVerification: checkVerification,
1554
+ createVerification: this._bind(createVerification),
1555
+ getVerification: this._bind(getVerification),
1556
+ checkVerification: this._bind(checkVerification),
1532
1557
  };
1533
1558
 
1534
1559
  /**
@@ -1538,213 +1563,213 @@ export class Zernio {
1538
1563
  */
1539
1564
  ads = {
1540
1565
  /** @deprecated Use `zernio.adcampaigns.listAds` instead. */
1541
- listAds: listAds,
1566
+ listAds: this._bind(listAds),
1542
1567
  /** @deprecated Use `zernio.adcampaigns.listAdKeywords` instead. */
1543
- listAdKeywords: listAdKeywords,
1568
+ listAdKeywords: this._bind(listAdKeywords),
1544
1569
  /** @deprecated Use `zernio.adcampaigns.listAdCampaigns` instead. */
1545
- listAdCampaigns: listAdCampaigns,
1570
+ listAdCampaigns: this._bind(listAdCampaigns),
1546
1571
  /** @deprecated Use `zernio.adcampaigns.createAdCampaign` instead. */
1547
- createAdCampaign: createAdCampaign,
1572
+ createAdCampaign: this._bind(createAdCampaign),
1548
1573
  /** @deprecated Use `zernio.adcampaigns.updateAdCampaignStatus` instead. */
1549
- updateAdCampaignStatus: updateAdCampaignStatus,
1574
+ updateAdCampaignStatus: this._bind(updateAdCampaignStatus),
1550
1575
  /** @deprecated Use `zernio.adcampaigns.updateAdCampaign` instead. */
1551
- updateAdCampaign: updateAdCampaign,
1576
+ updateAdCampaign: this._bind(updateAdCampaign),
1552
1577
  /** @deprecated Use `zernio.adcampaigns.deleteAdCampaign` instead. */
1553
- deleteAdCampaign: deleteAdCampaign,
1578
+ deleteAdCampaign: this._bind(deleteAdCampaign),
1554
1579
  /** @deprecated Use `zernio.adcampaigns.bulkUpdateAdCampaignStatus` instead. */
1555
- bulkUpdateAdCampaignStatus: bulkUpdateAdCampaignStatus,
1580
+ bulkUpdateAdCampaignStatus: this._bind(bulkUpdateAdCampaignStatus),
1556
1581
  /** @deprecated Use `zernio.adcampaigns.duplicateAdCampaign` instead. */
1557
- duplicateAdCampaign: duplicateAdCampaign,
1582
+ duplicateAdCampaign: this._bind(duplicateAdCampaign),
1558
1583
  /** @deprecated Use `zernio.adcampaigns.duplicateAdSet` instead. */
1559
- duplicateAdSet: duplicateAdSet,
1584
+ duplicateAdSet: this._bind(duplicateAdSet),
1560
1585
  /** @deprecated Use `zernio.adcampaigns.duplicateAd` instead. */
1561
- duplicateAd: duplicateAd,
1586
+ duplicateAd: this._bind(duplicateAd),
1562
1587
  /** @deprecated Use `zernio.adcampaigns.getAdSetDetails` instead. */
1563
- getAdSetDetails: getAdSetDetails,
1588
+ getAdSetDetails: this._bind(getAdSetDetails),
1564
1589
  /** @deprecated Use `zernio.adcampaigns.updateAdSet` instead. */
1565
- updateAdSet: updateAdSet,
1590
+ updateAdSet: this._bind(updateAdSet),
1566
1591
  /** @deprecated Use `zernio.adcampaigns.updateAdSetStatus` instead. */
1567
- updateAdSetStatus: updateAdSetStatus,
1592
+ updateAdSetStatus: this._bind(updateAdSetStatus),
1568
1593
  /** @deprecated Use `zernio.adcampaigns.getAdTree` instead. */
1569
- getAdTree: getAdTree,
1594
+ getAdTree: this._bind(getAdTree),
1570
1595
  /** @deprecated Use `zernio.adcampaigns.getAdsTimeline` instead. */
1571
- getAdsTimeline: getAdsTimeline,
1596
+ getAdsTimeline: this._bind(getAdsTimeline),
1572
1597
  /** @deprecated Use `zernio.adcampaigns.getAd` instead. */
1573
- getAd: getAd,
1598
+ getAd: this._bind(getAd),
1574
1599
  /** @deprecated Use `zernio.adcampaigns.updateAd` instead. */
1575
- updateAd: updateAd,
1600
+ updateAd: this._bind(updateAd),
1576
1601
  /** @deprecated Use `zernio.adcampaigns.deleteAd` instead. */
1577
- deleteAd: deleteAd,
1602
+ deleteAd: this._bind(deleteAd),
1578
1603
  /** @deprecated Use `zernio.adcampaigns.updateAdStatus` instead. */
1579
- updateAdStatus: updateAdStatus,
1604
+ updateAdStatus: this._bind(updateAdStatus),
1580
1605
  /** @deprecated Use `zernio.adcampaigns.boostPost` instead. */
1581
- boostPost: boostPost,
1606
+ boostPost: this._bind(boostPost),
1582
1607
  /** @deprecated Use `zernio.adcampaigns.createStandaloneAd` instead. */
1583
- createStandaloneAd: createStandaloneAd,
1608
+ createStandaloneAd: this._bind(createStandaloneAd),
1584
1609
  /** @deprecated Use `zernio.adaccounts.getAdComments` instead. */
1585
- getAdComments: getAdComments,
1610
+ getAdComments: this._bind(getAdComments),
1586
1611
  /** @deprecated Use `zernio.adaccounts.listAdsBusinessCenters` instead. */
1587
- listAdsBusinessCenters: listAdsBusinessCenters,
1612
+ listAdsBusinessCenters: this._bind(listAdsBusinessCenters),
1588
1613
  /** @deprecated Use `zernio.adaccounts.getAdsActivityLog` instead. */
1589
- getAdsActivityLog: getAdsActivityLog,
1614
+ getAdsActivityLog: this._bind(getAdsActivityLog),
1590
1615
  /** @deprecated Use `zernio.adaccounts.listAdStudies` instead. */
1591
- listAdStudies: listAdStudies,
1616
+ listAdStudies: this._bind(listAdStudies),
1592
1617
  /** @deprecated Use `zernio.adaccounts.listMetaBusinesses` instead. */
1593
- listMetaBusinesses: listMetaBusinesses,
1618
+ listMetaBusinesses: this._bind(listMetaBusinesses),
1594
1619
  /** @deprecated Use `zernio.adaccounts.listAdLabels` instead. */
1595
- listAdLabels: listAdLabels,
1620
+ listAdLabels: this._bind(listAdLabels),
1596
1621
  /** @deprecated Use `zernio.adaccounts.listHighDemandPeriods` instead. */
1597
- listHighDemandPeriods: listHighDemandPeriods,
1622
+ listHighDemandPeriods: this._bind(listHighDemandPeriods),
1598
1623
  /** @deprecated Use `zernio.adaccounts.listValueRuleSets` instead. */
1599
- listValueRuleSets: listValueRuleSets,
1624
+ listValueRuleSets: this._bind(listValueRuleSets),
1600
1625
  /** @deprecated Use `zernio.adaccounts.createValueRuleSet` instead. */
1601
- createValueRuleSet: createValueRuleSet,
1626
+ createValueRuleSet: this._bind(createValueRuleSet),
1602
1627
  /** @deprecated Use `zernio.adaccounts.getValueRuleSet` instead. */
1603
- getValueRuleSet: getValueRuleSet,
1628
+ getValueRuleSet: this._bind(getValueRuleSet),
1604
1629
  /** @deprecated Use `zernio.adaccounts.updateValueRuleSet` instead. */
1605
- updateValueRuleSet: updateValueRuleSet,
1630
+ updateValueRuleSet: this._bind(updateValueRuleSet),
1606
1631
  /** @deprecated Use `zernio.adaccounts.deleteValueRuleSet` instead. */
1607
- deleteValueRuleSet: deleteValueRuleSet,
1632
+ deleteValueRuleSet: this._bind(deleteValueRuleSet),
1608
1633
  /** @deprecated Use `zernio.adaccounts.getAdAccountFinance` instead. */
1609
- getAdAccountFinance: getAdAccountFinance,
1634
+ getAdAccountFinance: this._bind(getAdAccountFinance),
1610
1635
  /** @deprecated Use `zernio.adaccounts.listAdAccounts` instead. */
1611
- listAdAccounts: listAdAccounts,
1636
+ listAdAccounts: this._bind(listAdAccounts),
1612
1637
  /** @deprecated Use `zernio.adaccounts.updateAdAccount` instead. */
1613
- updateAdAccount: updateAdAccount,
1638
+ updateAdAccount: this._bind(updateAdAccount),
1614
1639
  /** @deprecated Use `zernio.adaccounts.getDsaDefaults` instead. */
1615
- getDsaDefaults: getDsaDefaults,
1640
+ getDsaDefaults: this._bind(getDsaDefaults),
1616
1641
  /** @deprecated Use `zernio.adaccounts.getDsaRecommendations` instead. */
1617
- getDsaRecommendations: getDsaRecommendations,
1642
+ getDsaRecommendations: this._bind(getDsaRecommendations),
1618
1643
  /** @deprecated Use `zernio.adcreatives.generateAdPreviews` instead. */
1619
- generateAdPreviews: generateAdPreviews,
1644
+ generateAdPreviews: this._bind(generateAdPreviews),
1620
1645
  /** @deprecated Use `zernio.adcreatives.getAdPreviews` instead. */
1621
- getAdPreviews: getAdPreviews,
1646
+ getAdPreviews: this._bind(getAdPreviews),
1622
1647
  /** @deprecated Use `zernio.adcreatives.listAdCreatives` instead. */
1623
- listAdCreatives: listAdCreatives,
1648
+ listAdCreatives: this._bind(listAdCreatives),
1624
1649
  /** @deprecated Use `zernio.adcreatives.createAdCreative` instead. */
1625
- createAdCreative: createAdCreative,
1650
+ createAdCreative: this._bind(createAdCreative),
1626
1651
  /** @deprecated Use `zernio.adcreatives.getAdCreative` instead. */
1627
- getAdCreative: getAdCreative,
1652
+ getAdCreative: this._bind(getAdCreative),
1628
1653
  /** @deprecated Use `zernio.adcreatives.updateAdCreative` instead. */
1629
- updateAdCreative: updateAdCreative,
1654
+ updateAdCreative: this._bind(updateAdCreative),
1630
1655
  /** @deprecated Use `zernio.adcreatives.deleteAdCreative` instead. */
1631
- deleteAdCreative: deleteAdCreative,
1656
+ deleteAdCreative: this._bind(deleteAdCreative),
1632
1657
  /** @deprecated Use `zernio.adcreatives.uploadAdImage` instead. */
1633
- uploadAdImage: uploadAdImage,
1658
+ uploadAdImage: this._bind(uploadAdImage),
1634
1659
  /** @deprecated Use `zernio.adcreatives.listAdImages` instead. */
1635
- listAdImages: listAdImages,
1660
+ listAdImages: this._bind(listAdImages),
1636
1661
  /** @deprecated Use `zernio.adcreatives.listAdCatalogs` instead. */
1637
- listAdCatalogs: listAdCatalogs,
1662
+ listAdCatalogs: this._bind(listAdCatalogs),
1638
1663
  /** @deprecated Use `zernio.adcreatives.listAdCatalogProductSets` instead. */
1639
- listAdCatalogProductSets: listAdCatalogProductSets,
1664
+ listAdCatalogProductSets: this._bind(listAdCatalogProductSets),
1640
1665
  /** @deprecated Use `zernio.adaudiences.listAdAudiences` instead. */
1641
- listAdAudiences: listAdAudiences,
1666
+ listAdAudiences: this._bind(listAdAudiences),
1642
1667
  /** @deprecated Use `zernio.adaudiences.createAdAudience` instead. */
1643
- createAdAudience: createAdAudience,
1668
+ createAdAudience: this._bind(createAdAudience),
1644
1669
  /** @deprecated Use `zernio.adaudiences.getAdAudience` instead. */
1645
- getAdAudience: getAdAudience,
1670
+ getAdAudience: this._bind(getAdAudience),
1646
1671
  /** @deprecated Use `zernio.adaudiences.updateAdAudience` instead. */
1647
- updateAdAudience: updateAdAudience,
1672
+ updateAdAudience: this._bind(updateAdAudience),
1648
1673
  /** @deprecated Use `zernio.adaudiences.deleteAdAudience` instead. */
1649
- deleteAdAudience: deleteAdAudience,
1674
+ deleteAdAudience: this._bind(deleteAdAudience),
1650
1675
  /** @deprecated Use `zernio.adaudiences.addUsersToAdAudience` instead. */
1651
- addUsersToAdAudience: addUsersToAdAudience,
1676
+ addUsersToAdAudience: this._bind(addUsersToAdAudience),
1652
1677
  /** @deprecated Use `zernio.adtargeting.searchAdInterests` instead. */
1653
- searchAdInterests: searchAdInterests,
1678
+ searchAdInterests: this._bind(searchAdInterests),
1654
1679
  /** @deprecated Use `zernio.adtargeting.searchAdTargeting` instead. */
1655
- searchAdTargeting: searchAdTargeting,
1680
+ searchAdTargeting: this._bind(searchAdTargeting),
1656
1681
  /** @deprecated Use `zernio.adtargeting.estimateAdReach` instead. */
1657
- estimateAdReach: estimateAdReach,
1682
+ estimateAdReach: this._bind(estimateAdReach),
1658
1683
  /** @deprecated Use `zernio.adtargeting.getLinkedInBidPricing` instead. */
1659
- getLinkedInBidPricing: getLinkedInBidPricing,
1684
+ getLinkedInBidPricing: this._bind(getLinkedInBidPricing),
1660
1685
  /** @deprecated Use `zernio.adtargeting.getLinkedInSupplyForecast` instead. */
1661
- getLinkedInSupplyForecast: getLinkedInSupplyForecast,
1686
+ getLinkedInSupplyForecast: this._bind(getLinkedInSupplyForecast),
1662
1687
  /** @deprecated Use `zernio.adinsights.getCampaignAnalytics` instead. */
1663
- getCampaignAnalytics: getCampaignAnalytics,
1688
+ getCampaignAnalytics: this._bind(getCampaignAnalytics),
1664
1689
  /** @deprecated Use `zernio.adinsights.generateKeywordIdeas` instead. */
1665
- generateKeywordIdeas: generateKeywordIdeas,
1690
+ generateKeywordIdeas: this._bind(generateKeywordIdeas),
1666
1691
  /** @deprecated Use `zernio.adinsights.generateKeywordHistoricalMetrics` instead. */
1667
- generateKeywordHistoricalMetrics: generateKeywordHistoricalMetrics,
1692
+ generateKeywordHistoricalMetrics: this._bind(generateKeywordHistoricalMetrics),
1668
1693
  /** @deprecated Use `zernio.adinsights.queryAdInsights` instead. */
1669
- queryAdInsights: queryAdInsights,
1694
+ queryAdInsights: this._bind(queryAdInsights),
1670
1695
  /** @deprecated Use `zernio.adinsights.createAdInsightsReport` instead. */
1671
- createAdInsightsReport: createAdInsightsReport,
1696
+ createAdInsightsReport: this._bind(createAdInsightsReport),
1672
1697
  /** @deprecated Use `zernio.adinsights.getAdInsightsReport` instead. */
1673
- getAdInsightsReport: getAdInsightsReport,
1698
+ getAdInsightsReport: this._bind(getAdInsightsReport),
1674
1699
  /** @deprecated Use `zernio.adinsights.getAdAnalytics` instead. */
1675
- getAdAnalytics: getAdAnalytics,
1700
+ getAdAnalytics: this._bind(getAdAnalytics),
1676
1701
  /** @deprecated Use `zernio.conversions.getConversionsQuality` instead. */
1677
- getConversionsQuality: getConversionsQuality,
1702
+ getConversionsQuality: this._bind(getConversionsQuality),
1678
1703
  /** @deprecated Use `zernio.conversions.sendConversions` instead. */
1679
- sendConversions: sendConversions,
1704
+ sendConversions: this._bind(sendConversions),
1680
1705
  /** @deprecated Use `zernio.conversions.adjustConversions` instead. */
1681
- adjustConversions: adjustConversions,
1706
+ adjustConversions: this._bind(adjustConversions),
1682
1707
  /** @deprecated Use `zernio.conversions.listConversionDestinations` instead. */
1683
- listConversionDestinations: listConversionDestinations,
1708
+ listConversionDestinations: this._bind(listConversionDestinations),
1684
1709
  /** @deprecated Use `zernio.conversions.createConversionDestination` instead. */
1685
- createConversionDestination: createConversionDestination,
1710
+ createConversionDestination: this._bind(createConversionDestination),
1686
1711
  /** @deprecated Use `zernio.conversions.getConversionDestination` instead. */
1687
- getConversionDestination: getConversionDestination,
1712
+ getConversionDestination: this._bind(getConversionDestination),
1688
1713
  /** @deprecated Use `zernio.conversions.updateConversionDestination` instead. */
1689
- updateConversionDestination: updateConversionDestination,
1714
+ updateConversionDestination: this._bind(updateConversionDestination),
1690
1715
  /** @deprecated Use `zernio.conversions.deleteConversionDestination` instead. */
1691
- deleteConversionDestination: deleteConversionDestination,
1716
+ deleteConversionDestination: this._bind(deleteConversionDestination),
1692
1717
  /** @deprecated Use `zernio.conversions.listConversionAssociations` instead. */
1693
- listConversionAssociations: listConversionAssociations,
1718
+ listConversionAssociations: this._bind(listConversionAssociations),
1694
1719
  /** @deprecated Use `zernio.conversions.addConversionAssociations` instead. */
1695
- addConversionAssociations: addConversionAssociations,
1720
+ addConversionAssociations: this._bind(addConversionAssociations),
1696
1721
  /** @deprecated Use `zernio.conversions.removeConversionAssociations` instead. */
1697
- removeConversionAssociations: removeConversionAssociations,
1722
+ removeConversionAssociations: this._bind(removeConversionAssociations),
1698
1723
  /** @deprecated Use `zernio.conversions.getConversionMetrics` instead. */
1699
- getConversionMetrics: getConversionMetrics,
1724
+ getConversionMetrics: this._bind(getConversionMetrics),
1700
1725
  /** @deprecated Use `zernio.messagingads.createMessagingAd` instead. */
1701
- createMessagingAd: createMessagingAd,
1726
+ createMessagingAd: this._bind(createMessagingAd),
1702
1727
  /** @deprecated Use `zernio.messagingads.createCallAd` instead. */
1703
- createCallAd: createCallAd,
1728
+ createCallAd: this._bind(createCallAd),
1704
1729
  /** @deprecated Use `zernio.messagingads.createCtwaAd` instead. */
1705
- createCtwaAd: createCtwaAd,
1730
+ createCtwaAd: this._bind(createCtwaAd),
1706
1731
  /** @deprecated Use `zernio.reachandfrequency.createRfPrediction` instead. */
1707
- createRfPrediction: createRfPrediction,
1732
+ createRfPrediction: this._bind(createRfPrediction),
1708
1733
  /** @deprecated Use `zernio.reachandfrequency.getRfPrediction` instead. */
1709
- getRfPrediction: getRfPrediction,
1734
+ getRfPrediction: this._bind(getRfPrediction),
1710
1735
  /** @deprecated Use `zernio.reachandfrequency.cancelRfReservation` instead. */
1711
- cancelRfReservation: cancelRfReservation,
1736
+ cancelRfReservation: this._bind(cancelRfReservation),
1712
1737
  /** @deprecated Use `zernio.reachandfrequency.reserveRfPrediction` instead. */
1713
- reserveRfPrediction: reserveRfPrediction,
1738
+ reserveRfPrediction: this._bind(reserveRfPrediction),
1714
1739
  /** @deprecated Use `zernio.leadgen.listLeads` instead. */
1715
- listLeads: listLeads,
1740
+ listLeads: this._bind(listLeads),
1716
1741
  /** @deprecated Use `zernio.leadgen.listLeadForms` instead. */
1717
- listLeadForms: listLeadForms,
1742
+ listLeadForms: this._bind(listLeadForms),
1718
1743
  /** @deprecated Use `zernio.leadgen.createLeadForm` instead. */
1719
- createLeadForm: createLeadForm,
1744
+ createLeadForm: this._bind(createLeadForm),
1720
1745
  /** @deprecated Use `zernio.leadgen.getLeadForm` instead. */
1721
- getLeadForm: getLeadForm,
1746
+ getLeadForm: this._bind(getLeadForm),
1722
1747
  /** @deprecated Use `zernio.leadgen.archiveLeadForm` instead. */
1723
- archiveLeadForm: archiveLeadForm,
1748
+ archiveLeadForm: this._bind(archiveLeadForm),
1724
1749
  /** @deprecated Use `zernio.leadgen.listFormLeads` instead. */
1725
- listFormLeads: listFormLeads,
1750
+ listFormLeads: this._bind(listFormLeads),
1726
1751
  /** @deprecated Use `zernio.leadgen.createTestLead` instead. */
1727
- createTestLead: createTestLead,
1752
+ createTestLead: this._bind(createTestLead),
1728
1753
  /** @deprecated Use `zernio.trackingtags.getAdTrackingTags` instead. */
1729
- getAdTrackingTags: getAdTrackingTags,
1754
+ getAdTrackingTags: this._bind(getAdTrackingTags),
1730
1755
  /** @deprecated Use `zernio.trackingtags.updateAdTrackingTags` instead. */
1731
- updateAdTrackingTags: updateAdTrackingTags,
1756
+ updateAdTrackingTags: this._bind(updateAdTrackingTags),
1732
1757
  /** @deprecated Use `zernio.trackingtags.listTrackingTags` instead. */
1733
- listTrackingTags: listTrackingTags,
1758
+ listTrackingTags: this._bind(listTrackingTags),
1734
1759
  /** @deprecated Use `zernio.trackingtags.createTrackingTag` instead. */
1735
- createTrackingTag: createTrackingTag,
1760
+ createTrackingTag: this._bind(createTrackingTag),
1736
1761
  /** @deprecated Use `zernio.trackingtags.getTrackingTag` instead. */
1737
- getTrackingTag: getTrackingTag,
1762
+ getTrackingTag: this._bind(getTrackingTag),
1738
1763
  /** @deprecated Use `zernio.trackingtags.updateTrackingTag` instead. */
1739
- updateTrackingTag: updateTrackingTag,
1764
+ updateTrackingTag: this._bind(updateTrackingTag),
1740
1765
  /** @deprecated Use `zernio.trackingtags.listTrackingTagSharedAccounts` instead. */
1741
- listTrackingTagSharedAccounts: listTrackingTagSharedAccounts,
1766
+ listTrackingTagSharedAccounts: this._bind(listTrackingTagSharedAccounts),
1742
1767
  /** @deprecated Use `zernio.trackingtags.addTrackingTagSharedAccount` instead. */
1743
- addTrackingTagSharedAccount: addTrackingTagSharedAccount,
1768
+ addTrackingTagSharedAccount: this._bind(addTrackingTagSharedAccount),
1744
1769
  /** @deprecated Use `zernio.trackingtags.removeTrackingTagSharedAccount` instead. */
1745
- removeTrackingTagSharedAccount: removeTrackingTagSharedAccount,
1770
+ removeTrackingTagSharedAccount: this._bind(removeTrackingTagSharedAccount),
1746
1771
  /** @deprecated Use `zernio.trackingtags.getTrackingTagStats` instead. */
1747
- getTrackingTagStats: getTrackingTagStats,
1772
+ getTrackingTagStats: this._bind(getTrackingTagStats),
1748
1773
  };
1749
1774
 
1750
1775
  /**
@@ -1768,26 +1793,32 @@ export class Zernio {
1768
1793
  this.baseURL = options.baseURL ?? 'https://zernio.com/api';
1769
1794
  this._options = options;
1770
1795
 
1771
- // Configure the generated client. User-Agent and defaultHeaders are
1772
- // applied at config time (not via the interceptor) because Node 20's
1773
- // undici treats User-Agent as a forbidden header on already-constructed
1774
- // Request objects, silently dropping `headers.set('User-Agent', …)`.
1775
- client.setConfig({
1776
- baseUrl: this.baseURL,
1777
- headers: {
1778
- 'User-Agent': `zernio-node/${packageJson.version}`,
1779
- ...(options.defaultHeaders ?? {}),
1780
- },
1781
- });
1796
+ // One client per instance. Interceptors used to be registered on the
1797
+ // module-global client, so every `new Zernio()` stacked another auth
1798
+ // interceptor on the same shared client and the last-constructed key won
1799
+ // for ALL in-flight requests — one tenant's call could carry another
1800
+ // tenant's token. User-Agent and defaultHeaders are applied at config time
1801
+ // (not via the interceptor) because Node 20's undici treats User-Agent as a
1802
+ // forbidden header on already-constructed Request objects, silently
1803
+ // dropping `headers.set('User-Agent', …)`.
1804
+ this._client = createClient(
1805
+ createConfig({
1806
+ baseUrl: this.baseURL,
1807
+ headers: {
1808
+ 'User-Agent': `zernio-node/${packageJson.version}`,
1809
+ ...(options.defaultHeaders ?? {}),
1810
+ },
1811
+ })
1812
+ );
1782
1813
 
1783
1814
  // Add auth interceptor
1784
- client.interceptors.request.use((request) => {
1815
+ this._client.interceptors.request.use((request) => {
1785
1816
  request.headers.set('Authorization', `Bearer ${this.apiKey}`);
1786
1817
  return request;
1787
1818
  });
1788
1819
 
1789
1820
  // Add error handling interceptor
1790
- client.interceptors.response.use(async (response) => {
1821
+ this._client.interceptors.response.use(async (response) => {
1791
1822
  if (!response.ok) {
1792
1823
  let body: Record<string, unknown> | undefined;
1793
1824
  try {