Api DocumentationClientWebhooks

Webhook Operations

POST /clientWebhook

Description: Creates a new webhook for client notifications.

Request Body:

{
  "url": "https://huuuuuuuuuuuuuuuuuuuum2g96068888jjjiui-3010.i99999999nc1.devtunnels.ms/webhookyutyuiyui99999",
  "webhook_secret": "adsf4r23rsdsdf2#23wdsf)88877778-dsf9999_23"
}

Success Response (200 OK):

{
  "message": "Webhook created successfully",
  "updatedWebhook": {
    "response": {
      "status": true,
      "message": "Webhook created successfully",
      "data": {
        "webhook_id": "29a9913c-4b14-4c71-a3cf-022ee612341f",
        "client_id": "e513739a-5231-4538-a818-ea2b8a1a2bc0",
        "url": "https://huuuuuuuuuuuuuuuuuuuum2g96068888jjjiui-3010.i99999999nc1.devtunnels.ms/webhookyutyuiyui99999"
      }
    }
  }
}

GET /clientWebhook

Description: Retrieves the client’s webhook configuration.

Success Response (200 OK):

{
  "message": "Webhook retrived successfully",
  "data": {
    "webhook_id": "29a9913c-4b14-4c71-a3cf-022ee612341f",
    "client_id": "e513739a-5231-4538-a818-ea2b8a1a2bc0",
    "url": "https://huuuuuuuuuuuuuuuuuuuum2g96068888jjjiui-3010.i99999999nc1.devtunnels.ms/webhookyutyuiyui99999"
  }
}

PUT /clientWebhook

Description: Updates the client’s webhook configuration.

Request Body:

{
  "url": "https://hm2g9606-3010.inc1.devtunnels.ms/webhook",
  "webhook_secret": "adsf4r23rsdsdf2#23wdsf)-dsf_23"
}

Success Response (200 OK):

{
  "message": "Webhook updated successfully",
  "updatedWebhook": {
    "response": {
      "status": true,
      "message": "Webhook updated successfully",
      "data": {
        "webhook_id": "29a9913c-4b14-4c71-a3cf-022ee612341f",
        "client_id": "e513739a-5231-4538-a818-ea2b8a1a2bc0",
        "url": "https://hm2g9606-3010.inc1.devtunnels.ms/webhook"
      }
    }
  }
}