Skip to main content
PUT
/
api
/
v2
/
public
/
application
/
event
/
:event_id
curl -X PUT "https://app.refold.ai/api/v2/public/application/event/{event_id}" \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "candidate_created",
    "response": "{ \"event\": \"candidate_created\", \"payload\": { \"email\": \"jane@example.com\" } }"
  }'
[
  {
    "_id": "6a314123d0aeb8165be4f175",
    "name": "candidate_created",
    "response": [
      { "key": "event", "type": "text" },
      { "key": "payload", "type": "object" }
    ]
  }
]
Edit an existing custom event (trigger) on your organization’s default custom application. The response is the full, updated list of events.

Authentication

Events are defined at the org level, so this endpoint uses API-key auth.
x-api-key
string
required
Your Refold API key. Find it in Settings → Credentials.

Path Parameters

event_id
string
required
The event ID to update.

Body Parameters

name
string
required
Event name.
response
string
required
Sample payload (as a string) describing the event’s data shape.
json_schema
object
Optional JSON schema describing the payload.

Response

Returns the full updated array of events for the default app.
[
  {
    "_id": "6a314123d0aeb8165be4f175",
    "name": "candidate_created",
    "response": [
      { "key": "event", "type": "text" },
      { "key": "payload", "type": "object" }
    ]
  }
]
curl -X PUT "https://app.refold.ai/api/v2/public/application/event/{event_id}" \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "candidate_created",
    "response": "{ \"event\": \"candidate_created\", \"payload\": { \"email\": \"jane@example.com\" } }"
  }'