> For the complete documentation index, see [llms.txt](https://docs.neox.vn/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.neox.vn/docs/global/global-collections/sub-merchant-management/webhook.md).

# Webhook

For general information on how NeoX Global Collections delivers webhook notifications — including delivery guarantees, retry schedule, security verification, and how to respond — refer to the [Event Notification guide](/docs/global/global-collections/integration/event-notification.md).

### Event data

| Field Name    | Type   | Description                                                                                                                                       |
| ------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| requestId     | string | The original merchant-supplied `requestId` that triggered this event.                                                                             |
| type          | string | Webhook category. Fixed value: `SUB_MERCHANT`.                                                                                                    |
| merchantCode  | string | NeoX identifier of the parent merchant.                                                                                                           |
| subMerchantId | string | NeoX identifier of the sub-merchant whose status has changed.                                                                                     |
| eventType     | string | The specific lifecycle event that triggered this notification. Enum: `ONBOARDING`, `QUALIFICATION_RENEWAL`.                                       |
| status        | string | Outcome of the event. Enum: `PROCESS`, `SUCCESS`, `FAILED`.                                                                                       |
| errCode       | string | Error code when `status` is `FAILED`; empty otherwise.                                                                                            |
| errMsg        | string | Human-readable error description when `status` is `FAILED`; empty otherwise.                                                                      |
| createdAt     | string | ISO 8601 timestamp of when the event was generated (e.g. `2024-06-01T08:30:00Z`).                                                                 |
| secureHash    | string | Base64-encoded SHA-256 HMAC signature computed over the sorted payload fields concatenated with your Secret Key. Use this to verify authenticity. |

#### Status Values

| Status    | Applicable eventType                  | Meaning                                                          |
| --------- | ------------------------------------- | ---------------------------------------------------------------- |
| `PROCESS` | `ONBOARDING`, `QUALIFICATION_RENEWAL` | The application or renewal is under review by the platform.      |
| `SUCCESS` | `ONBOARDING`, `QUALIFICATION_RENEWAL` | The application or renewal was approved successfully.            |
| `FAILED`  | `ONBOARDING`, `QUALIFICATION_RENEWAL` | The application or renewal was rejected; see `errCode`/`errMsg`. |

### Sample data

```json
{
  "requestId": "a3f1e2d4-1234-4c78-b9ab-0987654321cd",
  "type": "SUB_MERCHANT",
  "merchantCode": "MC-00012345",
  "subMerchantId": "SM-00098761",
  "eventType": "ONBOARDING",
  "status": "SUCCESS",
  "errCode": "",
  "errMsg": "",
  "createdAt": "2024-06-01T08:30:00Z",
  "secureHash": "bXlTZWN1cmVIYXNoVmFsdWVFeGFtcGxlMTIzNDU2Nzg5MA=="
}
```
