I'm building a DocuSign integration using the v2.1 REST API. I create an envelope with multiple recipients and documents, and then open the embedded sender view using:
POST https://demo.docusign.net/restapi/v2.1/accounts/{accountId}/envelopes/{envelopeId}/views/sender
{
"returnUrl": "https://myapp/return",
"viewAccess": "envelope",
"status": "sent"
}
My goal: let the sender adjust Document Visibility settings before sending the envelope in the preview screen—uncheck/check visibility for a recipient.
Go to: Prepare → Advanced Options → enable "Recipients must be signers to view signed documents" → click Next.
Under Documents → Document Visibility, uncheck a recipient for a document and hit Done.
Error appears: "Document visibility changes could not be saved. Please try again"
Then, if I try Send, I get: "The access token provided is expired, revoked or malformed"
However, if I remove the "viewAccess": "envelope" field from my sender view request, visibility changes save correctly.
Is there a workaround to allow full sender view functionality and document visibility changes without stripping out viewAccess?