@verdocs/js-sdk 4.2.48 → 4.2.50
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 +16 -9
- package/dist/index.d.ts +16 -9
- package/dist/index.js +8 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +8 -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
|
@@ -613,7 +613,7 @@ interface IRecipient {
|
|
|
613
613
|
status: TRecipientStatus;
|
|
614
614
|
email: string;
|
|
615
615
|
phone: string | null;
|
|
616
|
-
full_name
|
|
616
|
+
full_name?: string | null;
|
|
617
617
|
first_name: string;
|
|
618
618
|
last_name: string;
|
|
619
619
|
address: string;
|
|
@@ -693,6 +693,8 @@ interface IRole {
|
|
|
693
693
|
name: string;
|
|
694
694
|
type: TRecipientType;
|
|
695
695
|
full_name: string | null;
|
|
696
|
+
first_name: string | null;
|
|
697
|
+
last_name: string | null;
|
|
696
698
|
email: string | null;
|
|
697
699
|
phone: string | null;
|
|
698
700
|
message: string | null;
|
|
@@ -1210,11 +1212,13 @@ interface IUpdateRecipientDeclineParams {
|
|
|
1210
1212
|
}
|
|
1211
1213
|
interface IUpdateRecipientClaimEnvelope {
|
|
1212
1214
|
action: "owner_update";
|
|
1213
|
-
|
|
1215
|
+
first_name: string;
|
|
1216
|
+
last_name: string;
|
|
1214
1217
|
email: string;
|
|
1215
1218
|
}
|
|
1216
1219
|
interface IUpdateRecipientStatus {
|
|
1217
|
-
|
|
1220
|
+
first_name?: string;
|
|
1221
|
+
last_name?: string;
|
|
1218
1222
|
agreed?: boolean;
|
|
1219
1223
|
action?: "prepare" | "update";
|
|
1220
1224
|
}
|
|
@@ -1224,7 +1228,8 @@ interface IUpdateRecipientAgreedParams {
|
|
|
1224
1228
|
}
|
|
1225
1229
|
interface IUpdateRecipientNameParams {
|
|
1226
1230
|
action: "update";
|
|
1227
|
-
|
|
1231
|
+
first_name: string;
|
|
1232
|
+
last_name: string;
|
|
1228
1233
|
}
|
|
1229
1234
|
interface IUpdateRecipientPrepareParams {
|
|
1230
1235
|
action: "prepare";
|
|
@@ -1263,7 +1268,8 @@ type TCreateEnvelopeRequest = ICreateEnvelopeFromTemplateRequest | ICreateEnvelo
|
|
|
1263
1268
|
* const role1: ICreateEnvelopeRole = {
|
|
1264
1269
|
* type: 'signer',
|
|
1265
1270
|
* name: 'Seller',
|
|
1266
|
-
*
|
|
1271
|
+
* first_name: 'Paige',
|
|
1272
|
+
* last_name: 'Turner',
|
|
1267
1273
|
* email: 'paige.turner@nomail.com',
|
|
1268
1274
|
* phone: '',
|
|
1269
1275
|
* sequence: 1,
|
|
@@ -1274,7 +1280,8 @@ type TCreateEnvelopeRequest = ICreateEnvelopeFromTemplateRequest | ICreateEnvelo
|
|
|
1274
1280
|
* const role2: ICreateEnvelopeRole = {
|
|
1275
1281
|
* type: 'signer',
|
|
1276
1282
|
* name: 'Buyer',
|
|
1277
|
-
*
|
|
1283
|
+
* first_name: 'Power',
|
|
1284
|
+
* last_name: 'Power',
|
|
1278
1285
|
* email: 'will.power@nomail.com',
|
|
1279
1286
|
* phone: '',
|
|
1280
1287
|
* sequence: 2,
|
|
@@ -1483,7 +1490,7 @@ declare const submitKbaChallengeResponse: (endpoint: VerdocsEndpoint, envelope_i
|
|
|
1483
1490
|
/**
|
|
1484
1491
|
* Update a recipient's status block
|
|
1485
1492
|
*/
|
|
1486
|
-
declare const updateRecipient: (endpoint: VerdocsEndpoint,
|
|
1493
|
+
declare const updateRecipient: (endpoint: VerdocsEndpoint, envelope_id: string, role_name: string, params: IUpdateRecipientSubmitParams | IUpdateRecipientClaimEnvelope | IUpdateRecipientAgreedParams | IUpdateRecipientNameParams | IUpdateRecipientDeclineParams | IUpdateRecipientPrepareParams) => Promise<IRecipient>;
|
|
1487
1494
|
/**
|
|
1488
1495
|
* Submit an envelope (signing is finished). Note that all fields must be valid/completed for this to succeed.
|
|
1489
1496
|
*/
|
|
@@ -1495,7 +1502,7 @@ declare const envelopeRecipientDecline: (endpoint: VerdocsEndpoint, envelopeId:
|
|
|
1495
1502
|
/**
|
|
1496
1503
|
* Claim / change ownership of an envelope. This is a special-case operation only available in certain workflows.
|
|
1497
1504
|
*/
|
|
1498
|
-
declare const envelopeRecipientChangeOwner: (endpoint: VerdocsEndpoint,
|
|
1505
|
+
declare const envelopeRecipientChangeOwner: (endpoint: VerdocsEndpoint, envelope_id: string, role_name: string, email: string, first_name: string, last_name: string) => Promise<IRecipient>;
|
|
1499
1506
|
/**
|
|
1500
1507
|
* Agree to electronic signing.
|
|
1501
1508
|
*/
|
|
@@ -1503,7 +1510,7 @@ declare const envelopeRecipientAgree: (endpoint: VerdocsEndpoint, envelopeId: st
|
|
|
1503
1510
|
/**
|
|
1504
1511
|
* Change a recipient's name.
|
|
1505
1512
|
*/
|
|
1506
|
-
declare const envelopeRecipientUpdateName: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string,
|
|
1513
|
+
declare const envelopeRecipientUpdateName: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string, first_name: string, last_name: string) => Promise<IRecipient>;
|
|
1507
1514
|
/**
|
|
1508
1515
|
* Change a recipient's name.
|
|
1509
1516
|
*/
|
package/dist/index.d.ts
CHANGED
|
@@ -613,7 +613,7 @@ interface IRecipient {
|
|
|
613
613
|
status: TRecipientStatus;
|
|
614
614
|
email: string;
|
|
615
615
|
phone: string | null;
|
|
616
|
-
full_name
|
|
616
|
+
full_name?: string | null;
|
|
617
617
|
first_name: string;
|
|
618
618
|
last_name: string;
|
|
619
619
|
address: string;
|
|
@@ -693,6 +693,8 @@ interface IRole {
|
|
|
693
693
|
name: string;
|
|
694
694
|
type: TRecipientType;
|
|
695
695
|
full_name: string | null;
|
|
696
|
+
first_name: string | null;
|
|
697
|
+
last_name: string | null;
|
|
696
698
|
email: string | null;
|
|
697
699
|
phone: string | null;
|
|
698
700
|
message: string | null;
|
|
@@ -1210,11 +1212,13 @@ interface IUpdateRecipientDeclineParams {
|
|
|
1210
1212
|
}
|
|
1211
1213
|
interface IUpdateRecipientClaimEnvelope {
|
|
1212
1214
|
action: "owner_update";
|
|
1213
|
-
|
|
1215
|
+
first_name: string;
|
|
1216
|
+
last_name: string;
|
|
1214
1217
|
email: string;
|
|
1215
1218
|
}
|
|
1216
1219
|
interface IUpdateRecipientStatus {
|
|
1217
|
-
|
|
1220
|
+
first_name?: string;
|
|
1221
|
+
last_name?: string;
|
|
1218
1222
|
agreed?: boolean;
|
|
1219
1223
|
action?: "prepare" | "update";
|
|
1220
1224
|
}
|
|
@@ -1224,7 +1228,8 @@ interface IUpdateRecipientAgreedParams {
|
|
|
1224
1228
|
}
|
|
1225
1229
|
interface IUpdateRecipientNameParams {
|
|
1226
1230
|
action: "update";
|
|
1227
|
-
|
|
1231
|
+
first_name: string;
|
|
1232
|
+
last_name: string;
|
|
1228
1233
|
}
|
|
1229
1234
|
interface IUpdateRecipientPrepareParams {
|
|
1230
1235
|
action: "prepare";
|
|
@@ -1263,7 +1268,8 @@ type TCreateEnvelopeRequest = ICreateEnvelopeFromTemplateRequest | ICreateEnvelo
|
|
|
1263
1268
|
* const role1: ICreateEnvelopeRole = {
|
|
1264
1269
|
* type: 'signer',
|
|
1265
1270
|
* name: 'Seller',
|
|
1266
|
-
*
|
|
1271
|
+
* first_name: 'Paige',
|
|
1272
|
+
* last_name: 'Turner',
|
|
1267
1273
|
* email: 'paige.turner@nomail.com',
|
|
1268
1274
|
* phone: '',
|
|
1269
1275
|
* sequence: 1,
|
|
@@ -1274,7 +1280,8 @@ type TCreateEnvelopeRequest = ICreateEnvelopeFromTemplateRequest | ICreateEnvelo
|
|
|
1274
1280
|
* const role2: ICreateEnvelopeRole = {
|
|
1275
1281
|
* type: 'signer',
|
|
1276
1282
|
* name: 'Buyer',
|
|
1277
|
-
*
|
|
1283
|
+
* first_name: 'Power',
|
|
1284
|
+
* last_name: 'Power',
|
|
1278
1285
|
* email: 'will.power@nomail.com',
|
|
1279
1286
|
* phone: '',
|
|
1280
1287
|
* sequence: 2,
|
|
@@ -1483,7 +1490,7 @@ declare const submitKbaChallengeResponse: (endpoint: VerdocsEndpoint, envelope_i
|
|
|
1483
1490
|
/**
|
|
1484
1491
|
* Update a recipient's status block
|
|
1485
1492
|
*/
|
|
1486
|
-
declare const updateRecipient: (endpoint: VerdocsEndpoint,
|
|
1493
|
+
declare const updateRecipient: (endpoint: VerdocsEndpoint, envelope_id: string, role_name: string, params: IUpdateRecipientSubmitParams | IUpdateRecipientClaimEnvelope | IUpdateRecipientAgreedParams | IUpdateRecipientNameParams | IUpdateRecipientDeclineParams | IUpdateRecipientPrepareParams) => Promise<IRecipient>;
|
|
1487
1494
|
/**
|
|
1488
1495
|
* Submit an envelope (signing is finished). Note that all fields must be valid/completed for this to succeed.
|
|
1489
1496
|
*/
|
|
@@ -1495,7 +1502,7 @@ declare const envelopeRecipientDecline: (endpoint: VerdocsEndpoint, envelopeId:
|
|
|
1495
1502
|
/**
|
|
1496
1503
|
* Claim / change ownership of an envelope. This is a special-case operation only available in certain workflows.
|
|
1497
1504
|
*/
|
|
1498
|
-
declare const envelopeRecipientChangeOwner: (endpoint: VerdocsEndpoint,
|
|
1505
|
+
declare const envelopeRecipientChangeOwner: (endpoint: VerdocsEndpoint, envelope_id: string, role_name: string, email: string, first_name: string, last_name: string) => Promise<IRecipient>;
|
|
1499
1506
|
/**
|
|
1500
1507
|
* Agree to electronic signing.
|
|
1501
1508
|
*/
|
|
@@ -1503,7 +1510,7 @@ declare const envelopeRecipientAgree: (endpoint: VerdocsEndpoint, envelopeId: st
|
|
|
1503
1510
|
/**
|
|
1504
1511
|
* Change a recipient's name.
|
|
1505
1512
|
*/
|
|
1506
|
-
declare const envelopeRecipientUpdateName: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string,
|
|
1513
|
+
declare const envelopeRecipientUpdateName: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string, first_name: string, last_name: string) => Promise<IRecipient>;
|
|
1507
1514
|
/**
|
|
1508
1515
|
* Change a recipient's name.
|
|
1509
1516
|
*/
|
package/dist/index.js
CHANGED
|
@@ -1365,7 +1365,8 @@ class VerdocsEndpoint {
|
|
|
1365
1365
|
* const role1: ICreateEnvelopeRole = {
|
|
1366
1366
|
* type: 'signer',
|
|
1367
1367
|
* name: 'Seller',
|
|
1368
|
-
*
|
|
1368
|
+
* first_name: 'Paige',
|
|
1369
|
+
* last_name: 'Turner',
|
|
1369
1370
|
* email: 'paige.turner@nomail.com',
|
|
1370
1371
|
* phone: '',
|
|
1371
1372
|
* sequence: 1,
|
|
@@ -1376,7 +1377,8 @@ class VerdocsEndpoint {
|
|
|
1376
1377
|
* const role2: ICreateEnvelopeRole = {
|
|
1377
1378
|
* type: 'signer',
|
|
1378
1379
|
* name: 'Buyer',
|
|
1379
|
-
*
|
|
1380
|
+
* first_name: 'Power',
|
|
1381
|
+
* last_name: 'Power',
|
|
1380
1382
|
* email: 'will.power@nomail.com',
|
|
1381
1383
|
* phone: '',
|
|
1382
1384
|
* sequence: 2,
|
|
@@ -1559,8 +1561,8 @@ const submitKbaChallengeResponse = (endpoint, envelope_id, role_name, response)
|
|
|
1559
1561
|
/**
|
|
1560
1562
|
* Update a recipient's status block
|
|
1561
1563
|
*/
|
|
1562
|
-
const updateRecipient = async (endpoint,
|
|
1563
|
-
.put(`/envelopes/${
|
|
1564
|
+
const updateRecipient = async (endpoint, envelope_id, role_name, params) => endpoint.api //
|
|
1565
|
+
.put(`/envelopes/${envelope_id}/recipients/${role_name}`, params)
|
|
1564
1566
|
.then((r) => r.data);
|
|
1565
1567
|
/**
|
|
1566
1568
|
* Submit an envelope (signing is finished). Note that all fields must be valid/completed for this to succeed.
|
|
@@ -1573,7 +1575,7 @@ const envelopeRecipientDecline = (endpoint, envelopeId, roleName) => updateRecip
|
|
|
1573
1575
|
/**
|
|
1574
1576
|
* Claim / change ownership of an envelope. This is a special-case operation only available in certain workflows.
|
|
1575
1577
|
*/
|
|
1576
|
-
const envelopeRecipientChangeOwner = (endpoint,
|
|
1578
|
+
const envelopeRecipientChangeOwner = (endpoint, envelope_id, role_name, email, first_name, last_name) => updateRecipient(endpoint, envelope_id, role_name, { action: 'owner_update', email, first_name, last_name });
|
|
1577
1579
|
/**
|
|
1578
1580
|
* Agree to electronic signing.
|
|
1579
1581
|
*/
|
|
@@ -1581,7 +1583,7 @@ const envelopeRecipientAgree = (endpoint, envelopeId, roleName, agreed) => updat
|
|
|
1581
1583
|
/**
|
|
1582
1584
|
* Change a recipient's name.
|
|
1583
1585
|
*/
|
|
1584
|
-
const envelopeRecipientUpdateName = (endpoint, envelopeId, roleName,
|
|
1586
|
+
const envelopeRecipientUpdateName = (endpoint, envelopeId, roleName, first_name, last_name) => updateRecipient(endpoint, envelopeId, roleName, { action: 'update', first_name, last_name });
|
|
1585
1587
|
/**
|
|
1586
1588
|
* Change a recipient's name.
|
|
1587
1589
|
*/
|