Endpoint
POST https://example.com/wp-json/eventer/v1/create-update-event
Authentication
Use WordPress Application Passwords for authentication. Include the following header in your request:
Authorization: Basic base64_encode(username:application_password)
Request Parameters
1. Basic Event Fields
| Field | Type | Required | Description |
|---|---|---|---|
title |
String | Yes | The title of the event. |
description |
String | No | The detailed description of the event. |
event_start_dt |
String | Yes | The start date and time of the event in Y-m-d H:i format (e.g., 2025-07-01 10:00). |
event_end_dt |
String | Yes | The end date and time of the event in Y-m-d H:i format (e.g., 2025-07-01 22:00). |
status |
String | No | The status of the event. Default is publish. Options: publish, draft, pending. |
2. Time Slot Options
| Field | Type | Required | Description |
|---|---|---|---|
time_slots |
Array | No | Array of time slots for the event (see format below). |
time_slots_mandatory |
String | No | Set to on to make time slots mandatory during booking. Default is off. |
Time Slot Format (within time_slots array):
{
"title": "Opening Ceremony",
"start": "10:00",
"end": "11:00",
"desc": "Welcome speech and introduction."
}
3. Tickets
Regular Tickets (when WooCommerce ticketing is disabled)
| Field | Type | Required | Description |
|---|---|---|---|
tickets |
Array | No | Array of regular tickets (see format below). |
Ticket Format (within tickets array):
{
"name": "VIP Access",
"number": 50,
"price": 150.00,
"restrict": "1" // Restrict multiple registrations (0 or 1)
}
WooCommerce Tickets (when WooCommerce ticketing is enabled)
| Field | Type | Required | Description |
|---|---|---|---|
woocommerce_tickets |
Array | No | Array of WooCommerce tickets (see format below). |
disable_booking_before |
Int | No | Disable bookings this many days before the event (e.g., 2). |
common_ticket_count |
Int | No | Common ticket count for all WooCommerce tickets. |
common_tickets_management |
String | No | Set to yes to enable combined ticket count management. Default is no. |
WooCommerce Ticket Format (within woocommerce_tickets array):
{
"product_id": 1234,
"name": "VIP Access",
"number": 50,
"price": 150.00,
"enabled": "2025-06-30", // Activation date for the ticket
"action": "add" // Options: add, update, delete
}
4. Taxonomies
| Field | Type | Required | Description |
|---|---|---|---|
eventer-category |
Array | No | Array of category names to assign to the event (e.g., ["Music", "Festivals"]). |
eventer-tag |
Array | No | Array of tags to assign to the event (e.g., ["Outdoor", "Live"]). |
eventer-venue |
Array | No | Array of venue names for the event (e.g., ["Central Park"]). |
eventer-organizer |
Array | No | Array of organizer names (e.g., ["Event Co."]). |
5. Additional Fields
| Field | Type | Required | Description |
|---|---|---|---|
event_each_day_time |
String | No | Set to 1 to enable same time for each day of multi-day events. Default is 0. |
event_all_day |
String | No | Set to 1 for all-day events. Default is 0. |
event_featured |
String | No | Set to 1 to mark the event as featured. Default is 0. |
event_virtual |
String | No | Set to 1 for virtual events. Default is 0. |
event_specific_venue |
String | No | Specify a custom venue for the event. |
event_additional_info |
String | No | Add additional information to display with the event. |
event_frequency_type |
String | No | Recurrence type for the event. Options: no, 1 (Fixed Date), 2 (Weekday). |
event_frequency_count |
Int | No | Number of times the event should repeat. |
event_registration_swtich |
String | No | Enable registration for the event. Options: no, 1. |
event_registration_form |
String | No | Custom registration form shortcode for the event. |
event_email_additional_info |
String | No | Add additional info to event-related emails. |
Example Request Body
With Regular Tickets
{
"title": "Summer Music Festival",
"description": "A grand festival featuring live music performances.",
"event_start_dt": "2025-07-01 10:00",
"event_end_dt": "2025-07-01 22:00",
"tickets": [
{
"name": "General Admission",
"number": 500,
"price": 50.00,
"restrict": "0"
},
{
"name": "VIP Access",
"number": 50,
"price": 150.00,
"restrict": "1"
}
],
"eventer-category": ["Music", "Festivals"],
"eventer-tag": ["Outdoor", "Live"],
"eventer-venue": ["Central Park"],
"eventer-organizer": ["Event Co."]
}
With WooCommerce Tickets
{
"title": "Summer Music Festival",
"description": "A grand festival featuring live music performances.",
"event_start_dt": "2025-07-01 10:00",
"event_end_dt": "2025-07-01 22:00",
"woocommerce_tickets": [
{
"product_id": 1234,
"name": "VIP Access",
"number": 50,
"price": 150.00,
"enabled": "2025-06-30",
"action": "add"
}
],
"disable_booking_before": 2,
"common_ticket_count": 550,
"eventer-category": ["Music", "Festivals"],
"eventer-tag": ["Outdoor", "Live"],
"eventer-venue": ["Central Park"],
"eventer-organizer": ["Event Co."]
}
Response
Success
{
"success": true,
"message": "Event saved successfully.",
"event_id": 123
}
Error
{
"success": false,
"message": "The \"title\" field is required."
}
Notes
- Authentication: Ensure that the user associated with the application password has the necessary permissions (e.g.,
edit_posts). - WooCommerce Tickets: Use
woocommerce_ticketsonly if WooCommerce ticketing is enabled in the plugin settings. - Validation: Validate fields like
event_start_dt,event_end_dt, and ticket prices to ensure correct data formats. - Optional Fields: Only include fields that are relevant to your event configuration to simplify the request.