POST
/
send
/
letter
Letter Preview
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"front_image_url":"https://s3.amazonaws.com/cdn.thanks.io/user_image_library/gFBaJJJWRp60op3ZOoK7UaO5I7zi33rdKQGgHylR.png","handwriting_style":5,"message":"This is a test message","mailing_lists":[5166,514],"return_name":"Custom Return","return_address":"123 Fake Street","return_address2":"Unit 1","return_city":"Anytown","return_state":"NY","return_postal_code":"10990","preview":true}'
};

fetch('https://api.thanks.io/api/v2/send/letter', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
{
  "success": true,
  "code": 200,
  "message": "OK",
  "data": {
    "previews": [
      "https://s3.amazonaws.com/content.thanks.io/sls-handwriting-engine/images/9e3212b0-fd22-18a6-fd14-630ffbc66ed8.png"
    ]
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Content-Type
string

Body

application/json · object

Response

200 - application/json

OK

The response is of type object.