The CancelEnvelope operation allows removal of an envelope from active status (including any documents contained in the envelope). When this operation is called, any documents contained in the envelope will no longer be available for signing.
Any documents contained in the envelope that were declined or completed prior to the CancelEnvelope operation being called will retain their status of declined or completed and will not be affected by the CancelEnvelope call.
The CancelEnvelope operation requires knowledge of the following:
- The EnvelopeId of the envelope to cancel (this is returned as an element in the returned XML from an envelope creation operation)
- The AuthToken of the envelope to cancel (this is returned as an element in the returned XML from n envelope creation operation)
- The AssureSign account ContextIdentifier (this is exposed in the AssureSign administrative application account settings and serves to provide some security to the transaction)
Additionally, an optional Remarks attribute (128 characters max) may be passed that will be included in the envelope status history record that will be created when this cancellation request is processed.
<?xml version="1.0" encoding="utf-8"?> <CancelEnvelope xmlns="https://www.assuresign.net/Services/DocumentNOW/Envelopes"> <CancelEnvelopeRequest ContextIdentifier="06C4A84A-693C-46CB-8DF2-40A8215AA056" EnvelopeId="2CE11EF1-8938-DD11-8735-00065B8CE99B" AuthToken="8CC9A84B-693C-46CC-4342-40A8215AD76A" Remarks="" /> </CancelEnvelope>
The SOAP Action Header is
A simple response is returned echoing the envelope information which will only contain an Exceptions node if some issue has occurred:
<?xml version="1.0" encoding="utf-8"?> <CancelEnvelopeResponse xmlns="https://www.assuresign.net/Services/DocumentNOW/Envelopes"> <CancelEnvelopeResult EnvelopeId="2CE11EF1-8938-DD11-8735-00065B8CE99B" /> </CancelEnvelopeResponse>
The CancelEnvelopeResult should be checked for the presence of an Exceptions element, which may contain multiple EnvelopeException items.