List the webhook subscriptions of a merchant
webhooks:manageRequired scope (API key) or equivalent permission (password): webhooks:manage.
المعاملات
| الاسم | الموضع | النوع | الوصف |
|---|---|---|---|
merchantIdمطلوب | path | string (uuid) | Merchant id. |
مثال طلب
curl "https://api.goldrock.live/api/public/v1/merchants/3fa85f64-5717-4562-b3fc-2c963f66afa6/webhooks" \
-H "X-API-Key: lmc_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
-H "X-API-Secret: YOUR_API_SECRET"const response = await fetch("https://api.goldrock.live/api/public/v1/merchants/3fa85f64-5717-4562-b3fc-2c963f66afa6/webhooks", {
method: "GET",
headers: {
"X-API-Key": "lmc_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"X-API-Secret": "YOUR_API_SECRET"
},
});
const data = await response.json();
console.log(response.status, data);<?php
$url = 'https://api.goldrock.live/api/public/v1/merchants/3fa85f64-5717-4562-b3fc-2c963f66afa6/webhooks';
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-API-Key: lmc_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
'X-API-Secret: YOUR_API_SECRET',
],
]);
$result = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
var_dump($status, json_decode($result, true));import requests
response = requests.request(
"GET",
"https://api.goldrock.live/api/public/v1/merchants/3fa85f64-5717-4562-b3fc-2c963f66afa6/webhooks",
headers={
"X-API-Key": "lmc_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"X-API-Secret": "YOUR_API_SECRET",
},
timeout=30,
)
print(response.status_code, response.json())تستخدم الأمثلة مفتاح API؛ استبدل القيم النائبة. لاستخدام رمز Bearer أرسل Authorization: Bearer <accessToken>.
الاستجابات
200The subscriptions (without secrets).
الاستجابات · الحقل
| الحقل | النوع | الوصف |
|---|---|---|
id | string (uuid) | Subscription id. |
merchantId | string (uuid) | The merchant whose shipments trigger the events. |
url | stringيقبل null | The receiving URL. |
events | array<string>يقبل null | Subscribed event types. |
description | stringيقبل null | Description. |
isActive | boolean | False when the subscription is paused. |
createdAt | string (date-time) | Creation time (UTC). |
[
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"merchantId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"isActive": false,
"createdAt": "2026-01-15T09:30:00Z"
}
]| الحالة | الوصف |
|---|---|
401 | Authentication is missing or invalid (code |
403 | The credential lacks the required scope, or the public API is disabled (codes |
404 | Code |
429 | Too many requests (code |
تشترك أخطاء الواجهة في جسم واحد موصوف في مرجع الأخطاء. مرجع الأخطاء