@verdocs/js-sdk 4.2.0 → 4.2.1

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/dist/index.d.mts CHANGED
@@ -1,8 +1,131 @@
1
1
  import { AxiosInstance } from "axios";
2
- type TTemplatePermission = "template:creator:create:public" | "template:creator:create:org" | "template:creator:create:personal" | "template:creator:delete" | "template:creator:visibility" | "template:member:read" | "template:member:write" | "template:member:delete" | "template:member:visibility";
3
- type TAccountPermission = "owner:add" | "owner:remove" | "admin:add" | "admin:remove" | "member:view" | "member:add" | "member:remove";
4
- type TOrgPermission = "org:create" | "org:view" | "org:update" | "org:delete" | "org:transfer" | "org:list";
5
- type TEnvelopePermission = "envelope:create" | "envelope:cancel" | "envelope:view";
2
+ /**
3
+ * Create public templates. Public templates are still owned and managed by the creator,
4
+ * but may be searched for and used to create envelopes by other users.
5
+ */
6
+ type TTemplatePermissionCreatePublic = "template:creator:create:public";
7
+ /**
8
+ * Create templates shared with other users of the same organization.
9
+ */
10
+ type TTemplatePermissionCreateOrg = "template:creator:create:org";
11
+ /**
12
+ * Create templates private to the creator.
13
+ */
14
+ type TTemplatePermissionCreatePersonal = "template:creator:create:personal";
15
+ /**
16
+ * Create templates private to the creator.
17
+ */
18
+ type TTemplatePermissionDelete = "template:creator:delete";
19
+ /**
20
+ * Alter the visiiblity settings on a template.
21
+ */
22
+ type TTemplatePermissionVisibility = "template:creator:visibility";
23
+ /**
24
+ * View templates shared by other members of the same organization. Those templates must also
25
+ * have `is_personal` set to false to be visible.
26
+ */
27
+ type TTemplateMemberRead = "template:member:read";
28
+ /**
29
+ * Edit templates shared by other members of the same organization. Those templates must also
30
+ * have `is_personal` set to false to be editable.
31
+ */
32
+ type TTemplateMemberWrite = "template:member:write";
33
+ /**
34
+ * Edit templates shared by other members of the same organization. Those templates must also
35
+ * have `is_personal` set to false to be editable.
36
+ */
37
+ type TTemplateMemberDelete = "template:member:delete";
38
+ /**
39
+ * Edit templates shared by other members of the same organization. Those templates must also
40
+ * have `is_personal` set to false to be editable.
41
+ */
42
+ type TTemplateMemberVisibility = "template:member:visibility";
43
+ type TTemplatePermission = TTemplatePermissionCreatePublic | TTemplatePermissionCreateOrg | TTemplatePermissionCreatePersonal | TTemplatePermissionDelete | TTemplatePermissionVisibility | TTemplateMemberRead | TTemplateMemberWrite | TTemplateMemberDelete | TTemplateMemberVisibility;
44
+ /**
45
+ * Grant the "owner" role to other organization members.
46
+ */
47
+ type TAccountPermissionOwnerAdd = "owner:add";
48
+ /**
49
+ * Remove the "owner" role from other organization members.
50
+ */
51
+ type TAccountPermissionOwnerRemove = "owner:remove";
52
+ /**
53
+ * Grant the "admin" role to other organization members.
54
+ */
55
+ type TAccountPermissionAdminAdd = "admin:add";
56
+ /**
57
+ * Remove the "admin" role from other organization members.
58
+ */
59
+ type TAccountPermissionAdminRemove = "admin:remove";
60
+ /**
61
+ * View the members of an organization.
62
+ */
63
+ type TAccountPermissionMemberView = "member:view";
64
+ /**
65
+ * Grant the "member" role to other organization members.
66
+ */
67
+ type TAccountPermissionMemberAdd = "member:add";
68
+ /**
69
+ * Remove the "member" role from other organization members.
70
+ */
71
+ type TAccountPermissionMemberRemove = "member:remove";
72
+ type TAccountPermission = TAccountPermissionOwnerAdd | TAccountPermissionOwnerRemove | TAccountPermissionAdminAdd | TAccountPermissionAdminRemove | TAccountPermissionMemberAdd | TAccountPermissionMemberRemove | TAccountPermissionMemberView;
73
+ /**
74
+ * Create a new organization.
75
+ * @deprecated This is a system-wide setting and organization owners cannot prevent their
76
+ * members from listing other organizations that they may have separate profiles in.
77
+ */
78
+ type TOrgPermissionCreate = "org:create";
79
+ /**
80
+ * View the organization.
81
+ */
82
+ type TOrgPermissionView = "org:view";
83
+ /**
84
+ * Update the organization.
85
+ */
86
+ type TOrgPermissionUpdate = "org:update";
87
+ /**
88
+ * Delete the organization.
89
+ */
90
+ type TOrgPermissionDelete = "org:delete";
91
+ /**
92
+ * Transfer ownership of the organization. This primarily allows the holder to remove his/her own
93
+ * Owner role or add new Owners even if the holder is not one themselves. This is primarily intended
94
+ * to be used for reseller scenarios.
95
+ */
96
+ type TOrgPermissionTransfer = "org:transfer";
97
+ /**
98
+ * List organizations.
99
+ * @deprecated This is a system-wide setting and organization owners cannot prevent their
100
+ * members from listing other organizations that they may have separate profiles in.
101
+ */
102
+ type TOrgPermissionList = "org:list";
103
+ type TOrgPermission = TOrgPermissionCreate | TOrgPermissionView | TOrgPermissionUpdate | TOrgPermissionDelete | TOrgPermissionTransfer | TOrgPermissionList;
104
+ /**
105
+ * Create envelopes.
106
+ */
107
+ type TEnvelopePermissionCreate = "envelope:create";
108
+ /**
109
+ * Cancel envelopes. This is a default permission for most users, but it may be removed for
110
+ * highly regulated environments where envelope activities must be audited, and should not
111
+ * be canceled.
112
+ */
113
+ type TEnvelopePermissionCancel = "envelope:cancel";
114
+ /**
115
+ * View envelopes. This is a default permission for most users, but it may be removed for
116
+ * highly regulated environments where once sent, envelopes may only be viewed by specific
117
+ * users.
118
+ */
119
+ type TEnvelopePermissionView = "envelope:view";
120
+ /**
121
+ * View envelopes created by other members of the same organization. By default, only templates
122
+ * having sharing settings controlled by their creators. Envelopes are usually private to the
123
+ * callers who created them. In some organizations it may be useful to have users who can see
124
+ * "all activity" by all organization members. This is particularly useful when applied to API
125
+ * keys to develop applications that can access all data across the organization.
126
+ */
127
+ type TEnvelopePermissionOrg = "envelope:org:view";
128
+ type TEnvelopePermission = TEnvelopePermissionCreate | TEnvelopePermissionCancel | TEnvelopePermissionView | TEnvelopePermissionOrg;
6
129
  /**
7
130
  * Operation within Verdocs that users may perform.
8
131
  */
