List AppStack webhooks

Updated at:

Retrieves a list of webhooks configured for AppStack.

Applicable editions

Centralized Edition, Regional Edition

Service endpoints and authorization

  • Replace {domain} in the request URL with your service endpoint.
  • Get a personal access token.
  • Get the organization ID: Required only for the Centralized Edition. Get your organization ID from the Basic Information page in the Organization Management Backend.

Product

Resource

Required permission

AppStack

webhook

Read-only

Request syntax

Centralized Edition

GET https://{domain}/oapi/v1/appstack/organizations/{organizationId}/hook

Regional Edition

GET https://{domain}/oapi/v1/appstack/hook

Request headers

Parameter

Type

Required

Description

Example

x-yunxiao-token

string

Yes

The personal access token.

pt-0fh3****0fbG_35af****0484

Request parameters

Parameter

Type

In

Required

Description

Example

organizationId

string

path

  • Yes, for Centralized Edition

  • No, for Regional Edition

The organization ID.

ec766e6xxxxxxxxxx34d6exe671

scopeType

string

query

Yes

The scope type.

ORGANIZATION

scopeId

string

query

Yes

The scope ID. You can provide one or more comma-separated IDs.

YOUR_ORG_ID,YOUR_APP_NAME

channelType

string

query

Yes

The resource type.

WEBHOOK

Request examples

Centralized Edition

curl -X 'GET' \
  'https://{domain}/oapi/v1/appstack/organizations/ec766e6xxxxxxxxxx34d6exe671/hook?scopeType=ORGANIZATION&scopeId=YOUR_ORG_ID,YOUR_APP_NAME&channelType=WEBHOOK' \
  -H 'Content-Type: application/json' \
  -H 'x-yunxiao-token: pt-0fh3****0fbG_35af****0484'

Regional Edition

curl -X 'GET' \
  'https://{domain}/oapi/v1/appstack/hook?scopeType=ORGANIZATION&scopeId=YOUR_ORG_ID,YOUR_APP_NAME&channelType=WEBHOOK' \
  -H 'Content-Type: application/json' \
  -H 'x-yunxiao-token: pt-0fh3****0fbG_35af****0484'

Response parameters

Parameter

Type

Description

Example

-

array

An array of webhook objects.

-

object

The AppStack webhook configuration.

description

string

The webhook description, up to 256 characters long.

Test

disabledExpired

string

The expiration timestamp for a disabled webhook.

enabled

boolean

Whether the webhook is enabled.

true

events

array

The events that trigger the webhook.

-

object

action

string

The event action.

Create

event

string

The event type.

App

scopeId

string

The scope ID.

YOUR_ORG_ID,YOUR_APP_NAME

scopeType

string

The scope type. Valid values: ORGANIZATION, APP.

ORGANIZATION

sn

string

The webhook's unique identifier.

c263a6749757xxxxxx2f45f2f80e

spec

object

The webhook specifications.

token

string

The webhook's secret token, up to 128 characters long.

type

string

The webhook type.

WEBHOOK

url

string

The webhook's payload URL, up to 1024 characters long.

https://devops.aliyun.com/appstack/setting/webhooks

timeout

integer

The timeout in seconds.

3

type

string

The webhook type.

WEBHOOK

Response example

[
    {
        "description": "Test",
        "disabledExpired": "",
        "enabled": true,
        "events": [
            {
                "action": "Create",
                "event": "App"
            }
        ],
        "scopeId": "YOUR_ORG_ID,YOUR_APP_NAME",
        "scopeType": "ORGANIZATION",
        "sn": "c263a6749757xxxxxx2f45f2f80e",
        "spec": {
            "token": "",
            "type": "WEBHOOK",
            "url": "https://devops.aliyun.com/appstack/setting/webhooks"
        },
        "timeout": 3,
        "type": "WEBHOOK"
    }
]

Error codes

For API-related error codes, see the Error Code Center.