@verdocs/js-sdk 6.2.0-beta.8 → 6.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
@@ -1732,7 +1732,7 @@ declare const updateEnvelope: (endpoint: VerdocsEndpoint, envelopeId: string, pa
1732
1732
  * @apiBody value . Value to set.
1733
1733
  * @apiSuccess IEnvelopeField . A copy of the newly-updated field.
1734
1734
  */
1735
- declare const updateEnvelopeField: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string, fieldName: string, value: any) => Promise<IEnvelopeField>;
1735
+ declare const updateEnvelopeField: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string, fieldName: string, value: string, prepared: boolean) => Promise<IEnvelopeField>;
1736
1736
  /**
1737
1737
  * Upload an attachment to an attachment field.
1738
1738
  */
package/dist/index.d.ts CHANGED
@@ -1732,7 +1732,7 @@ declare const updateEnvelope: (endpoint: VerdocsEndpoint, envelopeId: string, pa
1732
1732
  * @apiBody value . Value to set.
1733
1733
  * @apiSuccess IEnvelopeField . A copy of the newly-updated field.
1734
1734
  */
1735
- declare const updateEnvelopeField: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string, fieldName: string, value: any) => Promise<IEnvelopeField>;
1735
+ declare const updateEnvelopeField: (endpoint: VerdocsEndpoint, envelopeId: string, roleName: string, fieldName: string, value: string, prepared: boolean) => Promise<IEnvelopeField>;
1736
1736
  /**
1737
1737
  * Upload an attachment to an attachment field.
1738
1738
  */
package/dist/index.js CHANGED
@@ -1688,8 +1688,8 @@ const updateEnvelope = async (endpoint, envelopeId, params) => endpoint.api //
1688
1688
  * @apiBody value . Value to set.
1689
1689
  * @apiSuccess IEnvelopeField . A copy of the newly-updated field.
1690
1690
  */
1691
- const updateEnvelopeField = async (endpoint, envelopeId, roleName, fieldName, value) => endpoint.api //
1692
- .put(`/v2/envelopes/${envelopeId}/recipients/${roleName}/fields/${fieldName}`, { value })
1691
+ const updateEnvelopeField = async (endpoint, envelopeId, roleName, fieldName, value, prepared) => endpoint.api //
1692
+ .put(`/v2/envelopes/${envelopeId}/recipients/${roleName}/fields/${fieldName}`, { value, prepared })
1693
1693
  .then((r) => r.data);
1694
1694
  /**
1695
1695
  * Upload an attachment to an attachment field.
@@ -1697,6 +1697,7 @@ const updateEnvelopeField = async (endpoint, envelopeId, roleName, fieldName, va
1697
1697
  const uploadEnvelopeFieldAttachment = async (endpoint, envelopeId, roleName, fieldName, file, onUploadProgress) => {
1698
1698
  const formData = new FormData();
1699
1699
  formData.append('document', file, file.name);
1700
+ formData.append('value', '');
1700
1701
  return endpoint.api //
1701
1702
  .put(`/v2/envelopes/${envelopeId}/recipients/${roleName}/fields/${fieldName}`, formData, {
1702
1703
  timeout: 120000,
@@ -2705,7 +2706,7 @@ const envelopeRecipientDecline = (endpoint, envelopeId, roleName) => endpoint.ap
2705
2706
  * @apiSuccess IRecipient . The updated Recipient.
2706
2707
  */
2707
2708
  const envelopeRecipientSubmit = (endpoint, envelopeId, roleName) => endpoint.api //
2708
- .put(`/v2/envelopes/${envelopeId}/recipients/${roleName}/submit`)
2709
+ .post(`/v2/envelopes/${envelopeId}/recipients/${roleName}/submit`)
2709
2710
  .then((r) => r.data);
2710
2711
  /**
2711
2712
  * Begin a signing session for an Envelope. This path requires an invite code, and should generally
@@ -2796,7 +2797,7 @@ const verifySigner = (endpoint, params) => endpoint.api //
2796
2797
  * @apiSuccess string . Success message.
2797
2798
  */
2798
2799
  const delegateRecipient = (endpoint, envelopeId, roleName, params) => endpoint.api //
2799
- .put(`/v2/envelopes/${envelopeId}/recipients/${encodeURIComponent(roleName)}`, { action: 'delegate', ...params })
2800
+ .post(`/v2/envelopes/${envelopeId}/recipients/${encodeURIComponent(roleName)}/delegate`, params)
2800
2801
  .then((r) => r.data);
2801
2802
  /**
2802
2803
  * Update a recipient. NOTE: User interfaces should rate-limit this operation to avoid spamming recipients.