Order and Pay: Webhook

Create a Webhook

Changed on

Configures a new webhook to be used for order status updates.

put/o/wh/1/webhook

Request

  • Base URL
    https://api.trial.lsk.lightspeed.app
  • URL
    https://api.trial.lsk.lightspeed.app/o/wh/1/webhook
  • Auth
    OAuth 2
    Authorization code: https://auth.lsk-prod.app/realms/k-series/protocol/openid-connect/auth
    Token URL: https://auth.lsk-prod.app/realms/k-series/protocol/openid-connect/token scopes: orders-api

Request body

endpointIdstring required

The unique endpoint ID, for example the integration name. Case sensitive.

urlstring required

The URL which this endpoint points to.

withBasicAuthboolean

If basic auth should be used, defaults to false.

usernamestring

The username for basic auth.

passwordstring

The password for basic auth.

provideAccountboolean

Whether or not to include account info in the notification.

expandTransactionsboolean

Whether or not to include transaction lines in the notification.

expandPaymentsboolean

Whether or not to include payment lines in the notification.

Example request

{
  "endpointId": "MY-AWESOME-ENDPOINT-ID",
  "url": "https://webhook.site/1dc40b86-3d0d",
  "withBasicAuth": true,
  "username": "username",
  "password": "password",
  "provideAccount": true,
  "expandTransactions": true,
  "expandPayments": true,
  "subscribeTo": [
    {
      "name": "DELIVERED",
      "resource": "order"
    }
  ]
}

Response

Webhook

endpointIdstring required

The unique endpoint ID, for example the integration name. Case sensitive.

urlstring required

The URL which this endpoint points to.

withBasicAuthboolean

If basic auth should be used, defaults to false.

usernamestring

The username for basic auth.

passwordstring

The password for basic auth.

provideAccountboolean

Whether or not to include account info in the notification.

expandTransactionsboolean

Whether or not to include transaction lines in the notification.

expandPaymentsboolean

Whether or not to include payment lines in the notification.

Example response

{
  "endpointId": "MY-AWESOME-ENDPOINT-ID",
  "url": "https://webhook.site/1dc40b86-3d0d",
  "withBasicAuth": true,
  "username": "username",
  "password": "password",
  "provideAccount": true,
  "expandTransactions": true,
  "expandPayments": true,
  "subscribeTo": [
    {
      "name": "DELIVERED",
      "resource": "order"
    }
  ]
}

Changes

    • warning

      added the new item enum value to the // response property for the response status

    • warning

      added the new order_api enum value to the // response property for the response status

    • info

      api tag Order and Pay: Webhook added

    • info

      api tag Order and Pay removed

    • info

      added the new item enum value to the request property //

    • info

      added the new order_api enum value to the request property //