Update a signature
const url = 'https://mail.work.optidata.cloud/api/mail/signatures/39922fe6-7060-4932-bc32-eaf484adfd7a';const form = new FormData();form.append('signature', '{ "content": "example", "name": "example" }');form.append('attachments', '[ { "file": "binary", "url": "example", "disposition": "inline", "type": "example" } ]');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://mail.work.optidata.cloud/api/mail/signatures/39922fe6-7060-4932-bc32-eaf484adfd7a \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: multipart/form-data' \ --form 'signature={ "content": "example", "name": "example" }' \ --form 'attachments=[ { "file": "binary", "url": "example", "disposition": "inline", "type": "example" } ]'Replace the content of an existing signature, addressed by its hash. The
body is the same as on creation.
Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”The signature’s hash.
Request Bodyrequired
Section titled “Request Bodyrequired”object
object
HTML content of the signature.
Images embedded in the signature, at up to 10 MB each.
object
The placeholder URL used inside signature.content.
object
object
HTML content of the signature.
Images embedded in the signature, at up to 10 MB each.
object
The placeholder URL used inside signature.content.
Examples
{ "signature": { "name": "Work", "content": "<div>Jane Doe — Head of Finance, Acme</div>" }}Responses
Section titled “ Responses ”The updated signature.
A signature block appended to outgoing mail.
object
Stable identifier, used to address the signature.
HTML content.
Example
{ "hash": "39922fe6-7060-4932-bc32-eaf484adfd7a"}Missing, malformed or expired authentication key.
Authentication failures use an error key rather than message.
object
Examples
No bearer token sent
{ "error": "JWT passport exception: Missing bearer token in request"}The request tried to read or write the signatures of another user, which only an administrator may do.
Generic error envelope used by policy, binding and framework failures.
object
Human-readable description of the failure.
Examples
{ "message": "Only administrators can manage signatures for other users."}No such resource, or it does not belong to the caller.
Generic error envelope used by policy, binding and framework failures.
object
Human-readable description of the failure.
Examples
{ "message": "No query results for model."}The request body or query string failed validation.
object
The first validation message.
Validation messages keyed by field name.
object
Examples
{ "message": "The conversations field is required.", "errors": { "conversation_ids": [ "The conversations field is required." ] }}Rate limit exceeded. Retry after the window resets.
Generic error envelope used by policy, binding and framework failures.
object
Human-readable description of the failure.
Examples
{ "message": "Too Many Attempts."}