Generate a template from a URL (coming soon)
POST
/api/v3/letters/templates/actions/generate-from-url
const url = 'https://api.tryletterhead.com/api/v3/letters/templates/actions/generate-from-url';const form = new FormData();form.append('api', 'true');form.append('url', 'https://example.com/newsletter-archive');
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://api.tryletterhead.com/api/v3/letters/templates/actions/generate-from-url \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: multipart/form-data' \ --form api=true \ --form url=https://example.com/newsletter-archiveAuthorizations
Section titled βAuthorizations βRequest Body required
Section titled βRequest Body required β Media type multipart/form-data
object
api
required
When set to true, this endpoint will accept authorization with your API Key.
string
Example
true url
string
Example
https://example.com/newsletter-archiveResponses
Section titled β Responses βSuccessful response
Still can’t find what you need? Contact support.