How about just create a topic or post for the event via the API and add the [event][/event] tags to the post as the value of its raw parameter?
The trick seems to be that there has to be a newline character (\n) between the opening and closing event tags.
I’m using "Content-Type: multipart/form-data" in the example below because it’s easier than dealing with JSON from the command line. Also $api_key is set to the value of an actual API Key:
curl -X POST "http://localhost:4200/posts.json" \
-H "Api-Key: $api_key" \
-H "Api-Username: scossar" \
-H "Content-Type: multipart/form-data" \
-F title="Can I create an event via the API?" \
-F category=6 \
-F raw='[event start="2024-05-10 20:00" status="public" timezone="America/Vancouver" end="2024-05-10 21:30" allowedGroups="trust_level_0"]\n[/event]'