Current section

Files

Jump to
docusign lib docusign api template_document_html_definitions.ex
Raw

lib/docusign/api/template_document_html_definitions.ex

# NOTE: This file is auto generated by OpenAPI Generator 6.4.0 (https://openapi-generator.tech).
# Do not edit this file manually.
defmodule DocuSign.Api.TemplateDocumentHtmlDefinitions do
@moduledoc """
API calls for all endpoints tagged `TemplateDocumentHtmlDefinitions`.
"""
alias DocuSign.Connection
import DocuSign.RequestBuilder
@doc """
Gets the Original HTML Definition used to generate the Responsive HTML for a given document in a template.
### Parameters
- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `document_id` (String.t): The unique ID of the document within the envelope. Unlike other IDs in the eSignature API, you specify the `documentId` yourself. Typically the first document has the ID `1`, the second document `2`, and so on, but you can use any numbering scheme that fits within a 32-bit signed integer (1 through 2147483647). Tab objects have a `documentId` property that specifies the document on which to place the tab.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters
### Returns
- `{:ok, DocuSign.Model.DocumentHtmlDefinitionOriginals.t}` on success
- `{:error, Tesla.Env.t}` on failure
"""
@spec responsive_html_get_template_document_html_definitions(
Tesla.Env.client(),
String.t(),
String.t(),
String.t(),
keyword()
) ::
{:ok, DocuSign.Model.DocumentHtmlDefinitionOriginals.t()}
| {:ok, DocuSign.Model.ErrorDetails.t()}
| {:error, Tesla.Env.t()}
def responsive_html_get_template_document_html_definitions(
connection,
account_id,
document_id,
template_id,
_opts \\ []
) do
request =
%{}
|> method(:get)
|> url(
"/v2.1/accounts/#{account_id}/templates/#{template_id}/documents/#{document_id}/html_definitions"
)
|> Enum.into([])
connection
|> Connection.request(request)
|> evaluate_response([
{200, %DocuSign.Model.DocumentHtmlDefinitionOriginals{}},
{400, %DocuSign.Model.ErrorDetails{}}
])
end
end