Allows you to create a new event in a specified calendar. Below is a detailed description of the request payload and the required/optional fields.

  • HTTP Method: POST
  • Endpoint: /rest-api/1/event-calendar/events

Fields description:

FieldTypeRequiredDescription
calendarstringYesThe unique identifier (UUID) of the calendar where the event will be created.
namestringYesThe title of the event.
descriptionstringNoA detailed description of the event, up to 1000 characters.
urlstringNoA URL related to the event (e.g., a meeting link), up to 500 characters.
colorstringNoThe 7-char hex color code (e.g., "#FF5733") for the event.
starting_datestringYesThe starting date of the event in ISO 8601 format (YYYY-MM-DD).
ending_datestringYesThe ending date of the event in ISO 8601 format (YYYY-MM-DD).
starting_timestringNoThe starting time of the event in HH:mm format. If provided, ending_time is required.
ending_timestringNoThe ending time of the event in HH:mm format. If provided, starting_time is required.
event_typestringYesThe event type, which must match a value from the event types endpoint.

Request example:

fetch("https://<site-url>/rest-api/1/event-calendar/events", {
method: "POST",
headers: {
"X-AldevaDigital-Rest-Token": "your-access-token",
"Content-Type": "application/json",
},
body: JSON.stringify({
calendar: "123e4567-e89b-12d3-a456-426614174000",
name: "Sprint Planning Meeting",
description: "Planning the next sprint goals and tasks.",
url: "https://meeting-link.com",
color: "#FF5733",
starting_date: "2025-01-15",
ending_date: "2025-01-15",
starting_time: "10:00",
event_type: 1,
ending_time: "11:00",
}),
});

Response example:

{
"status": true,
"id": "987e6543-b21b-65d4-c789-426614170999"
}