📘
Gleantap API
  • Introduction
  • Fetch Data
    • Attribute List
    • Attribute Event List
    • Locations
    • Class Schedule
    • Customers
    • Events for a Customer
    • Opted In Customers
    • Campaigns
    • Opted Out Customers
    • Workrooms
    • Forms
    • Form Submissions
  • Update Data
    • Create or Update Location
    • Create a Class
    • Delete Class
    • Create or Update Contact
    • SMS Opt-in a Contact
    • Add Memberships for Contact
    • Create an Event
    • Delete Contact
    • Merge Contacts
    • Send SMS Notification
    • Send Email Notifications
Powered by GitBook
On this page
  1. Update Data

Create an Event

PreviousAdd Memberships for ContactNextDelete Contact

Last updated 2 months ago

Create new event

post

Create a new event for a contact. To identify the contact, use either user_id, or email & firstname or phone & firstname

Header parameters
X-API-KEYstringRequired

Your API key

X-SECRET-KEYstringRequired

Your Secret key

Body
app_idstringRequired
_idstringOptional
user_idstringRequired
emailstringOptional
phonestringOptional
event_typestringRequired
event_namestringOptional
event_datestring · dateRequired

Date of the event in YYYY-MM-DD format

event_timestring · timeOptional

Time of the event in HH:MM AM/PM format

idstringRequired

Unique Event ID from your system

is_visitbooleanOptional
is_purchasebooleanOptional
event_dataobject[]Optional

Event data with custom fields such as status, staff etc.

Example: {"status":"completed","staff":"John Doe"}
Responses
200
Event created successfully
application/json
400
Invalid request
post
POST /v2/ExternalApi/newEvent HTTP/1.1
Host: api.gleantap.com
X-API-KEY: text
X-SECRET-KEY: text
Content-Type: application/json
Accept: */*
Content-Length: 269

{
  "app_id": "text",
  "_id": "text",
  "user_id": "text",
  "email": "text",
  "phone": "text",
  "event_type": "text",
  "event_name": "text",
  "event_date": "2025-05-21",
  "event_time": "16:29:10",
  "id": "text",
  "is_visit": true,
  "is_purchase": true,
  "event_data": {
    "status": "completed",
    "staff": "John Doe"
  }
}
{
  "result": "success"
}