Im trying to create an email via REST API, based on an existing template. The only real documentation I can find is https://developer.salesforce.com/docs/atlas.en-us.noversion.mc-apis.meta/mc-apis/content.htm But it dosnt show how I use an existing template, only creating new HTML PASTE email.
Have anyone tried to do this, or have some examples of this?
EDIT: I have managed to get the correct template, but is dosnt put content in my slot called "contentarea2".
{
"assetType": {
"id": 207
},
"name": "Test_9",
"views": {
"subjectline": {
"content": "Hello"
},
"preheader": {
"content": "preheader text here"
},
"html": {
"template": {
"id": 86912,
"slots": {
"contentarea2": {
"content": "<div data-type=\"block\" data-key=\"block1\"></div>",
"design": "click here to start editing this block",
"blocks":{
"block1":{
"content":"123",
"design":"click here to start editing this block",
"assetType":{
"name":"freeformblock",
"id":195
}
}
}
}
}
}
},
"data": {
"email": {
"options": {
"characterEncoding": "utf-8"
}
}
}
}
}