@verdocs/js-sdk 3.10.30 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/README.md +75 -0
- package/dist/index.d.mts +41294 -0
- package/dist/index.d.ts +41294 -0
- package/dist/index.js +3045 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +3036 -0
- package/dist/index.mjs.map +1 -0
- package/dist/package.json +85 -0
- package/dist/tsconfig.json +16 -0
- package/package.json +29 -12
- package/.github/workflows/generate-docs.yml +0 -41
- package/Envelopes/Envelopes.d.ts +0 -242
- package/Envelopes/Envelopes.js +0 -339
- package/Envelopes/Initials.d.ts +0 -15
- package/Envelopes/Initials.js +0 -13
- package/Envelopes/Permissions.d.ts +0 -52
- package/Envelopes/Permissions.js +0 -84
- package/Envelopes/Recipients.d.ts +0 -89
- package/Envelopes/Recipients.js +0 -112
- package/Envelopes/Reminders.d.ts +0 -23
- package/Envelopes/Reminders.js +0 -33
- package/Envelopes/Signatures.d.ts +0 -28
- package/Envelopes/Signatures.js +0 -37
- package/Envelopes/Types.d.ts +0 -390
- package/Envelopes/Types.js +0 -45
- package/Envelopes/index.d.ts +0 -7
- package/Envelopes/index.js +0 -7
- package/Organizations/ApiKeys.d.ts +0 -64
- package/Organizations/ApiKeys.js +0 -82
- package/Organizations/Groups.d.ts +0 -47
- package/Organizations/Groups.js +0 -76
- package/Organizations/Invitations.d.ts +0 -24
- package/Organizations/Invitations.js +0 -45
- package/Organizations/Members.d.ts +0 -12
- package/Organizations/Members.js +0 -30
- package/Organizations/Organizations.d.ts +0 -27
- package/Organizations/Organizations.js +0 -45
- package/Organizations/Types.d.ts +0 -104
- package/Organizations/Types.js +0 -1
- package/Organizations/Webhooks.d.ts +0 -34
- package/Organizations/Webhooks.js +0 -10
- package/Organizations/Whitelabel.d.ts +0 -31
- package/Organizations/Whitelabel.js +0 -38
- package/Organizations/index.d.ts +0 -16
- package/Organizations/index.js +0 -16
- package/Sessions/Types.d.ts +0 -54
- package/Sessions/Types.js +0 -1
- package/Sessions/index.d.ts +0 -6
- package/Sessions/index.js +0 -7
- package/Templates/Actions.d.ts +0 -26
- package/Templates/Actions.js +0 -104
- package/Templates/Fields.d.ts +0 -14
- package/Templates/Fields.js +0 -24
- package/Templates/Pages.d.ts +0 -30
- package/Templates/Pages.js +0 -41
- package/Templates/Permissions.d.ts +0 -73
- package/Templates/Permissions.js +0 -124
- package/Templates/Reminders.d.ts +0 -23
- package/Templates/Reminders.js +0 -33
- package/Templates/Roles.d.ts +0 -16
- package/Templates/Roles.js +0 -42
- package/Templates/Stars.d.ts +0 -10
- package/Templates/Stars.js +0 -16
- package/Templates/Tags.d.ts +0 -33
- package/Templates/Tags.js +0 -55
- package/Templates/TemplateDocuments.d.ts +0 -66
- package/Templates/TemplateDocuments.js +0 -139
- package/Templates/Templates.d.ts +0 -284
- package/Templates/Templates.js +0 -309
- package/Templates/Types.d.ts +0 -346
- package/Templates/Types.js +0 -29
- package/Templates/Validators.d.ts +0 -21
- package/Templates/Validators.js +0 -27
- package/Templates/index.d.ts +0 -11
- package/Templates/index.js +0 -11
- package/Users/Auth.d.ts +0 -123
- package/Users/Auth.js +0 -142
- package/Users/Billing.d.ts +0 -1
- package/Users/Billing.js +0 -2
- package/Users/Notifications.d.ts +0 -2
- package/Users/Notifications.js +0 -43
- package/Users/Profiles.d.ts +0 -151
- package/Users/Profiles.js +0 -179
- package/Users/Types.d.ts +0 -146
- package/Users/Types.js +0 -47
- package/Users/index.d.ts +0 -5
- package/Users/index.js +0 -5
- package/Utils/Colors.d.ts +0 -18
- package/Utils/Colors.js +0 -102
- package/Utils/DateTime.d.ts +0 -6
- package/Utils/DateTime.js +0 -79
- package/Utils/Fields.d.ts +0 -5
- package/Utils/Fields.js +0 -24
- package/Utils/Files.d.ts +0 -16
- package/Utils/Files.js +0 -42
- package/Utils/Locales.d.ts +0 -17
- package/Utils/Locales.js +0 -1358
- package/Utils/Primitives.d.ts +0 -18
- package/Utils/Primitives.js +0 -31
- package/Utils/Strings.d.ts +0 -9
- package/Utils/Strings.js +0 -28
- package/Utils/Token.d.ts +0 -19
- package/Utils/Token.js +0 -67
- package/Utils/globalThis.d.ts +0 -2
- package/Utils/globalThis.js +0 -52
- package/Utils/index.d.ts +0 -8
- package/Utils/index.js +0 -8
- package/VerdocsEndpoint.d.ts +0 -199
- package/VerdocsEndpoint.js +0 -319
- package/index.d.ts +0 -18
- package/index.js +0 -18
- package/tsconfig-typedoc.json +0 -26
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@verdocs/js-sdk",
|
|
3
|
+
"version": "4.0.0",
|
|
4
|
+
"private": false,
|
|
5
|
+
"homepage": "https://github.com/Verdocs/js-sdk",
|
|
6
|
+
"description": "Isomorphic JS SDK providing types and API wrappers for the Verdocs platform",
|
|
7
|
+
"keywords": [
|
|
8
|
+
"pdf",
|
|
9
|
+
"document",
|
|
10
|
+
"signing",
|
|
11
|
+
"Verdocs",
|
|
12
|
+
"embed"
|
|
13
|
+
],
|
|
14
|
+
"author": "Verdocs, LLC",
|
|
15
|
+
"license": "MIT",
|
|
16
|
+
"main": "dist/index.js",
|
|
17
|
+
"module": "dist/index.mjs",
|
|
18
|
+
"types": "dist/index.d.ts",
|
|
19
|
+
"source": "./src/index.ts",
|
|
20
|
+
"browser": "dist/browser.js",
|
|
21
|
+
"files": [
|
|
22
|
+
"dist/*",
|
|
23
|
+
"node.js",
|
|
24
|
+
"browser.js",
|
|
25
|
+
"README.md"
|
|
26
|
+
],
|
|
27
|
+
"repository": {
|
|
28
|
+
"type": "git",
|
|
29
|
+
"url": "git://github.com/Verdocs/js-sdk.git"
|
|
30
|
+
},
|
|
31
|
+
"bugs": {
|
|
32
|
+
"url": "https://github.com/Verdocs/js-sdk/issues"
|
|
33
|
+
},
|
|
34
|
+
"scripts": {
|
|
35
|
+
"buildX": "npm run clean && npm run docs && tsc && npm run lint",
|
|
36
|
+
"build": "rollup -c --sourcemap --bundleConfigAsCjs",
|
|
37
|
+
"prepare": "npm run build",
|
|
38
|
+
"prepublishOnly": "npm run lint",
|
|
39
|
+
"preversion": "npm run lint",
|
|
40
|
+
"version": "npm run format && git add -A src",
|
|
41
|
+
"postversion": "git push && git push --tags",
|
|
42
|
+
"postpublish": "npm run clean",
|
|
43
|
+
"test": "node --experimental-vm-modules node_modules/jest/bin/jest.js --config jestconfig.json",
|
|
44
|
+
"format": "prettier --write \"src/**/*.ts\"",
|
|
45
|
+
"lint": "tslint -p tsconfig.json",
|
|
46
|
+
"docs-md": "typedoc --tsconfig ./tsconfig-typedoc.json",
|
|
47
|
+
"docs-html": "typedoc --tsconfig ./tsconfig-typedoc.json --out docs-html",
|
|
48
|
+
"Xdocs-html": "typedoc --tsconfig ./tsconfig-typedoc.json --plugin none --out docs-html",
|
|
49
|
+
"docs": "npm run docs-md && npm run docs-html",
|
|
50
|
+
"clear-docs": "aws --profile=verdocs cloudfront create-invalidation --distribution-id E29UFGU4KEH1GQ --paths \"/*\"",
|
|
51
|
+
"deploy-docs": "npm run docs && aws --profile=verdocs s3 sync --acl public-read --delete docs-html s3://verdocs-developers-js-sdk/ && yarn clear-docs",
|
|
52
|
+
"clean": "rm -rf Envelopes Sessions HTTP Organizations Search Templates Users Utils index.js index.d.ts VerdocsEndpoint.* docs docs-html",
|
|
53
|
+
"push": "npm run build && npm publish"
|
|
54
|
+
},
|
|
55
|
+
"publishConfig": {
|
|
56
|
+
"access": "public"
|
|
57
|
+
},
|
|
58
|
+
"dependencies": {
|
|
59
|
+
"axios": "^1.7.2"
|
|
60
|
+
},
|
|
61
|
+
"peerDependencies": {
|
|
62
|
+
"typescript": "^5.4.5"
|
|
63
|
+
},
|
|
64
|
+
"devDependencies": {
|
|
65
|
+
"@jest/globals": "^29.7.0",
|
|
66
|
+
"@rollup/plugin-commonjs": "^26.0.1",
|
|
67
|
+
"@rollup/plugin-typescript": "^11.1.6",
|
|
68
|
+
"@types/jest": "^29.5.12",
|
|
69
|
+
"axios-mock-adapter": "^1.22.0",
|
|
70
|
+
"esbuild": "^0.21.5",
|
|
71
|
+
"jest": "^29.7.0",
|
|
72
|
+
"jest-environment-jsdom": "^29.7.0",
|
|
73
|
+
"prettier": "^3.3.2",
|
|
74
|
+
"rollup": "^4.18.0",
|
|
75
|
+
"rollup-plugin-clear": "^2.0.7",
|
|
76
|
+
"rollup-plugin-copy": "^3.5.0",
|
|
77
|
+
"rollup-plugin-ts": "^3.4.5",
|
|
78
|
+
"ts-jest": "^29.1.4",
|
|
79
|
+
"tslint": "^6.1.3",
|
|
80
|
+
"tslint-config-prettier": "^1.18.0",
|
|
81
|
+
"typedoc": "^0.25.13",
|
|
82
|
+
"typedoc-plugin-markdown": "^4.0.3",
|
|
83
|
+
"typescript": "^5.4.5"
|
|
84
|
+
}
|
|
85
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "esnext",
|
|
4
|
+
"module": "esnext",
|
|
5
|
+
"lib": ["es2017", "es7", "es6", "dom"],
|
|
6
|
+
"declaration": true,
|
|
7
|
+
"allowJs": true,
|
|
8
|
+
"strict": true,
|
|
9
|
+
"noEmit": false,
|
|
10
|
+
"esModuleInterop": true,
|
|
11
|
+
"moduleResolution": "node",
|
|
12
|
+
"strictNullChecks": true
|
|
13
|
+
},
|
|
14
|
+
"include": ["src"],
|
|
15
|
+
"exclude": ["node_modules", "dist", "**/__tests__/*"]
|
|
16
|
+
}
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@verdocs/js-sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"homepage": "https://github.com/Verdocs/js-sdk",
|
|
6
|
-
"description": "
|
|
6
|
+
"description": "Isomorphic JS SDK providing types and API wrappers for the Verdocs platform",
|
|
7
7
|
"keywords": [
|
|
8
8
|
"pdf",
|
|
9
9
|
"document",
|
|
@@ -13,8 +13,17 @@
|
|
|
13
13
|
],
|
|
14
14
|
"author": "Verdocs, LLC",
|
|
15
15
|
"license": "MIT",
|
|
16
|
-
"main": "index.js",
|
|
17
|
-
"
|
|
16
|
+
"main": "dist/index.js",
|
|
17
|
+
"module": "dist/index.mjs",
|
|
18
|
+
"types": "dist/index.d.ts",
|
|
19
|
+
"source": "./src/index.ts",
|
|
20
|
+
"browser": "dist/browser.js",
|
|
21
|
+
"files": [
|
|
22
|
+
"dist/*",
|
|
23
|
+
"node.js",
|
|
24
|
+
"browser.js",
|
|
25
|
+
"README.md"
|
|
26
|
+
],
|
|
18
27
|
"repository": {
|
|
19
28
|
"type": "git",
|
|
20
29
|
"url": "git://github.com/Verdocs/js-sdk.git"
|
|
@@ -23,7 +32,8 @@
|
|
|
23
32
|
"url": "https://github.com/Verdocs/js-sdk/issues"
|
|
24
33
|
},
|
|
25
34
|
"scripts": {
|
|
26
|
-
"
|
|
35
|
+
"buildX": "npm run clean && npm run docs && tsc && npm run lint",
|
|
36
|
+
"build": "rollup -c --sourcemap --bundleConfigAsCjs",
|
|
27
37
|
"prepare": "npm run build",
|
|
28
38
|
"prepublishOnly": "npm run lint",
|
|
29
39
|
"preversion": "npm run lint",
|
|
@@ -46,23 +56,30 @@
|
|
|
46
56
|
"access": "public"
|
|
47
57
|
},
|
|
48
58
|
"dependencies": {
|
|
49
|
-
"axios": "^1.
|
|
59
|
+
"axios": "^1.7.2"
|
|
50
60
|
},
|
|
51
61
|
"peerDependencies": {
|
|
52
|
-
"typescript": "^5.
|
|
62
|
+
"typescript": "^5.4.5"
|
|
53
63
|
},
|
|
54
64
|
"devDependencies": {
|
|
55
65
|
"@jest/globals": "^29.7.0",
|
|
66
|
+
"@rollup/plugin-commonjs": "^26.0.1",
|
|
67
|
+
"@rollup/plugin-typescript": "^11.1.6",
|
|
56
68
|
"@types/jest": "^29.5.12",
|
|
57
69
|
"axios-mock-adapter": "^1.22.0",
|
|
70
|
+
"esbuild": "^0.21.5",
|
|
58
71
|
"jest": "^29.7.0",
|
|
59
72
|
"jest-environment-jsdom": "^29.7.0",
|
|
60
|
-
"prettier": "^3.2
|
|
61
|
-
"
|
|
73
|
+
"prettier": "^3.3.2",
|
|
74
|
+
"rollup": "^4.18.0",
|
|
75
|
+
"rollup-plugin-clear": "^2.0.7",
|
|
76
|
+
"rollup-plugin-copy": "^3.5.0",
|
|
77
|
+
"rollup-plugin-ts": "^3.4.5",
|
|
78
|
+
"ts-jest": "^29.1.4",
|
|
62
79
|
"tslint": "^6.1.3",
|
|
63
80
|
"tslint-config-prettier": "^1.18.0",
|
|
64
|
-
"typedoc": "^0.25.
|
|
65
|
-
"typedoc-plugin-markdown": "^
|
|
66
|
-
"typescript": "^5.
|
|
81
|
+
"typedoc": "^0.25.13",
|
|
82
|
+
"typedoc-plugin-markdown": "^4.0.3",
|
|
83
|
+
"typescript": "^5.4.5"
|
|
67
84
|
}
|
|
68
85
|
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
name: Generate Docs
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- main
|
|
7
|
-
paths:
|
|
8
|
-
- "src/**"
|
|
9
|
-
- "README.md"
|
|
10
|
-
- "package.json"
|
|
11
|
-
- "tsconfig-typedoc.json"
|
|
12
|
-
- ".github/workflows/generate-docs.yml"
|
|
13
|
-
|
|
14
|
-
defaults:
|
|
15
|
-
run:
|
|
16
|
-
shell: bash
|
|
17
|
-
|
|
18
|
-
# We only want to run one job at a time in this group
|
|
19
|
-
concurrency:
|
|
20
|
-
group: api-sdk-docs
|
|
21
|
-
cancel-in-progress: true
|
|
22
|
-
|
|
23
|
-
jobs:
|
|
24
|
-
deploy:
|
|
25
|
-
name: Deploy Docs
|
|
26
|
-
runs-on: ubuntu-latest
|
|
27
|
-
steps:
|
|
28
|
-
- name: Checkout 🛎️
|
|
29
|
-
uses: actions/checkout@v2
|
|
30
|
-
|
|
31
|
-
- name: Install and Build 🔧
|
|
32
|
-
run: |
|
|
33
|
-
npm ci
|
|
34
|
-
npm run build
|
|
35
|
-
|
|
36
|
-
- name: Deploy 🚀
|
|
37
|
-
uses: JamesIves/github-pages-deploy-action@v4.2.3
|
|
38
|
-
with:
|
|
39
|
-
branch: gh-pages
|
|
40
|
-
folder: docs-html
|
|
41
|
-
clean: true
|
package/Envelopes/Envelopes.d.ts
DELETED
|
@@ -1,242 +0,0 @@
|
|
|
1
|
-
import { IEnvelope, IEnvelopesSummary, IRecipient, IEnvelopeDocument, IEnvelopeFieldSettings } from './Types';
|
|
2
|
-
import { ICreateEnvelopeRole, IEnvelopesSearchResult, ISigningSessionRequest } from './Types';
|
|
3
|
-
import { TEnvelopeUpdateResult, TEnvelopeStatus, TRecipientStatus } from './Types';
|
|
4
|
-
import { VerdocsEndpoint } from '../VerdocsEndpoint';
|
|
5
|
-
import { ISigningSession } from '../Sessions/Types';
|
|
6
|
-
export interface ICreateEnvelopeRequest {
|
|
7
|
-
template_id: string;
|
|
8
|
-
roles: ICreateEnvelopeRole[];
|
|
9
|
-
name: string;
|
|
10
|
-
environment?: string;
|
|
11
|
-
prepared_fields?: {
|
|
12
|
-
name: string;
|
|
13
|
-
value: string;
|
|
14
|
-
}[];
|
|
15
|
-
}
|
|
16
|
-
/**
|
|
17
|
-
* Create an envelope
|
|
18
|
-
*
|
|
19
|
-
* ```typescript
|
|
20
|
-
* import {Envelopes, ICreateEnvelopeRole, ICreateEnvelopeRequest} from '@verdocs/js-sdk/Envelopes';
|
|
21
|
-
*
|
|
22
|
-
* const role1: ICreateEnvelopeRole = {
|
|
23
|
-
* type: 'signer',
|
|
24
|
-
* name: 'Seller',
|
|
25
|
-
* full_name: 'Paige Turner',
|
|
26
|
-
* email: 'paige.turner@nomail.com',
|
|
27
|
-
* phone: '',
|
|
28
|
-
* sequence: 1,
|
|
29
|
-
* delegator: false,
|
|
30
|
-
* message: '',
|
|
31
|
-
* };
|
|
32
|
-
*
|
|
33
|
-
* const role2: ICreateEnvelopeRole = {
|
|
34
|
-
* type: 'signer',
|
|
35
|
-
* name: 'Buyer',
|
|
36
|
-
* full_name: 'Will Power',
|
|
37
|
-
* email: 'will.power@nomail.com',
|
|
38
|
-
* phone: '',
|
|
39
|
-
* sequence: 2,
|
|
40
|
-
* delegator: false,
|
|
41
|
-
* message: '',
|
|
42
|
-
* };
|
|
43
|
-
*
|
|
44
|
-
* const request: ICreateEnvelopeRequest = {template_id: 'd2338742-f3a1-465b-8592-806587413cc1', name: 'Bill of Sale', roles: [role1, role2]};
|
|
45
|
-
* const {id, recipients} = await Envelopes.createEnvelope(VerdocsEndpoint.getDefault(), request);
|
|
46
|
-
* ```
|
|
47
|
-
*/
|
|
48
|
-
export declare const createEnvelope: (endpoint: VerdocsEndpoint, request: ICreateEnvelopeRequest) => Promise<IEnvelope>;
|
|
49
|
-
/**
|
|
50
|
-
* Get a summary of currently active envelopes.
|
|
51
|
-
*
|
|
52
|
-
* ```typescript
|
|
53
|
-
* import {Envelopes} from '@verdocs/js-sdk/Envelopes';
|
|
54
|
-
*
|
|
55
|
-
* const {action_required, completed, waiting_on_others} = await Envelopes.getSummary(VerdocsEndpoint.getDefault());
|
|
56
|
-
* ```
|
|
57
|
-
*/
|
|
58
|
-
export declare const getSummary: (endpoint: VerdocsEndpoint, page: number) => Promise<IEnvelopesSummary>;
|
|
59
|
-
export interface IEnvelopeSearchParams {
|
|
60
|
-
/** The envelope must have been created via the specified template ID. */
|
|
61
|
-
template_id?: string;
|
|
62
|
-
/** The envelope must match one of the specified statuses. */
|
|
63
|
-
envelope_status?: TEnvelopeStatus[];
|
|
64
|
-
/** At least one of the recipients must match one of the specified statuses. */
|
|
65
|
-
recipient_status?: TRecipientStatus[];
|
|
66
|
-
/** The envelope's name (inherited from the template) must match the specified string. */
|
|
67
|
-
envelope_name?: string;
|
|
68
|
-
/** At least one of the envelope's recipients must match the specified name. */
|
|
69
|
-
recipient_name?: string;
|
|
70
|
-
/** At least one of the envelope's recipients must match the specified email address. */
|
|
71
|
-
recipient_email?: string;
|
|
72
|
-
/** Match against envelope_name, recipient_name, or recipient_email all at once. */
|
|
73
|
-
name?: string;
|
|
74
|
-
/** At least one of the envelope's recipients must match the specified ID. */
|
|
75
|
-
recipient_id?: string;
|
|
76
|
-
/** The date-range in which the envelope was created. Values should be specified in ISO8601 "UTC" format. */
|
|
77
|
-
created_at?: {
|
|
78
|
-
start_time: string;
|
|
79
|
-
end_time: string;
|
|
80
|
-
};
|
|
81
|
-
/**
|
|
82
|
-
* The date-range in which the envelope was last updated. Values should be specified in ISO8601 "UTC" format.
|
|
83
|
-
* Note that any operations that alter the envelope are considered "updates", including status changes (cancellation),
|
|
84
|
-
* recipient actions (opening/signing), etc.
|
|
85
|
-
*/
|
|
86
|
-
updated_at?: {
|
|
87
|
-
start_time: string;
|
|
88
|
-
end_time: string;
|
|
89
|
-
};
|
|
90
|
-
/** The date-range in which the envelope was canceled. Values should be specified in ISO8601 "UTC" format. */
|
|
91
|
-
canceled_at?: {
|
|
92
|
-
start_time: string;
|
|
93
|
-
end_time: string;
|
|
94
|
-
};
|
|
95
|
-
/** Perform a "contains" search where any of the attached documents' fields contains the specified value. */
|
|
96
|
-
text_field_value?: string;
|
|
97
|
-
/** Set to true to retrieve only summary records (IEnvelopeSummary). */
|
|
98
|
-
summary?: boolean;
|
|
99
|
-
/** Set to true to retrieve only those envelopes owned by the caller. */
|
|
100
|
-
is_owner?: boolean;
|
|
101
|
-
/** Set to true to retrieve only those envelopes in which the caller is one of the recipients. */
|
|
102
|
-
is_recipient?: boolean;
|
|
103
|
-
/** Whether the recipient has "claimed" the envelope. */
|
|
104
|
-
recipient_claimed?: boolean;
|
|
105
|
-
/** @deprecated. Use `limit`. */
|
|
106
|
-
row?: number;
|
|
107
|
-
/** The maximum number of records to return. Should be used in place of `row`. */
|
|
108
|
-
limit?: number;
|
|
109
|
-
/** The page number to return. Page numbers are 0-based. */
|
|
110
|
-
page?: number;
|
|
111
|
-
/** The field to sort the results by. */
|
|
112
|
-
sort_by?: 'created_at' | 'updated_at' | 'envelope_name' | 'canceled_at' | 'envelope_status';
|
|
113
|
-
/** Whether to sort in ascending (default) or descending order. */
|
|
114
|
-
ascending?: boolean;
|
|
115
|
-
}
|
|
116
|
-
/**
|
|
117
|
-
* Search for envelopes matching various criteria.
|
|
118
|
-
*
|
|
119
|
-
* ```typescript
|
|
120
|
-
* import {Envelopes} from '@verdocs/js-sdk/Envelopes';
|
|
121
|
-
*
|
|
122
|
-
* const {result, page, total} = await Envelopes.search(VerdocsEndpoint.getDefault(), { ... });
|
|
123
|
-
* ```
|
|
124
|
-
*/
|
|
125
|
-
export declare const searchEnvelopes: (endpoint: VerdocsEndpoint, params: IEnvelopeSearchParams) => Promise<IEnvelopesSearchResult>;
|
|
126
|
-
export interface ISigningSessionResult {
|
|
127
|
-
recipient: IRecipient;
|
|
128
|
-
session: ISigningSession;
|
|
129
|
-
signerToken: string;
|
|
130
|
-
}
|
|
131
|
-
/**
|
|
132
|
-
* Get a signing session for an Envelope.
|
|
133
|
-
*/
|
|
134
|
-
export declare const getSigningSession: (endpoint: VerdocsEndpoint, params: ISigningSessionRequest) => Promise<ISigningSessionResult>;
|
|
135
|
-
/**
|
|
136
|
-
* Get the list of recipients for an Envelope.
|
|
137
|
-
*/
|
|
138
|
-
export declare const getEnvelopeRecipients: (endpoint: VerdocsEndpoint, envelopeId: string) => Promise<IRecipient[]>;
|
|
139
|
-
/**
|
|
140
|
-
* Get all metadata for an Envelope.
|
|
141
|
-
*/
|
|
142
|
-
export declare const getEnvelope: (endpoint: VerdocsEndpoint, envelopeId: string) => Promise<IEnvelope>;
|
|
143
|
-
/**
|
|
144
|
-
* Get an Envelope Document
|
|
145
|
-
*/
|
|
146
|
-
export declare const getEnvelopeDocument: (endpoint: VerdocsEndpoint, envelopeId: string, documentId: string) => Promise<IEnvelopeDocument>;
|
|
147
|
-
/**
|
|
148
|
-
* Get a pre-signed download link for an Envelope Document. This link expires quickly, so it should
|
|
149
|
-
* be accessed immediately and never shared. Content-Disposition will be set to "download".
|
|
150
|
-
*/
|
|
151
|
-
export declare const getDocumentDownloadLink: (endpoint: VerdocsEndpoint, envelopeId: string, documentId: string) => Promise<string>;
|
|
152
|
-
/**
|
|
153
|
-
* Get a pre-signed preview link for an Envelope Document. This link expires quickly, so it should
|
|
154
|
-
* be accessed immediately and never shared. Content-Disposition will be set to "inline".
|
|
155
|
-
*/
|
|
156
|
-
export declare const getDocumentPreviewLink: (endpoint: VerdocsEndpoint, envelopeId: string, documentId: string) => Promise<string>;
|
|
157
|
-
/**
|
|
158
|
-
* Cancel an Envelope.
|
|
159
|
-
*/
|
|
160
|
-
export declare const cancelEnvelope: (endpoint: VerdocsEndpoint, envelopeId: string) => Promise<TEnvelopeUpdateResult>;
|
|
161
|
-
/**
|
|
162
|
-
* Get (binary download) a file attached to an Envelope. It is important to use this method
|
|
163
|
-
* rather than a direct A HREF or similar link to set the authorization headers for the
|
|
164
|
-
* request.
|
|
165
|
-
*/
|
|
166
|
-
export declare const getEnvelopeFile: (endpoint: VerdocsEndpoint, envelopeId: string, documentId: string) => Promise<any>;
|
|
167
|
-
/**
|
|
168
|
-
* Update a Document field. Typically called during the signing process as a Recipient fills in fields.
|
|
169
|
-
*/
|
|
170
|
-
export declare const updateEnvelopeField: (endpoint: VerdocsEndpoint, envelopeId: string, fieldName: string, value: any) => Promise<IEnvelopeFieldSettings>;
|
|
171
|
-
/**
|
|
172
|
-
* Update a Document signature field. Signature fields are ID-driven. Call `Document.createSignature()` first to create a
|
|
173
|
-
* signature for a Recipient, then call `Documents.updateDocumentFieldSignature()` to attach it to a field.
|
|
174
|
-
*/
|
|
175
|
-
export declare const updateEnvelopeFieldSignature: (endpoint: VerdocsEndpoint, envelopeId: string, fieldName: string, signatureId: string) => Promise<IEnvelopeFieldSettings>;
|
|
176
|
-
/**
|
|
177
|
-
* Update a Document signature field. Signature fields are ID-driven. Call `Document.createSignature()` first to create a
|
|
178
|
-
* signature for a Recipient, then call `Documents.updateDocumentFieldSignature()` to attach it to a field.
|
|
179
|
-
*/
|
|
180
|
-
export declare const updateEnvelopeFieldInitials: (endpoint: VerdocsEndpoint, envelopeId: string, fieldName: string, initialId: string) => Promise<IEnvelopeFieldSettings>;
|
|
181
|
-
/**
|
|
182
|
-
* Upload an attachment.
|
|
183
|
-
*/
|
|
184
|
-
export declare const uploadEnvelopeFieldAttachment: (endpoint: VerdocsEndpoint, envelopeId: string, fieldName: string, file: File, onUploadProgress?: ((percent: number, loadedBytes: number, totalBytes: number) => void) | undefined) => Promise<IEnvelopeFieldSettings>;
|
|
185
|
-
/**
|
|
186
|
-
* Delete an attachment.
|
|
187
|
-
*/
|
|
188
|
-
export declare const deleteEnvelopeFieldAttachment: (endpoint: VerdocsEndpoint, envelopeId: string, fieldName: string, file: File, onUploadProgress?: ((percent: number, loadedBytes: number, totalBytes: number) => void) | undefined) => Promise<IEnvelopeFieldSettings>;
|
|
189
|
-
/**
|
|
190
|
-
* Get the attached file for an attachment field (if any)
|
|
191
|
-
*/
|
|
192
|
-
export declare const getFieldAttachment: (endpoint: VerdocsEndpoint, envelopeId: string, fieldName: string) => Promise<any>;
|
|
193
|
-
/**
|
|
194
|
-
* Get all of the envelopes that were sent using a given template.
|
|
195
|
-
* NOTE: This endpoint will be retired soon. Its response is not paginated and it is typically used only to retrieve
|
|
196
|
-
* "submitted data" for a template. A new endpoint will be introduced to provide this function more directly.
|
|
197
|
-
* @deprecated
|
|
198
|
-
*/
|
|
199
|
-
export declare const getEnvelopesByTemplateId: (endpoint: VerdocsEndpoint, templateId: string) => Promise<IEnvelope[]>;
|
|
200
|
-
/**
|
|
201
|
-
* Get a display URI for a given page in a file attached to an envelope document. These pages are rendered server-side
|
|
202
|
-
* into PNG resources suitable for display in IMG tags although they may be used elsewhere. Note that these are intended
|
|
203
|
-
* for DISPLAY ONLY, are not legally binding documents, and do not contain any encoded metadata from participants.
|
|
204
|
-
*/
|
|
205
|
-
export declare const getEnvelopeDocumentPageDisplayUri: (endpoint: VerdocsEndpoint, envelopeId: string, documentId: string, page: number, type?: 'original' | 'filled' | 'certificate') => Promise<string>;
|
|
206
|
-
/**
|
|
207
|
-
* Wrapper for `getEnvelope()` that limits queries to one every 2 seconds per template ID.
|
|
208
|
-
* This is intended for use in component hierarchies that all rely on the same template
|
|
209
|
-
* to avoid unnecessary repeat server calls.
|
|
210
|
-
*/
|
|
211
|
-
export declare const throttledGetEnvelope: (endpoint: VerdocsEndpoint, envelopeId: string) => IEnvelope | Promise<IEnvelope>;
|
|
212
|
-
export interface ITimeRange {
|
|
213
|
-
start: string;
|
|
214
|
-
end: string;
|
|
215
|
-
}
|
|
216
|
-
export interface IListEnvelopesParams {
|
|
217
|
-
view?: 'inbox' | 'sent' | 'action' | 'waiting' | 'completed';
|
|
218
|
-
q?: string;
|
|
219
|
-
status?: string[];
|
|
220
|
-
created_at?: ITimeRange;
|
|
221
|
-
is_owner?: boolean;
|
|
222
|
-
sort_by?: 'name' | 'created_at' | 'updated_at' | 'canceled_at' | 'status';
|
|
223
|
-
template_id?: string;
|
|
224
|
-
ascending?: boolean;
|
|
225
|
-
rows?: number;
|
|
226
|
-
page?: number;
|
|
227
|
-
}
|
|
228
|
-
/**a
|
|
229
|
-
* Lists all envelopes accessible by the caller, with optional filters.
|
|
230
|
-
*
|
|
231
|
-
* ```typescript
|
|
232
|
-
* import {Envelopes} from '@verdocs/js-sdk/Envelopes';
|
|
233
|
-
*
|
|
234
|
-
* const {totals, envelopes} = await Envelopes.listEnvelopes((VerdocsEndpoint.getDefault(), { q: 'test', sort: 'created_at' });
|
|
235
|
-
* ```
|
|
236
|
-
*/
|
|
237
|
-
export declare const listEnvelopes: (endpoint: VerdocsEndpoint, params?: IListEnvelopesParams) => Promise<{
|
|
238
|
-
total: number;
|
|
239
|
-
rows: number;
|
|
240
|
-
page: number;
|
|
241
|
-
envelopes: IEnvelope[];
|
|
242
|
-
}>;
|