const url = DISCOURSE_BASE_URL + '/posts.json';
const message = {
method: 'POST',
headers: {
'Api-Key': DISCOURSE_API_KEY,
'Api-Username': DISCOURSE_API_USERNAME,
'Content-Type': 'application/json'
},
body: JSON.stringify({
"title": title,
"raw": content,
"category": categoryId
})
};
const response1 = await fetch(url, message);
I get “Unprocessable Entity” when raw as follow:
[event start="2024-05-16 19:00" status="public" name="585" timezone="Europe/Paris" allowedGroups="trust_level_0" end="2024-05-16 21:00"]
[/event]
When i get off event declaration and put alternative description, my forum gets updated but as soon as i put event declaration, i get Unprocessable Entity.
I don’t understand what i’m doing wrong.