Webhook

Criar uma configuração (url que receberá os eventos) de webhook

Changed on
post/webhook/v1/subscription

Request

Request body

namestring required

Nome da inscrição

urlstring required

URL do WebHook

Example request

{
  "name": "Aluno assistiu Aula",
  "url": "https://webhook.site/c8ff7d31-4fd9-40c7-8eca-b2334d996fb0",
  "events": [
    {
      "name": "nutror.lesson_watched"
    }
  ],
  "filters": [
    {
      "metadata": "productId",
      "values": [
        "123456"
      ]
    }
  ]
}

Response

Configuração de WebHook criada com sucesso

idstring required

ID da inscrição

namestring required

Nome da inscrição criada

secretIdstring required

Id do Secret de WebHook

urlstring required

URL do WebHook

statusstring required

Status da inscrição

Example response

{
  "id": "yaeung4oaxt25pi0bzzycoezf",
  "name": "Test for Doc",
  "secretId": "f87fce2b9bbbf534fc91fa63fdb697a4e9b7f17205c2577ef2cb1f9757307c180",
  "events": [
    {
      "name": "nutror.lesson_watched"
    }
  ],
  "url": "https://webhook.site/c8ff7d31-4fd9-40c7-8eca-b2334d996fb0",
  "status": "disabled"
}

Changes

    • breaking

      the request property became required

    • breaking

      the request property // became required

    • breaking

      the request property became required

    • breaking

      the request property // became required

    • breaking

      the request property // became required

    • breaking

      the request property became required

    • breaking

      the request property became required

    • breaking

      the / request property type changed from string to object

    • warning

      removed the request property

    • info

      added the new optional request property //

    • info

      added the new optional request property