@@ -1371,8 +1494,8 @@ interface IListEnvelopesParams {
1371
1494
  status?: string[];
1372
1495
  created_at?: ITimeRange;
1373
1496
  is_owner?: boolean;
1374
- sort_by?: "name" | "created_at" | "updated_at" | "canceled_at" | "status";
1375
1497
  template_id?: string;
1498
+ sort_by?: "name" | "created_at" | "updated_at" | "canceled_at" | "status";
1376
1499
  ascending?: boolean;
1377
1500
  rows?: number;
1378
1501
  page?: number;
@@ -1386,19 +1509,12 @@ interface IListEnvelopesParams {
1386
1509
  * const {totals, envelopes} = await Envelopes.listEnvelopes((VerdocsEndpoint.getDefault(), { q: 'test', sort: 'created_at' });
1387
1510
  * ```
1388
1511
  */
1389
- declare const listEnvelopes: (endpoint: VerdocsEndpoint, params?: IListEnvelopesParams) => Promise<{
1512
+ declare const getEnvelopes: (endpoint: VerdocsEndpoint, params?: IListEnvelopesParams) => Promise<{
1390
1513
  total: number;
1391
1514
  rows: number;
1392
1515
  page: number;
1393
1516
  envelopes: IEnvelope[];
1394
1517
  }>;
1395
- /**
1396
- * Get all of the envelopes that were sent using a given template.
1397
- * NOTE: This endpoint will be retired soon. Its response is not paginated and it is typically used only to retrieve
1398
- * "submitted data" for a template. A new endpoint will be introduced to provide this function more directly.
1399
- * @deprecated
1400
- */
1401
- declare const getEnvelopesByTemplateId: (endpoint: VerdocsEndpoint, templateId: string) => Promise<IEnvelope[]>;
1402
1518
  /**
1403
1519
  * Create an initials block. In a typical signing workflow, the user is asked at the beginning of the process to "adopt"
1404
1520
  * an initials block to be used for all initials fields in the document. Thus, this is typically called one time to
@@ -2798,4 +2914,4 @@ declare const isValidEmail: (email: string | undefined) => boolean;
2798
2914
  declare const isValidPhone: (phone: string | undefined) => boolean;
2799
2915
  declare const isValidRoleName: (value: string, roles: IRole[]) => boolean;
2800
2916
  declare const isValidTag: (value: string, tags: string[]) => boolean;
2801
- export { TRequestStatus, TTemplateSenderType, TTemplateAction, TRecipientAction, TEnvelopeStatus, TRecipientStatus, TRecipientType, TSortTemplateBy, TAccessKeyType, TApiKeyPermission, THistoryEvent, TEventDetail, TEnvelopeUpdateResult, TFieldType, IChannel, IDisabledChannel, INotification, IApiKey, IGroup, IGroupProfile, IOAuth2App, IOrganization, IOrganizationInvitation, IPendingWebhook, IProfile, IWebhookEvents, IWebhook, IInPersonAccessKey, IInAppAccessKey, IEmailAccessKey, ISMSAccessKey, TAccessKey, IEnvelope, IEnvelopeDocument, IEnvelopeField, IEnvelopeFieldOptions, IEnvelopeFieldSettings, IEnvelopeHistory, IInitial, IKbaPINRequired, IRecipient, IReminder, IRole, ISignature, ITemplate, ITemplateDocument, ITemplateField, ITextFieldSetting, ITemplateFieldSetting, IActivityEntry, TEnvironment, TSessionChangedListener, VerdocsEndpointOptions, VerdocsEndpoint, createEnvelope, getEnvelopesSummary, IEnvelopeSearchParams, searchEnvelopes, ISigningSessionResult, getSigningSession, getEnvelopeRecipients, getEnvelope, getEnvelopeDocument, getDocumentDownloadLink, getDocumentPreviewLink, cancelEnvelope, getEnvelopeFile, updateEnvelopeField, updateEnvelopeFieldSignature, updateEnvelopeFieldInitials, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, getFieldAttachment, getEnvelopeDocumentPageDisplayUri, throttledGetEnvelope, ITimeRange, IListEnvelopesParams, listEnvelopes, getEnvelopesByTemplateId, createInitials, IRecipientKbaStatusNotRequired, IRecipientKbaStatusComplete, IRecipientKbaStatusPinRequired, IRecipientKbaStatusIdentityRequired, IRecipientKbaChallengeRequired, IRecipientKbaStatusFailed, TRecipientKbaStatus, getKbaStatus, submitKbaPin, IKbaIdentity, submitKbaIdentity, submitKbaChallengeResponse, updateRecipient, envelopeRecipientSubmit, envelopeRecipientDecline, envelopeRecipientChangeOwner, envelopeRecipientAgree, envelopeRecipientUpdateName, envelopeRecipientPrepare, ISignerTokenResponse, getSignerToken, getInPersonLink, sendDelegate, resendInvitation, createEnvelopeReminder, getEnvelopeReminder, updateEnvelopeReminder, deleteEnvelopeReminder, userIsEnvelopeOwner, userIsEnvelopeRecipient, envelopeIsActive, envelopeIsComplete, userCanCancelEnvelope, userCanFinishEnvelope, recipientHasAction, getRecipientsWithActions, recipientCanAct, userCanAct, userCanSignNow, getNextRecipient, createSignature, getSignatures, getSignature, deleteSignature, IEnvelopesSearchResultEntry, IEnvelopesSearchResult, IEnvelopesSummary, IDocumentSearchOptions, ICreateEnvelopeRole, IEnvelopeSummary, IEnvelopeSummaries, IInPersonLinkResponse, IUpdateRecipientSubmitParams, IUpdateRecipientDeclineParams, IUpdateRecipientClaimEnvelope, IUpdateRecipientStatus, IUpdateRecipientAgreedParams, IUpdateRecipientNameParams, IUpdateRecipientPrepareParams, ICreateEnvelopeReminderRequest, ICreateEnvelopeRequest, getApiKeys, createApiKey, rotateApiKey, updateApiKey, deleteApiKey, getGroups, getGroup, createGroup, addGroupMember, deleteGroupMember, updateGroup, getOrganizationInvitations, createOrganizationInvitation, deleteOrganizationInvitation, updateOrganizationInvitation, resendOrganizationInvitation, getOrganizationInvitation, acceptOrganizationInvitation, declineOrganizationInvitation, getOrganizationMembers, deleteOrganizationMember, updateOrganizationMember, getOrganization, updateOrganization, updateOrganizationLogo, updateOrganizationThumbnail, ICreateApiKeyRequest, IUpdateApiKeyRequest, ICreateInvitationRequest, IAcceptOrganizationInvitationRequest, ISetWebhookRequest, getWebhooks, setWebhooks, TTemplatePermission, TAccountPermission, TOrgPermission, TEnvelopePermission, TPermission, TRole, RolePermissions, userHasPermissions, ISigningSessionRequest, ISigningSession, IUserSession, TSessionType, TSession, TActiveSession, canPerformTemplateAction, hasRequiredPermissions, createField, updateField, deleteField, userIsTemplateCreator, userHasSharedTemplate, userCanCreatePersonalTemplate, userCanCreateOrgTemplate, userCanCreatePublicTemplate, userCanReadTemplate, userCanUpdateTemplate, userCanMakeTemplatePrivate, userCanMakeTemplateShared, userCanMakeTemplatePublic, userCanChangeOrgVisibility, userCanDeleteTemplate, userCanSendTemplate, userCanCreateTemplate, userCanBuildTemplate, getFieldsForRole, userCanPreviewTemplate, ICreateTemplateReminderRequest, createTemplateReminder, getTemplateReminder, updateTemplateReminder, deleteTemplateReminder, createTemplateRole, getTemplateRoles, getTemplateRole, updateTemplateRole, deleteTemplateRole, getTemplateRoleFields, getStars, toggleStar, addTemplateTag, getTemplateTags, deleteTemplateTag, createTag, getTag, getAllTags, IGetTemplatesParams, getTemplates, getTemplate, getTemplateOwnerInfo, IDocumentFromUri, IDocumentFromData, ITemplateCreateParams, createTemplate, createTemplatev2, ITemplateCreateFromSharepointParams, createTemplateFromSharepoint, updateTemplate, deleteTemplate, searchTemplates, ISearchTimeRange, IGetTemplateSummarySortBy, IGetTemplateSummaryParams, getTemplatesSummary, throttledGetTemplate, ITemplateListParams, listTemplates, getTemplateDocuments, getTemplateDocument, createTemplateDocument, deleteTemplateDocument, getTemplateDocumentFile, getTemplateDocumentThumbnail, getTemplateDocumentPageDisplayUri, ITemplateSummary, ITemplateSearchParams, ITemplateSummaries, ITemplateTag, ITag, IStar, ITemplateOwnerInfo, ITemplateSearchResult, IValidator, getValidators, getValidator, isValidEmail, isValidPhone, isValidRoleName, isValidTag, IROPCRequest, IClientCredentialsRequest, IRefreshTokenRequest, TAuthenticationRequest, authenticate, refreshToken, changePassword, resetPassword, verifyEmail, resendVerification, getNotifications, getProfiles, getCurrentProfile, getProfile, switchProfile, updateProfile, deleteProfile, createProfile, updateProfilePhoto, IUpdateProfileRequest, IAuthenticateResponse, IUpdatePasswordRequest, IUpdatePasswordResponse, ICreateAccountRequest, getRGB, getRGBA, nameToRGBA, getRoleColor, formatShortTimeAgo, timePeriod, getRTop, getRLeft, getRValue, blobToBase64, rescale, fileToDataUrl, downloadBlob, Countries, getCountryByCode, isFrenchGuiana, isGuadeloupe, isMartinique, isMayotte, getPlusOneCountry, isCanada, isAmericanSamoa, isDominicanRepublic, isPuertoRico, getMatchingCountry, integerSequence, formatFullName, formatInitials, fullNameToInitials, capitalize, convertToE164, AtoB, decodeJWTBody, decodeAccessTokenBody, IFileWithData, ICountry, ITimePeriod };
2917
+ export { TRequestStatus, TTemplateSenderType, TTemplateAction, TRecipientAction, TEnvelopeStatus, TRecipientStatus, TRecipientType, TSortTemplateBy, TAccessKeyType, TApiKeyPermission, THistoryEvent, TEventDetail, TEnvelopeUpdateResult, TFieldType, IChannel, IDisabledChannel, INotification, IApiKey, IGroup, IGroupProfile, IOAuth2App, IOrganization, IOrganizationInvitation, IPendingWebhook, IProfile, IWebhookEvents, IWebhook, IInPersonAccessKey, IInAppAccessKey, IEmailAccessKey, ISMSAccessKey, TAccessKey, IEnvelope, IEnvelopeDocument, IEnvelopeField, IEnvelopeFieldOptions, IEnvelopeFieldSettings, IEnvelopeHistory, IInitial, IKbaPINRequired, IRecipient, IReminder, IRole, ISignature, ITemplate, ITemplateDocument, ITemplateField, ITextFieldSetting, ITemplateFieldSetting, IActivityEntry, TEnvironment, TSessionChangedListener, VerdocsEndpointOptions, VerdocsEndpoint, createEnvelope, getEnvelopesSummary, IEnvelopeSearchParams, searchEnvelopes, ISigningSessionResult, getSigningSession, getEnvelopeRecipients, getEnvelope, getEnvelopeDocument, getDocumentDownloadLink, getDocumentPreviewLink, cancelEnvelope, getEnvelopeFile, updateEnvelopeField, updateEnvelopeFieldSignature, updateEnvelopeFieldInitials, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, getFieldAttachment, getEnvelopeDocumentPageDisplayUri, throttledGetEnvelope, ITimeRange, IListEnvelopesParams, getEnvelopes, createInitials, IRecipientKbaStatusNotRequired, IRecipientKbaStatusComplete, IRecipientKbaStatusPinRequired, IRecipientKbaStatusIdentityRequired, IRecipientKbaChallengeRequired, IRecipientKbaStatusFailed, TRecipientKbaStatus, getKbaStatus, submitKbaPin, IKbaIdentity, submitKbaIdentity, submitKbaChallengeResponse, updateRecipient, envelopeRecipientSubmit, envelopeRecipientDecline, envelopeRecipientChangeOwner, envelopeRecipientAgree, envelopeRecipientUpdateName, envelopeRecipientPrepare, ISignerTokenResponse, getSignerToken, getInPersonLink, sendDelegate, resendInvitation, createEnvelopeReminder, getEnvelopeReminder, updateEnvelopeReminder, deleteEnvelopeReminder, userIsEnvelopeOwner, userIsEnvelopeRecipient, envelopeIsActive, envelopeIsComplete, userCanCancelEnvelope, userCanFinishEnvelope, recipientHasAction, getRecipientsWithActions, recipientCanAct, userCanAct, userCanSignNow, getNextRecipient, createSignature, getSignatures, getSignature, deleteSignature, IEnvelopesSearchResultEntry, IEnvelopesSearchResult, IEnvelopesSummary, IDocumentSearchOptions, ICreateEnvelopeRole, IEnvelopeSummary, IEnvelopeSummaries, IInPersonLinkResponse, IUpdateRecipientSubmitParams, IUpdateRecipientDeclineParams, IUpdateRecipientClaimEnvelope, IUpdateRecipientStatus, IUpdateRecipientAgreedParams, IUpdateRecipientNameParams, IUpdateRecipientPrepareParams, ICreateEnvelopeReminderRequest, ICreateEnvelopeRequest, getApiKeys, createApiKey, rotateApiKey, updateApiKey, deleteApiKey, getGroups, getGroup, createGroup, addGroupMember, deleteGroupMember, updateGroup, getOrganizationInvitations, createOrganizationInvitation, deleteOrganizationInvitation, updateOrganizationInvitation, resendOrganizationInvitation, getOrganizationInvitation, acceptOrganizationInvitation, declineOrganizationInvitation, getOrganizationMembers, deleteOrganizationMember, updateOrganizationMember, getOrganization, updateOrganization, updateOrganizationLogo, updateOrganizationThumbnail, ICreateApiKeyRequest, IUpdateApiKeyRequest, ICreateInvitationRequest, IAcceptOrganizationInvitationRequest, ISetWebhookRequest, getWebhooks, setWebhooks, TTemplatePermissionCreatePublic, TTemplatePermissionCreateOrg, TTemplatePermissionCreatePersonal, TTemplatePermissionDelete, TTemplatePermissionVisibility, TTemplateMemberRead, TTemplateMemberWrite, TTemplateMemberDelete, TTemplateMemberVisibility, TTemplatePermission, TAccountPermissionOwnerAdd, TAccountPermissionOwnerRemove, TAccountPermissionAdminAdd, TAccountPermissionAdminRemove, TAccountPermissionMemberView, TAccountPermissionMemberAdd, TAccountPermissionMemberRemove, TAccountPermission, TOrgPermissionCreate, TOrgPermissionView, TOrgPermissionUpdate, TOrgPermissionDelete, TOrgPermissionTransfer, TOrgPermissionList, TOrgPermission, TEnvelopePermissionCreate, TEnvelopePermissionCancel, TEnvelopePermissionView, TEnvelopePermissionOrg, TEnvelopePermission, TPermission, TRole, RolePermissions, userHasPermissions, ISigningSessionRequest, ISigningSession, IUserSession, TSessionType, TSession, TActiveSession, canPerformTemplateAction, hasRequiredPermissions, createField, updateField, deleteField, userIsTemplateCreator, userHasSharedTemplate, userCanCreatePersonalTemplate, userCanCreateOrgTemplate, userCanCreatePublicTemplate, userCanReadTemplate, userCanUpdateTemplate, userCanMakeTemplatePrivate, userCanMakeTemplateShared, userCanMakeTemplatePublic, userCanChangeOrgVisibility, userCanDeleteTemplate, userCanSendTemplate, userCanCreateTemplate, userCanBuildTemplate, getFieldsForRole, userCanPreviewTemplate, ICreateTemplateReminderRequest, createTemplateReminder, getTemplateReminder, updateTemplateReminder, deleteTemplateReminder, createTemplateRole, getTemplateRoles, getTemplateRole, updateTemplateRole, deleteTemplateRole, getTemplateRoleFields, getStars, toggleStar, addTemplateTag, getTemplateTags, deleteTemplateTag, createTag, getTag, getAllTags, IGetTemplatesParams, getTemplates, getTemplate, getTemplateOwnerInfo, IDocumentFromUri, IDocumentFromData, ITemplateCreateParams, createTemplate, createTemplatev2, ITemplateCreateFromSharepointParams, createTemplateFromSharepoint, updateTemplate, deleteTemplate, searchTemplates, ISearchTimeRange, IGetTemplateSummarySortBy, IGetTemplateSummaryParams, getTemplatesSummary, throttledGetTemplate, ITemplateListParams, listTemplates, getTemplateDocuments, getTemplateDocument, createTemplateDocument, deleteTemplateDocument, getTemplateDocumentFile, getTemplateDocumentThumbnail, getTemplateDocumentPageDisplayUri, ITemplateSummary, ITemplateSearchParams, ITemplateSummaries, ITemplateTag, ITag, IStar, ITemplateOwnerInfo, ITemplateSearchResult, IValidator, getValidators, getValidator, isValidEmail, isValidPhone, isValidRoleName, isValidTag, IROPCRequest, IClientCredentialsRequest, IRefreshTokenRequest, TAuthenticationRequest, authenticate, refreshToken, changePassword, resetPassword, verifyEmail, resendVerification, getNotifications, getProfiles, getCurrentProfile, getProfile, switchProfile, updateProfile, deleteProfile, createProfile, updateProfilePhoto, IUpdateProfileRequest, IAuthenticateResponse, IUpdatePasswordRequest, IUpdatePasswordResponse, ICreateAccountRequest, getRGB, getRGBA, nameToRGBA, getRoleColor, formatShortTimeAgo, timePeriod, getRTop, getRLeft, getRValue, blobToBase64, rescale, fileToDataUrl, downloadBlob, Countries, getCountryByCode, isFrenchGuiana, isGuadeloupe, isMartinique, isMayotte, getPlusOneCountry, isCanada, isAmericanSamoa, isDominicanRepublic, isPuertoRico, getMatchingCountry, integerSequence, formatFullName, formatInitials, fullNameToInitials, capitalize, convertToE164, AtoB, decodeJWTBody, decodeAccessTokenBody, IFileWithData, ICountry, ITimePeriod };
package/dist/index.d.ts CHANGED
@@ -1,8 +1,131 @@
1
1
  import { AxiosInstance } from "axios";
2
- type TTemplatePermission = "template:creator:create:public" | "template:creator:create:org" | "template:creator:create:personal" | "template:creator:delete" | "template:creator:visibility" | "template:member:read" | "template:member:write" | "template:member:delete" | "template:member:visibility";
3
- type TAccountPermission = "owner:add" | "owner:remove" | "admin:add" | "admin:remove" | "member:view" | "member:add" | "member:remove";
4
- type TOrgPermission = "org:create" | "org:view" | "org:update" | "org:delete" | "org:transfer" | "org:list";
5
- type TEnvelopePermission = "envelope:create" | "envelope:cancel" | "envelope:view";
2
+ /**
3
+ * Create public templates. Public templates are still owned and managed by the creator,
4
+ * but may be searched for and used to create envelopes by other users.
5
+ */
6
+ type TTemplatePermissionCreatePublic = "template:creator:create:public";
7
+ /**
8
+ * Create templates shared with other users of the same organization.
9
+ */
10
+ type TTemplatePermissionCreateOrg = "template:creator:create:org";
11
+ /**
12
+ * Create templates private to the creator.
13
+ */
14
+ type TTemplatePermissionCreatePersonal = "template:creator:create:personal";
15
+ /**
16
+ * Create templates private to the creator.
17
+ */
18
+ type TTemplatePermissionDelete = "template:creator:delete";
19
+ /**
20
+ * Alter the visiiblity settings on a template.
21
+ */
22
+ type TTemplatePermissionVisibility = "template:creator:visibility";
23
+ /**
24
+ * View templates shared by other members of the same organization. Those templates must also
25
+ * have `is_personal` set to false to be visible.
26
+ */
27
+ type TTemplateMemberRead = "template:member:read";
28
+ /**
29
+ * Edit templates shared by other members of the same organization. Those templates must also
30
+ * have `is_personal` set to false to be editable.
31
+ */
32
+ type TTemplateMemberWrite = "template:member:write";
33
+ /**
34
+ * Edit templates shared by other members of the same organization. Those templates must also
35
+ * have `is_personal` set to false to be editable.
36
+ */
37
+ type TTemplateMemberDelete = "template:member:delete";
38
+ /**
39
+ * Edit templates shared by other members of the same organization. Those templates must also
40
+ * have `is_personal` set to false to be editable.
41
+ */
42
+ type TTemplateMemberVisibility = "template:member:visibility";
43
+ type TTemplatePermission = TTemplatePermissionCreatePublic | TTemplatePermissionCreateOrg | TTemplatePermissionCreatePersonal | TTemplatePermissionDelete | TTemplatePermissionVisibility | TTemplateMemberRead | TTemplateMemberWrite | TTemplateMemberDelete | TTemplateMemberVisibility;
44
+ /**
45
+ * Grant the "owner" role to other organization members.
46
+ */
47
+ type TAccountPermissionOwnerAdd = "owner:add";
48
+ /**
49
+ * Remove the "owner" role from other organization members.
50
+ */
51
+ type TAccountPermissionOwnerRemove = "owner:remove";
52
+ /**
53
+ * Grant the "admin" role to other organization members.
54
+ */
55
+ type TAccountPermissionAdminAdd = "admin:add";
56
+ /**
57
+ * Remove the "admin" role from other organization members.
58
+ */
59
+ type TAccountPermissionAdminRemove = "admin:remove";
60
+ /**
61
+ * View the members of an organization.
62
+ */
63
+ type TAccountPermissionMemberView = "member:view";
64
+ /**
65
+ * Grant the "member" role to other organization members.
66
+ */
67
+ type TAccountPermissionMemberAdd = "member:add";
68
+ /**
69
+ * Remove the "member" role from other organization members.
70
+ */
71
+ type TAccountPermissionMemberRemove = "member:remove";
72
+ type TAccountPermission = TAccountPermissionOwnerAdd | TAccountPermissionOwnerRemove | TAccountPermissionAdminAdd | TAccountPermissionAdminRemove | TAccountPermissionMemberAdd | TAccountPermissionMemberRemove | TAccountPermissionMemberView;
73
+ /**
74
+ * Create a new organization.
75
+ * @deprecated This is a system-wide setting and organization owners cannot prevent their
76
+ * members from listing other organizations that they may have separate profiles in.
77
+ */
78
+ type TOrgPermissionCreate = "org:create";
79
+ /**
80
+ * View the organization.
81
+ */
82
+ type TOrgPermissionView = "org:view";
83
+ /**
84
+ * Update the organization.
85
+ */
86
+ type TOrgPermissionUpdate = "org:update";
87
+ /**
88
+ * Delete the organization.
89
+ */
90
+ type TOrgPermissionDelete = "org:delete";
91
+ /**
92
+ * Transfer ownership of the organization. This primarily allows the holder to remove his/her own
93
+ * Owner role or add new Owners even if the holder is not one themselves. This is primarily intended
94
+ * to be used for reseller scenarios.
95
+ */
96
+ type TOrgPermissionTransfer = "org:transfer";
97
+ /**
98
+ * List organizations.
99
+ * @deprecated This is a system-wide setting and organization owners cannot prevent their
100
+ * members from listing other organizations that they may have separate profiles in.
101
+ */
102
+ type TOrgPermissionList = "org:list";
103
+ type TOrgPermission = TOrgPermissionCreate | TOrgPermissionView | TOrgPermissionUpdate | TOrgPermissionDelete | TOrgPermissionTransfer | TOrgPermissionList;
104
+ /**
105
+ * Create envelopes.
106
+ */
107
+ type TEnvelopePermissionCreate = "envelope:create";
108
+ /**
109
+ * Cancel envelopes. This is a default permission for most users, but it may be removed for
110
+ * highly regulated environments where envelope activities must be audited, and should not
111
+ * be canceled.
112
+ */
113
+ type TEnvelopePermissionCancel = "envelope:cancel";
114
+ /**
115
+ * View envelopes. This is a default permission for most users, but it may be removed for
116
+ * highly regulated environments where once sent, envelopes may only be viewed by specific
117
+ * users.
118
+ */
119
+ type TEnvelopePermissionView = "envelope:view";
120
+ /**
121
+ * View envelopes created by other members of the same organization. By default, only templates
122
+ * having sharing settings controlled by their creators. Envelopes are usually private to the
123
+ * callers who created them. In some organizations it may be useful to have users who can see
124
+ * "all activity" by all organization members. This is particularly useful when applied to API
125
+ * keys to develop applications that can access all data across the organization.
126
+ */
127
+ type TEnvelopePermissionOrg = "envelope:org:view";
128
+ type TEnvelopePermission = TEnvelopePermissionCreate | TEnvelopePermissionCancel | TEnvelopePermissionView | TEnvelopePermissionOrg;
6
129
  /**
7
130
  * Operation within Verdocs that users may perform.
8
131
  */
@@ -1371,8 +1494,8 @@ interface IListEnvelopesParams {
1371
1494
  status?: string[];
1372
1495
  created_at?: ITimeRange;
1373
1496
  is_owner?: boolean;
1374
- sort_by?: "name" | "created_at" | "updated_at" | "canceled_at" | "status";
1375
1497
  template_id?: string;
1498
+ sort_by?: "name" | "created_at" | "updated_at" | "canceled_at" | "status";
1376
1499
  ascending?: boolean;
1377
1500
  rows?: number;
1378
1501
  page?: number;
@@ -1386,19 +1509,12 @@ interface IListEnvelopesParams {
1386
1509
  * const {totals, envelopes} = await Envelopes.listEnvelopes((VerdocsEndpoint.getDefault(), { q: 'test', sort: 'created_at' });
1387
1510
  * ```
1388
1511
  */
1389
- declare const listEnvelopes: (endpoint: VerdocsEndpoint, params?: IListEnvelopesParams) => Promise<{
1512
+ declare const getEnvelopes: (endpoint: VerdocsEndpoint, params?: IListEnvelopesParams) => Promise<{
1390
1513
  total: number;
1391
1514
  rows: number;
1392
1515
  page: number;
1393
1516
  envelopes: IEnvelope[];
1394
1517
  }>;
1395
- /**
1396
- * Get all of the envelopes that were sent using a given template.
1397
- * NOTE: This endpoint will be retired soon. Its response is not paginated and it is typically used only to retrieve
1398
- * "submitted data" for a template. A new endpoint will be introduced to provide this function more directly.
1399
- * @deprecated
1400
- */
1401
- declare const getEnvelopesByTemplateId: (endpoint: VerdocsEndpoint, templateId: string) => Promise<IEnvelope[]>;
1402
1518
  /**
1403
1519
  * Create an initials block. In a typical signing workflow, the user is asked at the beginning of the process to "adopt"
1404
1520
  * an initials block to be used for all initials fields in the document. Thus, this is typically called one time to
@@ -2798,4 +2914,4 @@ declare const isValidEmail: (email: string | undefined) => boolean;
2798
2914
  declare const isValidPhone: (phone: string | undefined) => boolean;
2799
2915
  declare const isValidRoleName: (value: string, roles: IRole[]) => boolean;
2800
2916
  declare const isValidTag: (value: string, tags: string[]) => boolean;
2801
- export { TRequestStatus, TTemplateSenderType, TTemplateAction, TRecipientAction, TEnvelopeStatus, TRecipientStatus, TRecipientType, TSortTemplateBy, TAccessKeyType, TApiKeyPermission, THistoryEvent, TEventDetail, TEnvelopeUpdateResult, TFieldType, IChannel, IDisabledChannel, INotification, IApiKey, IGroup, IGroupProfile, IOAuth2App, IOrganization, IOrganizationInvitation, IPendingWebhook, IProfile, IWebhookEvents, IWebhook, IInPersonAccessKey, IInAppAccessKey, IEmailAccessKey, ISMSAccessKey, TAccessKey, IEnvelope, IEnvelopeDocument, IEnvelopeField, IEnvelopeFieldOptions, IEnvelopeFieldSettings, IEnvelopeHistory, IInitial, IKbaPINRequired, IRecipient, IReminder, IRole, ISignature, ITemplate, ITemplateDocument, ITemplateField, ITextFieldSetting, ITemplateFieldSetting, IActivityEntry, TEnvironment, TSessionChangedListener, VerdocsEndpointOptions, VerdocsEndpoint, createEnvelope, getEnvelopesSummary, IEnvelopeSearchParams, searchEnvelopes, ISigningSessionResult, getSigningSession, getEnvelopeRecipients, getEnvelope, getEnvelopeDocument, getDocumentDownloadLink, getDocumentPreviewLink, cancelEnvelope, getEnvelopeFile, updateEnvelopeField, updateEnvelopeFieldSignature, updateEnvelopeFieldInitials, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, getFieldAttachment, getEnvelopeDocumentPageDisplayUri, throttledGetEnvelope, ITimeRange, IListEnvelopesParams, listEnvelopes, getEnvelopesByTemplateId, createInitials, IRecipientKbaStatusNotRequired, IRecipientKbaStatusComplete, IRecipientKbaStatusPinRequired, IRecipientKbaStatusIdentityRequired, IRecipientKbaChallengeRequired, IRecipientKbaStatusFailed, TRecipientKbaStatus, getKbaStatus, submitKbaPin, IKbaIdentity, submitKbaIdentity, submitKbaChallengeResponse, updateRecipient, envelopeRecipientSubmit, envelopeRecipientDecline, envelopeRecipientChangeOwner, envelopeRecipientAgree, envelopeRecipientUpdateName, envelopeRecipientPrepare, ISignerTokenResponse, getSignerToken, getInPersonLink, sendDelegate, resendInvitation, createEnvelopeReminder, getEnvelopeReminder, updateEnvelopeReminder, deleteEnvelopeReminder, userIsEnvelopeOwner, userIsEnvelopeRecipient, envelopeIsActive, envelopeIsComplete, userCanCancelEnvelope, userCanFinishEnvelope, recipientHasAction, getRecipientsWithActions, recipientCanAct, userCanAct, userCanSignNow, getNextRecipient, createSignature, getSignatures, getSignature, deleteSignature, IEnvelopesSearchResultEntry, IEnvelopesSearchResult, IEnvelopesSummary, IDocumentSearchOptions, ICreateEnvelopeRole, IEnvelopeSummary, IEnvelopeSummaries, IInPersonLinkResponse, IUpdateRecipientSubmitParams, IUpdateRecipientDeclineParams, IUpdateRecipientClaimEnvelope, IUpdateRecipientStatus, IUpdateRecipientAgreedParams, IUpdateRecipientNameParams, IUpdateRecipientPrepareParams, ICreateEnvelopeReminderRequest, ICreateEnvelopeRequest, getApiKeys, createApiKey, rotateApiKey, updateApiKey, deleteApiKey, getGroups, getGroup, createGroup, addGroupMember, deleteGroupMember, updateGroup, getOrganizationInvitations, createOrganizationInvitation, deleteOrganizationInvitation, updateOrganizationInvitation, resendOrganizationInvitation, getOrganizationInvitation, acceptOrganizationInvitation, declineOrganizationInvitation, getOrganizationMembers, deleteOrganizationMember, updateOrganizationMember, getOrganization, updateOrganization, updateOrganizationLogo, updateOrganizationThumbnail, ICreateApiKeyRequest, IUpdateApiKeyRequest, ICreateInvitationRequest, IAcceptOrganizationInvitationRequest, ISetWebhookRequest, getWebhooks, setWebhooks, TTemplatePermission, TAccountPermission, TOrgPermission, TEnvelopePermission, TPermission, TRole, RolePermissions, userHasPermissions, ISigningSessionRequest, ISigningSession, IUserSession, TSessionType, TSession, TActiveSession, canPerformTemplateAction, hasRequiredPermissions, createField, updateField, deleteField, userIsTemplateCreator, userHasSharedTemplate, userCanCreatePersonalTemplate, userCanCreateOrgTemplate, userCanCreatePublicTemplate, userCanReadTemplate, userCanUpdateTemplate, userCanMakeTemplatePrivate, userCanMakeTemplateShared, userCanMakeTemplatePublic, userCanChangeOrgVisibility, userCanDeleteTemplate, userCanSendTemplate, userCanCreateTemplate, userCanBuildTemplate, getFieldsForRole, userCanPreviewTemplate, ICreateTemplateReminderRequest, createTemplateReminder, getTemplateReminder, updateTemplateReminder, deleteTemplateReminder, createTemplateRole, getTemplateRoles, getTemplateRole, updateTemplateRole, deleteTemplateRole, getTemplateRoleFields, getStars, toggleStar, addTemplateTag, getTemplateTags, deleteTemplateTag, createTag, getTag, getAllTags, IGetTemplatesParams, getTemplates, getTemplate, getTemplateOwnerInfo, IDocumentFromUri, IDocumentFromData, ITemplateCreateParams, createTemplate, createTemplatev2, ITemplateCreateFromSharepointParams, createTemplateFromSharepoint, updateTemplate, deleteTemplate, searchTemplates, ISearchTimeRange, IGetTemplateSummarySortBy, IGetTemplateSummaryParams, getTemplatesSummary, throttledGetTemplate, ITemplateListParams, listTemplates, getTemplateDocuments, getTemplateDocument, createTemplateDocument, deleteTemplateDocument, getTemplateDocumentFile, getTemplateDocumentThumbnail, getTemplateDocumentPageDisplayUri, ITemplateSummary, ITemplateSearchParams, ITemplateSummaries, ITemplateTag, ITag, IStar, ITemplateOwnerInfo, ITemplateSearchResult, IValidator, getValidators, getValidator, isValidEmail, isValidPhone, isValidRoleName, isValidTag, IROPCRequest, IClientCredentialsRequest, IRefreshTokenRequest, TAuthenticationRequest, authenticate, refreshToken, changePassword, resetPassword, verifyEmail, resendVerification, getNotifications, getProfiles, getCurrentProfile, getProfile, switchProfile, updateProfile, deleteProfile, createProfile, updateProfilePhoto, IUpdateProfileRequest, IAuthenticateResponse, IUpdatePasswordRequest, IUpdatePasswordResponse, ICreateAccountRequest, getRGB, getRGBA, nameToRGBA, getRoleColor, formatShortTimeAgo, timePeriod, getRTop, getRLeft, getRValue, blobToBase64, rescale, fileToDataUrl, downloadBlob, Countries, getCountryByCode, isFrenchGuiana, isGuadeloupe, isMartinique, isMayotte, getPlusOneCountry, isCanada, isAmericanSamoa, isDominicanRepublic, isPuertoRico, getMatchingCountry, integerSequence, formatFullName, formatInitials, fullNameToInitials, capitalize, convertToE164, AtoB, decodeJWTBody, decodeAccessTokenBody, IFileWithData, ICountry, ITimePeriod };
2917
+ export { TRequestStatus, TTemplateSenderType, TTemplateAction, TRecipientAction, TEnvelopeStatus, TRecipientStatus, TRecipientType, TSortTemplateBy, TAccessKeyType, TApiKeyPermission, THistoryEvent, TEventDetail, TEnvelopeUpdateResult, TFieldType, IChannel, IDisabledChannel, INotification, IApiKey, IGroup, IGroupProfile, IOAuth2App, IOrganization, IOrganizationInvitation, IPendingWebhook, IProfile, IWebhookEvents, IWebhook, IInPersonAccessKey, IInAppAccessKey, IEmailAccessKey, ISMSAccessKey, TAccessKey, IEnvelope, IEnvelopeDocument, IEnvelopeField, IEnvelopeFieldOptions, IEnvelopeFieldSettings, IEnvelopeHistory, IInitial, IKbaPINRequired, IRecipient, IReminder, IRole, ISignature, ITemplate, ITemplateDocument, ITemplateField, ITextFieldSetting, ITemplateFieldSetting, IActivityEntry, TEnvironment, TSessionChangedListener, VerdocsEndpointOptions, VerdocsEndpoint, createEnvelope, getEnvelopesSummary, IEnvelopeSearchParams, searchEnvelopes, ISigningSessionResult, getSigningSession, getEnvelopeRecipients, getEnvelope, getEnvelopeDocument, getDocumentDownloadLink, getDocumentPreviewLink, cancelEnvelope, getEnvelopeFile, updateEnvelopeField, updateEnvelopeFieldSignature, updateEnvelopeFieldInitials, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, getFieldAttachment, getEnvelopeDocumentPageDisplayUri, throttledGetEnvelope, ITimeRange, IListEnvelopesParams, getEnvelopes, createInitials, IRecipientKbaStatusNotRequired, IRecipientKbaStatusComplete, IRecipientKbaStatusPinRequired, IRecipientKbaStatusIdentityRequired, IRecipientKbaChallengeRequired, IRecipientKbaStatusFailed, TRecipientKbaStatus, getKbaStatus, submitKbaPin, IKbaIdentity, submitKbaIdentity, submitKbaChallengeResponse, updateRecipient, envelopeRecipientSubmit, envelopeRecipientDecline, envelopeRecipientChangeOwner, envelopeRecipientAgree, envelopeRecipientUpdateName, envelopeRecipientPrepare, ISignerTokenResponse, getSignerToken, getInPersonLink, sendDelegate, resendInvitation, createEnvelopeReminder, getEnvelopeReminder, updateEnvelopeReminder, deleteEnvelopeReminder, userIsEnvelopeOwner, userIsEnvelopeRecipient, envelopeIsActive, envelopeIsComplete, userCanCancelEnvelope, userCanFinishEnvelope, recipientHasAction, getRecipientsWithActions, recipientCanAct, userCanAct, userCanSignNow, getNextRecipient, createSignature, getSignatures, getSignature, deleteSignature, IEnvelopesSearchResultEntry, IEnvelopesSearchResult, IEnvelopesSummary, IDocumentSearchOptions, ICreateEnvelopeRole, IEnvelopeSummary, IEnvelopeSummaries, IInPersonLinkResponse, IUpdateRecipientSubmitParams, IUpdateRecipientDeclineParams, IUpdateRecipientClaimEnvelope, IUpdateRecipientStatus, IUpdateRecipientAgreedParams, IUpdateRecipientNameParams, IUpdateRecipientPrepareParams, ICreateEnvelopeReminderRequest, ICreateEnvelopeRequest, getApiKeys, createApiKey, rotateApiKey, updateApiKey, deleteApiKey, getGroups, getGroup, createGroup, addGroupMember, deleteGroupMember, updateGroup, getOrganizationInvitations, createOrganizationInvitation, deleteOrganizationInvitation, updateOrganizationInvitation, resendOrganizationInvitation, getOrganizationInvitation, acceptOrganizationInvitation, declineOrganizationInvitation, getOrganizationMembers, deleteOrganizationMember, updateOrganizationMember, getOrganization, updateOrganization, updateOrganizationLogo, updateOrganizationThumbnail, ICreateApiKeyRequest, IUpdateApiKeyRequest, ICreateInvitationRequest, IAcceptOrganizationInvitationRequest, ISetWebhookRequest, getWebhooks, setWebhooks, TTemplatePermissionCreatePublic, TTemplatePermissionCreateOrg, TTemplatePermissionCreatePersonal, TTemplatePermissionDelete, TTemplatePermissionVisibility, TTemplateMemberRead, TTemplateMemberWrite, TTemplateMemberDelete, TTemplateMemberVisibility, TTemplatePermission, TAccountPermissionOwnerAdd, TAccountPermissionOwnerRemove, TAccountPermissionAdminAdd, TAccountPermissionAdminRemove, TAccountPermissionMemberView, TAccountPermissionMemberAdd, TAccountPermissionMemberRemove, TAccountPermission, TOrgPermissionCreate, TOrgPermissionView, TOrgPermissionUpdate, TOrgPermissionDelete, TOrgPermissionTransfer, TOrgPermissionList, TOrgPermission, TEnvelopePermissionCreate, TEnvelopePermissionCancel, TEnvelopePermissionView, TEnvelopePermissionOrg, TEnvelopePermission, TPermission, TRole, RolePermissions, userHasPermissions, ISigningSessionRequest, ISigningSession, IUserSession, TSessionType, TSession, TActiveSession, canPerformTemplateAction, hasRequiredPermissions, createField, updateField, deleteField, userIsTemplateCreator, userHasSharedTemplate, userCanCreatePersonalTemplate, userCanCreateOrgTemplate, userCanCreatePublicTemplate, userCanReadTemplate, userCanUpdateTemplate, userCanMakeTemplatePrivate, userCanMakeTemplateShared, userCanMakeTemplatePublic, userCanChangeOrgVisibility, userCanDeleteTemplate, userCanSendTemplate, userCanCreateTemplate, userCanBuildTemplate, getFieldsForRole, userCanPreviewTemplate, ICreateTemplateReminderRequest, createTemplateReminder, getTemplateReminder, updateTemplateReminder, deleteTemplateReminder, createTemplateRole, getTemplateRoles, getTemplateRole, updateTemplateRole, deleteTemplateRole, getTemplateRoleFields, getStars, toggleStar, addTemplateTag, getTemplateTags, deleteTemplateTag, createTag, getTag, getAllTags, IGetTemplatesParams, getTemplates, getTemplate, getTemplateOwnerInfo, IDocumentFromUri, IDocumentFromData, ITemplateCreateParams, createTemplate, createTemplatev2, ITemplateCreateFromSharepointParams, createTemplateFromSharepoint, updateTemplate, deleteTemplate, searchTemplates, ISearchTimeRange, IGetTemplateSummarySortBy, IGetTemplateSummaryParams, getTemplatesSummary, throttledGetTemplate, ITemplateListParams, listTemplates, getTemplateDocuments, getTemplateDocument, createTemplateDocument, deleteTemplateDocument, getTemplateDocumentFile, getTemplateDocumentThumbnail, getTemplateDocumentPageDisplayUri, ITemplateSummary, ITemplateSearchParams, ITemplateSummaries, ITemplateTag, ITag, IStar, ITemplateOwnerInfo, ITemplateSearchResult, IValidator, getValidators, getValidator, isValidEmail, isValidPhone, isValidRoleName, isValidTag, IROPCRequest, IClientCredentialsRequest, IRefreshTokenRequest, TAuthenticationRequest, authenticate, refreshToken, changePassword, resetPassword, verifyEmail, resendVerification, getNotifications, getProfiles, getCurrentProfile, getProfile, switchProfile, updateProfile, deleteProfile, createProfile, updateProfilePhoto, IUpdateProfileRequest, IAuthenticateResponse, IUpdatePasswordRequest, IUpdatePasswordResponse, ICreateAccountRequest, getRGB, getRGBA, nameToRGBA, getRoleColor, formatShortTimeAgo, timePeriod, getRTop, getRLeft, getRValue, blobToBase64, rescale, fileToDataUrl, downloadBlob, Countries, getCountryByCode, isFrenchGuiana, isGuadeloupe, isMartinique, isMayotte, getPlusOneCountry, isCanada, isAmericanSamoa, isDominicanRepublic, isPuertoRico, getMatchingCountry, integerSequence, formatFullName, formatInitials, fullNameToInitials, capitalize, convertToE164, AtoB, decodeJWTBody, decodeAccessTokenBody, IFileWithData, ICountry, ITimePeriod };
package/dist/index.js CHANGED
@@ -1599,18 +1599,9 @@ const throttledGetEnvelope = (endpoint, envelopeId) => {
1599
1599
  * const {totals, envelopes} = await Envelopes.listEnvelopes((VerdocsEndpoint.getDefault(), { q: 'test', sort: 'created_at' });
1600
1600
  * ```
1601
1601
  */
1602
- const listEnvelopes = (endpoint, params) => endpoint.api //
1602
+ const getEnvelopes = (endpoint, params) => endpoint.api //
1603
1603
  .post('/envelopes/list', params)
1604
1604
  .then((r) => r.data);
1605
- /**
1606
- * Get all of the envelopes that were sent using a given template.
1607
- * NOTE: This endpoint will be retired soon. Its response is not paginated and it is typically used only to retrieve
1608
- * "submitted data" for a template. A new endpoint will be introduced to provide this function more directly.
1609
- * @deprecated
1610
- */
1611
- const getEnvelopesByTemplateId = async (endpoint, templateId) => endpoint.api //
1612
- .get(`/envelopes?template_id=${templateId}`)
1613
- .then((r) => r.data);
1614
1605
 
1615
1606
  /**
1616
1607
  * Create an initials block. In a typical signing workflow, the user is asked at the beginning of the process to "adopt"
@@ -3025,7 +3016,7 @@ exports.getEnvelopeDocumentPageDisplayUri = getEnvelopeDocumentPageDisplayUri;
3025
3016
  exports.getEnvelopeFile = getEnvelopeFile;
3026
3017
  exports.getEnvelopeRecipients = getEnvelopeRecipients;
3027
3018
  exports.getEnvelopeReminder = getEnvelopeReminder;
3028
- exports.getEnvelopesByTemplateId = getEnvelopesByTemplateId;
3019
+ exports.getEnvelopes = getEnvelopes;
3029
3020
  exports.getEnvelopesSummary = getEnvelopesSummary;
3030
3021
  exports.getFieldAttachment = getFieldAttachment;
3031
3022
  exports.getFieldsForRole = getFieldsForRole;
@@ -3087,7 +3078,6 @@ exports.isValidEmail = isValidEmail;
3087
3078
  exports.isValidPhone = isValidPhone;
3088
3079
  exports.isValidRoleName = isValidRoleName;
3089
3080
  exports.isValidTag = isValidTag;
3090
- exports.listEnvelopes = listEnvelopes;
3091
3081
  exports.listTemplates = listTemplates;
3092
3082
  exports.nameToRGBA = nameToRGBA;
3093
3083
  exports.recipientCanAct = recipientCanAct;