Paycose Docs
Meter Event
POST/meter_events

Create Meter Event

Body — CreateMeterEventDTO. Top-level customer_id is the wallet's internal customer UUID; the wallet resolves it to the provider customer reference (e.g. Stripe cus_xxx) and injects it under payload.customer server-side. payload only carries metric values matching the meter's value_settings.event_payload_key (here, value).

Request

Example

curl -X POST 'https://api.paycose.com/api/v1/app1/platform/wallet/meter_events/' \
  -H 'X-Session-Token: {{session_token}}' \
  -H 'X-Country: {{country}}' \
  -H 'X-Test-Mode: {{x_test_mode}}' \
  -d '{
  "event_name": "api_request2",
  "customer_id": "{{customer_id}}",
  "identifier": "req_abc1234567",
  "payload": {
    "value": "1"
  },
  "timestamp": "2026-05-11 20:00:00"
}'

Headers

NameValueDescription
X-Session-Token{{session_token}}
X-Country{{country}}
X-Test-Mode{{x_test_mode}}true=wallet_test, false=wallet_live (default). Toggle the x_test_mode collection variable to flip every applicable request.

Body

NameTypeValue
event_namestringapi_request2
customer_idstring{{customer_id}}
identifierstringreq_abc1234567
payloadobject{…}
timestampstring2026-05-11 20:00:00
{
  "event_name": "api_request2",
  "customer_id": "{{customer_id}}",
  "identifier": "req_abc1234567",
  "payload": {
    "value": "1"
  },
  "timestamp": "2026-05-11 20:00:00"
}

Responses

200200 OK

Headers

NameValue
Content-Typeapplication/json

Body

{
  "id": "<string>",
  "object": "<string>",
  "resource": "<string>",
  "created_at": "<RFC3339 timestamp>",
  "errors": [
    {
      "code": "<string>",
      "message": "<string>"
    }
  ],
  "next_action": [
    {
      "type": "<string>",
      "title": "<string>",
      "description": "<string>",
      "i18n_key": "<string>",
      "url": "<string>",
      "client_secret": "<string>",
      "payment_method": "<string>",
      "qr_data": "<string>"
    }
  ]
}
400400 Bad Request

Headers

NameValue
Content-Typeapplication/json

Body

{
  "object": "error",
  "code": "<string>",
  "key": "<string>",
  "i18n_key": "<string>",
  "message": "<string>",
  "request_id": "<string>"
}

On this page