Get a Trigger Execution

Retrieves a single trigger execution by its ID.

Retrieves a single trigger execution by its ID.

A trigger execution is the record created each time a trigger fires. It captures the inbound event and tracks whether that event was successfully turned into a workflow run.

key

Use HTTP Basic auth with your PayMongo secret key as the username and an empty password. Include Organization-Id: <your organization id> on every request.

Request

GET https://workflow-api.paymongo.com/v1/trigger-executions/{id}

Path parameters

ParameterTypeRequiredDescription
idstringYesThe trigger execution ID to retrieve.

Headers

HeaderTypeRequiredDescription
AuthorizationstringYesHTTP Basic auth credentials generated from your secret key and an empty password.
Organization-IdstringYesYour organization ID. Must match the organization that owns the secret key.

Request body

This endpoint does not accept a request body.

Response

Returns the trigger execution wrapped in a top-level data object.

FieldTypeDescription
data.idstringThe trigger execution ID.
data.trigger_idstringID of the trigger that produced this execution.
data.workflow_instance_idstring | nullID of the workflow instance started by this execution. null if a workflow run has not yet been created for it.
data.event_message_idstringUnique ID of the inbound event message, used for idempotency and deduplication.
data.event_payloadobjectThe raw event payload that was received.
data.statestringLifecycle state of the execution. One of pending, executed, or failed.
data.livemodebooleantrue if the execution belongs to live mode, false for test mode.
data.created_atstringRFC 3339 timestamp for when the execution record was created.
data.updated_atstringRFC 3339 timestamp for when the execution record was last updated.

State values

ValueMeaning
pendingThe event was recorded; a workflow instance has not been started yet.
executedThe event was successfully processed and a workflow instance was started.
failedProcessing the event failed.

Example request

curl https://workflow-api.paymongo.com/v1/trigger-executions/trgexec_abc123 \
  -u sk_test_xxxxxxxxxxxxxxxx: \
  -H "Organization-Id: org_xxxxxxxxxxxx"

Example response

{
  "data": {
    "id": "trgexec_abc123",
    "trigger_id": "trg_def456",
    "workflow_instance_id": "winst_ghi789",
    "event_message_id": "evtmsg_jkl012",
    "event_payload": {
      "type": "payment.paid",
      "data": {
        "amount": 100000,
        "currency": "PHP"
      }
    },
    "state": "executed",
    "livemode": false,
    "created_at": "2026-06-18T04:21:00Z",
    "updated_at": "2026-06-18T04:21:02Z"
  }
}

Errors

Errors return a top-level errors array. Each error includes a machine-readable code and a human-readable detail.

HTTP statusCodeWhen it happens
400 Bad Requestinvalid_request_bodyThe id path segment is empty.
400 Bad Requestmissing_organization_idOrganization-Id is missing on a non-superuser request.
404 Not Foundtrigger_execution_not_foundNo trigger execution with that ID exists for this organization and mode.
500 Internal Server Errorinternal_server_errorAn unexpected server error occurred.

Example error

{
  "errors": [
    {
      "code": "trigger_execution_not_found",
      "detail": "trigger execution not found"
    }
  ]
}
eye-slash

Public responses omit internal/admin-only fields such as internal, trigger_arn, and temporal_schedule_id.

Mode behavior

Mode is derived from the secret key prefix. An sk_test_… key operates in test mode (livemode = false), and an sk_live_… key operates in live mode (livemode = true). A resource created in one mode is only visible to keys of the same mode.