Skip to navigation

Create template responsive HTML preview

View as Markdown

Creates a preview of the responsive, HTML versions of all of the documents associated with a template. This method enables you to preview the PDF document conversions to responsive HTML across device types prior to sending.

The request body is a documentHtmlDefinition object, which holds the responsive signing parameters that define how to generate the HTML version of the documents.

Authentication

AuthorizationBearer

OAuth 2.0 access token (JWT or auth-code grant). Sent as Authorization: Bearer <token> on every request except GET /v2.1 and GET /service_information, which are public discovery endpoints.

Path parameters

accountIdstringRequired

The external account number (int) or account ID Guid.

templateIdstringRequired
The ID of the template.

Request

This endpoint expects an object: documentHtmlDefinition

displayAnchorPrefixstringOptional
Contains text that all display anchors must start with. Using at least four characters will improve anchor processing performance.
displayAnchorslist of objectsOptional

An object that defines how to handle a section of the HTML in signing. This property enables an incoming request to make a section of the HTML collapsible and expandable or hidden from view.

A start anchor, end anchor, or both are required. If the anchors are not found, the display anchor will be ignored.

For a list of the available types, see the display property of the displaySettings object.

displayOrderstringOptional
The position on the page where the display section appears.
displayPageNumberstringOptional
The number of the page on which the display section appears.
documentGuidstringOptional
The GUID of the document.
documentIdstringOptional
Specifies the document ID number that the tab is placed on. This must refer to an existing Document's ID attribute.
headerLabelstringOptional
Header text or an HTML tag to place above the responsive HTML block.
maxScreenWidthstringOptional

If set, the responsive HTML version of the signing document will only display on screens with the specified pixel width or less. If the screen is larger than the value that you specify, the default PDF version of the content displays instead.

This setting can also be configured at the account level.

removeEmptyTagsstringOptional

Holds a comma-separated list of HTML tags to remove if they have no text within their node (including child nodes).

showMobileOptimizedTogglestringOptional

When true (the default), the Mobile-Friendly toggle displays at the top of the screen on the user’s mobile device. When false, the toggle will not be displayed.

the Mobile-Friendly toggle lets the user switch between the mobile-friendly and the PDF versions of a document. For example, the recipient can use this toggle to review the document using the PDF view before they finish signing.

sourcestringOptional

Specifies the type of responsive signing that will be used with the document.

If the value of this property is valid HTML, and the smart sections feature is enabled, the HTML code is used to display the signing page:

source: "<html> ... <body><p>hello world</p></body></html>"

If the value of this property is the string document, the HTML signing page is generated from the provided document.

source: "document"

Related topics

Response

Successful response.
htmlDefinitionslist of stringsOptional

Holds the properties that define how to generate the responsive-formatted HTML for the document.

Errors

400
Bad Request Error