Unable to create SMTP templates that allow use of drag&drop editor (with hacker's workaround)
Only simple and HTML editor are allowed, e.g. web app URLs https://app.brevo.com/editor/classic/html/XX and https://app.brevo.com/editor/classic/rich-text/XX.
When trying to edit template created in bulk via API using https://app.brevo.com/editor/newsletters/XX editor, editor crashes and this response is given GET https://editor-api.brevo.com/editor-api/newsletters/32?editorType=6:
{"message":"Campaign is not supporting editor type 6"}
How does one create template that is able to use drag&drop editor?
Templates created via web have this param:
"doiTemplate": true
Templates created via API have this:
"doiTemplate": false
However, using this param using PUT or POST set to true does not change anything and it is ignored.
For anyone bumping into this: this is not resolvable using API that Brevo offers.
Only way to create templates in bulk with support for the drag&drop (block) editor is to hijack requests the web app uses and run it via CURL, an example (you will have to really copy yours in full, do not use this example):
curl 'https://my.brevo.com/camp/save-campaign' --compressed -X POST -H 'User-Agent: XXXXXXXXX' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' -H 'Accept-Encoding: gzip, deflate, br, zstd' -H 'Referer: https://my.brevo.com/camp/template/setup' -H 'Content-Type: application/x-www-form-urlencoded' -H 'X-Requested-With: XMLHttpRequest' -H 'Origin: https://my.brevo.com' -H 'DNT: 1' -H 'Sec-GPC: 1' -H 'Connection: keep-alive' -H 'Cookie: tmpl_lang=en; country=US; first_referrer=https://account-app.brevo.com/; did=XXXXXXX; keen_anonymous_id=XXXXXX; anonymous_id=XXXXXXX; _plantrack=XXXXXXX; fs_uid=XXXXXXX; keen={%22uuid%22:XXXXXXXXinitialReferrer%22:%22https://app.brevo.com/%22}; cf_clearance=XXXXXXX; _zitok=XXXXXX; _reb2buid=XXXXXXXX; pscd=get.brevo.com; _gcl_au=XXXXXXXX; auth=XXXXXXXXX; loggedin=true; selected_app=campaigns; trk_usr_vld_trk=1; userTimeZone=XXXXXXX; contact_listpage_users=[3%2C1]; ACCOUNTSESSID=XXXXXX; exp=%7B%22SSC%22%3A%7B%22variant%22%3A%22V1%22%2C%22traffic%22%3A%22100%7C0%22%7D%7D; __ssid=XXXXXXXX; fs_lua=XXXXXXXX' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-origin' -H 'Priority: u=0' -H 'Pragma: no-cache' -H 'Cache-Control: no-cache' --data-raw 'camp_name=admin_voucher_sk&fromemail=XXXXXXXX&fromfield=XXXXXXXX&sender=1&warmup_enable=0&increase_rate=&initial_quota=&tofield=&attachmentfile=&form_name=Default+unsubscribe+page+-+XXXXXXXXXX&is_new_page=true&replyto=&header=&footer=&utm_campaign=&mirror_active=0&ga_active=1&utm_id_active=1&inline_images=0&category=&type=template&step=setup&id=&ab_testing=false&update_form=&preheader=&subject=XXXXX&token=XXXXXXX'
This successfully creates SMTP templates that support drag&drop / block editor.
Brevo, you should step up and offer this via your sad API.