Skip to main content
POST
https://api.owem.com.br
/
v4
/
i
/
webhooks
/
config
Create Webhook
curl --request POST \
  --url https://api.owem.com.br/v4/i/webhooks/config \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "event": [
    {}
  ],
  "targetUrl": "<string>",
  "authHeader": "<string>"
}
'
{
  "requestId": "a111b222-c333-4d44-8e55-f66677788899",
  "success": true,
  "size": 1,
  "data": {
    "configId": "wc_bd121426-4da1-4de4-b420-1b063aef81ee",
    "userId": "usr_abcdef12",
    "event": ["*"],
    "targetUrl": "https://hooks.yourserver.com/owem",
    "authHeader": "Bearer whsec_abc123example",
    "isEnabled": true,
    "createdAt": 1760000000000,
    "updatedAt": 1760000000000,
    "deletedAt": null
  }
}

Purpose

Creates a webhook configuration to receive events from Owem. When a configured event occurs, Owem sends a POST to your URL with the event data.

Authentication

Authorization
string
required
Basic Auth required in format: Basic {Base64(API_KEY:API_SECRET)}

Request Body

event
array
required
Events of interest. Use "*" for all events, or provide a list (e.g., ["pix_in:qrcode_paid","pix_out:processing"]).
targetUrl
string
required
Public HTTPS URL to receive webhooks. Must accept POST and return 2xx within 3s.
authHeader
string
Value to be sent in Authorization on all webhook calls. Useful for validation on your end.

Supported Events

EventTrigger
pix_in:qrcode_paidPayment via QR Code
pix_in:creditedCredit via PIX key
pix_in:refunded_processingPIX IN refund initiated
pix_in:refunded_med_processingPIX IN refund by MED
pix_out:processingPIX OUT transfer registered
pix_out:refunded_processingPIX OUT refund initiated
med:receivedMED received
*All events

Response

requestId
string
UUID for tracking
success
boolean
Operation status
size
number
Number of returned items
data
object
{
  "requestId": "a111b222-c333-4d44-8e55-f66677788899",
  "success": true,
  "size": 1,
  "data": {
    "configId": "wc_bd121426-4da1-4de4-b420-1b063aef81ee",
    "userId": "usr_abcdef12",
    "event": ["*"],
    "targetUrl": "https://hooks.yourserver.com/owem",
    "authHeader": "Bearer whsec_abc123example",
    "isEnabled": true,
    "createdAt": 1760000000000,
    "updatedAt": 1760000000000,
    "deletedAt": null
  }
}

Status Codes

HTTPWhen it occurs
201Configuration created successfully
400Invalid payload (malformed URL, invalid events, missing fields)
401Invalid/revoked credentials
403IP not allowlisted
409Conflict (duplicate config for same targetUrl/scope)
429Rate limit exceeded
500Internal error

Best Practices

Use a dedicated URL for webhooks with observability (logs/trace/metrics).
Protect the authHeader as a secret and rotate it periodically.