Add authentication with OAuth2
Activate OAuth2 authentication for webhooks.
Path parameters
-
platform-code string Required
The unique code assigned to the reservation platform.
Maximum length is
11
. Format should match the following pattern:[a-zA-Z0-9_-]+
.
Body
-
clientId string Required
The OAuth2 client ID.
-
clientSecret string(password) Required
The OAuth2 client secret.
-
clientName string
The OAuth2 client name.
-
scopes array[string]
The scopes being granted to the API client.
-
providerTokenUri string(uri) Required
The external platform URL for getting access tokens by private credentials of the K-Series.
-
providerJwkSetUri string(uri)
The external platform URL for getting public keys to verify given access tokens on the K-Series side.
curl \
-X PATCH https://api.trial.lsk.lightspeed.app/reservation/api/1/platform/EasyTable/webhook/auth/oauth2 \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"clientId":"LightspeedKSeries","clientSecret":"Example-Client-Secret","clientName":"LightspeedKSeries","clientAuthorizationMethod":"CLIENT_SECRET_BASIC","authorizationGrantType":"CLIENT_CREDENTIALS","scopes":["webhooks-api"],"providerTokenUri":"https://table.easy/emitter/token","providerJwkSetUri":"https://table.easy/public-keys"}'
{
"clientId": "LightspeedKSeries",
"clientSecret": "Example-Client-Secret",
"clientName": "LightspeedKSeries",
"clientAuthorizationMethod": "CLIENT_SECRET_BASIC",
"authorizationGrantType": "CLIENT_CREDENTIALS",
"scopes": [
"webhooks-api"
],
"providerTokenUri": "https://table.easy/emitter/token",
"providerJwkSetUri": "https://table.easy/public-keys"
}