@verdocs/js-sdk 4.2.135 → 4.2.136
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 +9 -6
- package/dist/index.d.ts +9 -6
- package/dist/index.js +4 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -6
- package/dist/index.mjs.map +1 -1
- package/dist/package.json +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -744,9 +744,11 @@ interface ITemplate {
|
|
|
744
744
|
*/
|
|
745
745
|
organization_id: string;
|
|
746
746
|
/**
|
|
747
|
-
* Who
|
|
747
|
+
* Who will "own" envelopes created from this template. Note that while either option is
|
|
748
|
+
* technically allowed for all visibility settings, "template_owner" only has an effect if
|
|
749
|
+
* visibility is "shared" or "public".
|
|
748
750
|
*/
|
|
749
|
-
sender:
|
|
751
|
+
sender: TTemplateSender;
|
|
750
752
|
/*
|
|
751
753
|
The user-supplied name of the template.
|
|
752
754
|
*/
|
|
@@ -898,7 +900,7 @@ interface ITemplateFieldSetting {
|
|
|
898
900
|
[key: string]: any;
|
|
899
901
|
}
|
|
900
902
|
type TRequestStatus = "OK" | "ERROR";
|
|
901
|
-
type
|
|
903
|
+
type TTemplateSender = "envelope_creator" | "template_owner";
|
|
902
904
|
type TTemplateAction = "create_personal" | "create_org" | "create_public" | "read" | "write" | "delete" | "change_visibility_personal" | "change_visibility_org" | "change_visibility_public";
|
|
903
905
|
type TRecipientAction = "submit" | "decline" | "prepare" | "update";
|
|
904
906
|
type TEnvelopeStatus = "complete" | "pending" | "in progress" | "declined" | "canceled";
|
|
@@ -2455,6 +2457,7 @@ declare const getTag: (endpoint: VerdocsEndpoint, name: string) => Promise<ITag>
|
|
|
2455
2457
|
*/
|
|
2456
2458
|
declare const getAllTags: (endpoint: VerdocsEndpoint) => Promise<ITag[]>;
|
|
2457
2459
|
type ITemplateSortBy = "created_at" | "updated_at" | "name" | "last_used_at" | "counter" | "star_counter";
|
|
2460
|
+
type TTemplateVisibilityFilter = "private_shared" | "private" | "shared" | "public";
|
|
2458
2461
|
interface IGetTemplatesParams {
|
|
2459
2462
|
/** List only those templates whose names, descriptions, etc contain this search term. */
|
|
2460
2463
|
q?: string;
|
|
@@ -2463,7 +2466,7 @@ interface IGetTemplatesParams {
|
|
|
2463
2466
|
/** List only those templates created by the caller. */
|
|
2464
2467
|
is_creator?: boolean;
|
|
2465
2468
|
/** Visibility status of templates to include. private_shared is the default (private + shared) */
|
|
2466
|
-
visibility:
|
|
2469
|
+
visibility: TTemplateVisibilityFilter;
|
|
2467
2470
|
/** Sort order */
|
|
2468
2471
|
sort_by?: TSortTemplateBy;
|
|
2469
2472
|
/** Set to true or false to control the sort order. Omit this field to sort dates descending, names ascending. */
|
|
@@ -2542,7 +2545,7 @@ interface ITemplateCreateParams {
|
|
|
2542
2545
|
*/
|
|
2543
2546
|
is_public?: boolean;
|
|
2544
2547
|
/** Optional (defaults to EVERYONE_AS_CREATOR). Who may create and send envelopes using this template. */
|
|
2545
|
-
sender?:
|
|
2548
|
+
sender?: TTemplateSender;
|
|
2546
2549
|
/** Delay (in seconds) before the first reminder is sent (min: 4hrs). Set to 0 or null to disable. */
|
|
2547
2550
|
initial_reminder?: number;
|
|
2548
2551
|
/** Delay (in seconds) before subsequent remidners are sent (min: 12hrs). Set to 0 or null to disable. */
|
|
@@ -2821,4 +2824,4 @@ declare const decodeJWTBody: (token: string) => any;
|
|
|
2821
2824
|
* the presence of the `document_id` field, which will only be present for signing sessions.
|
|
2822
2825
|
*/
|
|
2823
2826
|
declare const decodeAccessTokenBody: (token: string) => TSession;
|
|
2824
|
-
export { TRequestStatus,
|
|
2827
|
+
export { TRequestStatus, TTemplateSender, TTemplateAction, TRecipientAction, TEnvelopeStatus, TRecipientStatus, TRecipientType, TSortTemplateBy, TAccessKeyType, TApiKeyPermission, TDeprecatedHistoryEvent, THistoryEvent, TEventDetail, TEnvelopeUpdateResult, TFieldType, TWebhookEvent, TTemplateVisibility, FIELD_TYPES, DEFAULT_FIELD_WIDTHS, DEFAULT_FIELD_HEIGHTS, WEBHOOK_EVENTS, ALL_PERMISSIONS, IChannel, IDisabledChannel, INotification, IApiKey, IGroup, IGroupProfile, IOAuth2App, IOrganization, IOrganizationInvitation, IPendingWebhook, IProfile, IUser, IWebhookEvents, IWebhook, IInPersonAccessKey, IInAppAccessKey, IEmailAccessKey, ISMSAccessKey, TAccessKey, IEnvelope, IEnvelopeDocument, IDropdownOption, IEnvelopeField, IEnvelopeFieldOptions, IEnvelopeFieldSettings, IEnvelopeHistory, IInitial, IKbaPINRequired, IRecipient, IRole, ISignature, ITemplate, ITemplateDocument, ITemplateField, ITextFieldSetting, ITemplateFieldSetting, TEnvironment, TSessionChangedListener, VerdocsEndpointOptions, VerdocsEndpoint, createEnvelope, getEnvelope, getEnvelopeDocument, getDocumentDownloadLink, getDocumentPreviewLink, cancelEnvelope, getEnvelopeFile, updateEnvelope, updateEnvelopeField, updateEnvelopeFieldSignature, updateEnvelopeFieldInitials, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, getFieldAttachment, getEnvelopeDocumentPageDisplayUri, ITimeRange, IListEnvelopesParams, getEnvelopes, createInitials, IRecipientKbaStepNone, IRecipientKbaStepComplete, IRecipientKbaStepPin, IRecipientKbaStepIdentity, IRecipientKbaStepChallenge, IRecipientKbaStepFailed, TRecipientKbaStep, getKbaStep, submitKbaPin, IKbaIdentity, submitKbaIdentity, IKbaChallengeResponse, submitKbaChallengeResponse, updateRecipient, envelopeRecipientSubmit, envelopeRecipientDecline, envelopeRecipientChangeOwner, envelopeRecipientAgree, envelopeRecipientUpdateName, envelopeRecipientPrepare, startSigningSession, getInPersonLink, sendDelegate, resendInvitation, userIsEnvelopeOwner, userIsEnvelopeRecipient, envelopeIsActive, envelopeIsComplete, userCanCancelEnvelope, userCanFinishEnvelope, recipientHasAction, getRecipientsWithActions, recipientCanAct, userCanAct, userCanSignNow, getNextRecipient, createSignature, getSignatures, getSignature, deleteSignature, IEnvelopesSearchResult, IDocumentSearchOptions, ICreateEnvelopeRecipient, ISignerTokenResponse, IInPersonLinkResponse, IUpdateRecipientSubmitParams, IUpdateRecipientDeclineParams, IUpdateRecipientClaimEnvelope, IUpdateRecipientStatus, IUpdateRecipientAgreedParams, IUpdateRecipientNameParams, IUpdateRecipientPrepareParams, ICreateEnvelopeReminderRequest, ICreateEnvelopeFromTemplateRequest, ICreateEnvelopeDirectlyRequest, TCreateEnvelopeRequest, getApiKeys, createApiKey, rotateApiKey, updateApiKey, deleteApiKey, getOrganizationContacts, deleteOrganizationContact, createOrganizationContact, updateOrganizationContact, getGroups, getGroup, createGroup, updateGroup, deleteGroup, addGroupMember, deleteGroupMember, getOrganizationInvitations, createOrganizationInvitation, deleteOrganizationInvitation, updateOrganizationInvitation, resendOrganizationInvitation, getOrganizationInvitation, acceptOrganizationInvitation, declineOrganizationInvitation, getOrganizationMembers, deleteOrganizationMember, updateOrganizationMember, getOrganization, createOrganization, updateOrganization, deleteOrganization, 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, ISigningSession, IUserSession, IIdToken, 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, createTemplateRole, updateTemplateRole, deleteTemplateRole, getStars, toggleStar, addTemplateTag, getTemplateTags, deleteTemplateTag, createTag, getTag, getAllTags, ITemplateSortBy, TTemplateVisibilityFilter, IGetTemplatesParams, getTemplates, getTemplate, IDocumentFromUri, IDocumentFromData, ITemplateCreateParams, createTemplate, duplicateTemplate, ITemplateCreateFromSharepointParams, createTemplateFromSharepoint, updateTemplate, deleteTemplate, getTemplateDocuments, getTemplateDocument, createTemplateDocument, deleteTemplateDocument, getTemplateDocumentFile, getTemplateDocumentThumbnail, getTemplateDocumentPageDisplayUri, ITemplateTag, ITag, IStar, ITemplateSearchResult, IValidator, getValidators, getValidator, isValidEmail, isValidPhone, isValidRoleName, isValidTag, IROPCRequest, IClientCredentialsRequest, IRefreshTokenRequest, TAuthenticationRequest, authenticate, refreshToken, changePassword, resetPassword, resendVerification, verifyEmail, getMyUser, getNotifications, getProfiles, getCurrentProfile, switchProfile, updateProfile, deleteProfile, createProfile, updateProfilePhoto, ICreateProfileRequest, IUpdateProfileRequest, IAuthenticateResponse, IChangePasswordRequest, IChangePasswordResponse, IResetPasswordRequest, IResetPasswordResponse, IVerifyEmailRequest, getRGB, getRGBA, nameToRGBA, getRoleColor, formatShortTimeAgo, getRTop, getRLeft, getRValue, blobToBase64, rescale, sortFields, fileToDataUrl, downloadBlob, Countries, getCountryByCode, isFrenchGuiana, isGuadeloupe, isMartinique, isMayotte, getPlusOneCountry, isCanada, isAmericanSamoa, isDominicanRepublic, isPuertoRico, getMatchingCountry, integerSequence, formatFullName, formatInitials, fullNameToInitials, capitalize, convertToE164, randomString, AtoB, decodeJWTBody, decodeAccessTokenBody, IFileWithData, ICountry };
|
package/dist/index.d.ts
CHANGED
|
@@ -744,9 +744,11 @@ interface ITemplate {
|
|
|
744
744
|
*/
|
|
745
745
|
organization_id: string;
|
|
746
746
|
/**
|
|
747
|
-
* Who
|
|
747
|
+
* Who will "own" envelopes created from this template. Note that while either option is
|
|
748
|
+
* technically allowed for all visibility settings, "template_owner" only has an effect if
|
|
749
|
+
* visibility is "shared" or "public".
|
|
748
750
|
*/
|
|
749
|
-
sender:
|
|
751
|
+
sender: TTemplateSender;
|
|
750
752
|
/*
|
|
751
753
|
The user-supplied name of the template.
|
|
752
754
|
*/
|
|
@@ -898,7 +900,7 @@ interface ITemplateFieldSetting {
|
|
|
898
900
|
[key: string]: any;
|
|
899
901
|
}
|
|
900
902
|
type TRequestStatus = "OK" | "ERROR";
|
|
901
|
-
type
|
|
903
|
+
type TTemplateSender = "envelope_creator" | "template_owner";
|
|
902
904
|
type TTemplateAction = "create_personal" | "create_org" | "create_public" | "read" | "write" | "delete" | "change_visibility_personal" | "change_visibility_org" | "change_visibility_public";
|
|
903
905
|
type TRecipientAction = "submit" | "decline" | "prepare" | "update";
|
|
904
906
|
type TEnvelopeStatus = "complete" | "pending" | "in progress" | "declined" | "canceled";
|
|
@@ -2455,6 +2457,7 @@ declare const getTag: (endpoint: VerdocsEndpoint, name: string) => Promise<ITag>
|
|
|
2455
2457
|
*/
|
|
2456
2458
|
declare const getAllTags: (endpoint: VerdocsEndpoint) => Promise<ITag[]>;
|
|
2457
2459
|
type ITemplateSortBy = "created_at" | "updated_at" | "name" | "last_used_at" | "counter" | "star_counter";
|
|
2460
|
+
type TTemplateVisibilityFilter = "private_shared" | "private" | "shared" | "public";
|
|
2458
2461
|
interface IGetTemplatesParams {
|
|
2459
2462
|
/** List only those templates whose names, descriptions, etc contain this search term. */
|
|
2460
2463
|
q?: string;
|
|
@@ -2463,7 +2466,7 @@ interface IGetTemplatesParams {
|
|
|
2463
2466
|
/** List only those templates created by the caller. */
|
|
2464
2467
|
is_creator?: boolean;
|
|
2465
2468
|
/** Visibility status of templates to include. private_shared is the default (private + shared) */
|
|
2466
|
-
visibility:
|
|
2469
|
+
visibility: TTemplateVisibilityFilter;
|
|
2467
2470
|
/** Sort order */
|
|
2468
2471
|
sort_by?: TSortTemplateBy;
|
|
2469
2472
|
/** Set to true or false to control the sort order. Omit this field to sort dates descending, names ascending. */
|
|
@@ -2542,7 +2545,7 @@ interface ITemplateCreateParams {
|
|
|
2542
2545
|
*/
|
|
2543
2546
|
is_public?: boolean;
|
|
2544
2547
|
/** Optional (defaults to EVERYONE_AS_CREATOR). Who may create and send envelopes using this template. */
|
|
2545
|
-
sender?:
|
|
2548
|
+
sender?: TTemplateSender;
|
|
2546
2549
|
/** Delay (in seconds) before the first reminder is sent (min: 4hrs). Set to 0 or null to disable. */
|
|
2547
2550
|
initial_reminder?: number;
|
|
2548
2551
|
/** Delay (in seconds) before subsequent remidners are sent (min: 12hrs). Set to 0 or null to disable. */
|
|
@@ -2821,4 +2824,4 @@ declare const decodeJWTBody: (token: string) => any;
|
|
|
2821
2824
|
* the presence of the `document_id` field, which will only be present for signing sessions.
|
|
2822
2825
|
*/
|
|
2823
2826
|
declare const decodeAccessTokenBody: (token: string) => TSession;
|
|
2824
|
-
export { TRequestStatus,
|
|
2827
|
+
export { TRequestStatus, TTemplateSender, TTemplateAction, TRecipientAction, TEnvelopeStatus, TRecipientStatus, TRecipientType, TSortTemplateBy, TAccessKeyType, TApiKeyPermission, TDeprecatedHistoryEvent, THistoryEvent, TEventDetail, TEnvelopeUpdateResult, TFieldType, TWebhookEvent, TTemplateVisibility, FIELD_TYPES, DEFAULT_FIELD_WIDTHS, DEFAULT_FIELD_HEIGHTS, WEBHOOK_EVENTS, ALL_PERMISSIONS, IChannel, IDisabledChannel, INotification, IApiKey, IGroup, IGroupProfile, IOAuth2App, IOrganization, IOrganizationInvitation, IPendingWebhook, IProfile, IUser, IWebhookEvents, IWebhook, IInPersonAccessKey, IInAppAccessKey, IEmailAccessKey, ISMSAccessKey, TAccessKey, IEnvelope, IEnvelopeDocument, IDropdownOption, IEnvelopeField, IEnvelopeFieldOptions, IEnvelopeFieldSettings, IEnvelopeHistory, IInitial, IKbaPINRequired, IRecipient, IRole, ISignature, ITemplate, ITemplateDocument, ITemplateField, ITextFieldSetting, ITemplateFieldSetting, TEnvironment, TSessionChangedListener, VerdocsEndpointOptions, VerdocsEndpoint, createEnvelope, getEnvelope, getEnvelopeDocument, getDocumentDownloadLink, getDocumentPreviewLink, cancelEnvelope, getEnvelopeFile, updateEnvelope, updateEnvelopeField, updateEnvelopeFieldSignature, updateEnvelopeFieldInitials, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, getFieldAttachment, getEnvelopeDocumentPageDisplayUri, ITimeRange, IListEnvelopesParams, getEnvelopes, createInitials, IRecipientKbaStepNone, IRecipientKbaStepComplete, IRecipientKbaStepPin, IRecipientKbaStepIdentity, IRecipientKbaStepChallenge, IRecipientKbaStepFailed, TRecipientKbaStep, getKbaStep, submitKbaPin, IKbaIdentity, submitKbaIdentity, IKbaChallengeResponse, submitKbaChallengeResponse, updateRecipient, envelopeRecipientSubmit, envelopeRecipientDecline, envelopeRecipientChangeOwner, envelopeRecipientAgree, envelopeRecipientUpdateName, envelopeRecipientPrepare, startSigningSession, getInPersonLink, sendDelegate, resendInvitation, userIsEnvelopeOwner, userIsEnvelopeRecipient, envelopeIsActive, envelopeIsComplete, userCanCancelEnvelope, userCanFinishEnvelope, recipientHasAction, getRecipientsWithActions, recipientCanAct, userCanAct, userCanSignNow, getNextRecipient, createSignature, getSignatures, getSignature, deleteSignature, IEnvelopesSearchResult, IDocumentSearchOptions, ICreateEnvelopeRecipient, ISignerTokenResponse, IInPersonLinkResponse, IUpdateRecipientSubmitParams, IUpdateRecipientDeclineParams, IUpdateRecipientClaimEnvelope, IUpdateRecipientStatus, IUpdateRecipientAgreedParams, IUpdateRecipientNameParams, IUpdateRecipientPrepareParams, ICreateEnvelopeReminderRequest, ICreateEnvelopeFromTemplateRequest, ICreateEnvelopeDirectlyRequest, TCreateEnvelopeRequest, getApiKeys, createApiKey, rotateApiKey, updateApiKey, deleteApiKey, getOrganizationContacts, deleteOrganizationContact, createOrganizationContact, updateOrganizationContact, getGroups, getGroup, createGroup, updateGroup, deleteGroup, addGroupMember, deleteGroupMember, getOrganizationInvitations, createOrganizationInvitation, deleteOrganizationInvitation, updateOrganizationInvitation, resendOrganizationInvitation, getOrganizationInvitation, acceptOrganizationInvitation, declineOrganizationInvitation, getOrganizationMembers, deleteOrganizationMember, updateOrganizationMember, getOrganization, createOrganization, updateOrganization, deleteOrganization, 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, ISigningSession, IUserSession, IIdToken, 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, createTemplateRole, updateTemplateRole, deleteTemplateRole, getStars, toggleStar, addTemplateTag, getTemplateTags, deleteTemplateTag, createTag, getTag, getAllTags, ITemplateSortBy, TTemplateVisibilityFilter, IGetTemplatesParams, getTemplates, getTemplate, IDocumentFromUri, IDocumentFromData, ITemplateCreateParams, createTemplate, duplicateTemplate, ITemplateCreateFromSharepointParams, createTemplateFromSharepoint, updateTemplate, deleteTemplate, getTemplateDocuments, getTemplateDocument, createTemplateDocument, deleteTemplateDocument, getTemplateDocumentFile, getTemplateDocumentThumbnail, getTemplateDocumentPageDisplayUri, ITemplateTag, ITag, IStar, ITemplateSearchResult, IValidator, getValidators, getValidator, isValidEmail, isValidPhone, isValidRoleName, isValidTag, IROPCRequest, IClientCredentialsRequest, IRefreshTokenRequest, TAuthenticationRequest, authenticate, refreshToken, changePassword, resetPassword, resendVerification, verifyEmail, getMyUser, getNotifications, getProfiles, getCurrentProfile, switchProfile, updateProfile, deleteProfile, createProfile, updateProfilePhoto, ICreateProfileRequest, IUpdateProfileRequest, IAuthenticateResponse, IChangePasswordRequest, IChangePasswordResponse, IResetPasswordRequest, IResetPasswordResponse, IVerifyEmailRequest, getRGB, getRGBA, nameToRGBA, getRoleColor, formatShortTimeAgo, getRTop, getRLeft, getRValue, blobToBase64, rescale, sortFields, fileToDataUrl, downloadBlob, Countries, getCountryByCode, isFrenchGuiana, isGuadeloupe, isMartinique, isMayotte, getPlusOneCountry, isCanada, isAmericanSamoa, isDominicanRepublic, isPuertoRico, getMatchingCountry, integerSequence, formatFullName, formatInitials, fullNameToInitials, capitalize, convertToE164, randomString, AtoB, decodeJWTBody, decodeAccessTokenBody, IFileWithData, ICountry };
|
package/dist/index.js
CHANGED
|
@@ -2591,14 +2591,12 @@ const userCanDeleteTemplate = (profile, template) => userIsTemplateCreator(profi
|
|
|
2591
2591
|
* Confirm whether the user can create an envelope using the specified template.
|
|
2592
2592
|
*/
|
|
2593
2593
|
const userCanSendTemplate = (profile, template) => {
|
|
2594
|
-
switch (template.
|
|
2595
|
-
case '
|
|
2594
|
+
switch (template.visibility) {
|
|
2595
|
+
case 'private':
|
|
2596
2596
|
return userIsTemplateCreator(profile, template);
|
|
2597
|
-
case '
|
|
2598
|
-
case 'organization_member_as_creator':
|
|
2597
|
+
case 'shared':
|
|
2599
2598
|
return userIsTemplateCreator(profile, template) || template.organization_id === profile?.organization_id;
|
|
2600
|
-
|
|
2601
|
-
default:
|
|
2599
|
+
case 'public':
|
|
2602
2600
|
return true;
|
|
2603
2601
|
}
|
|
2604
2602
|
};
|