Org Webhooks

This contains APIs for Org Webhooks.

Lists all the Webhooks at Org level

List org level webhooks

Securityx-api-key
Request
path Parameters
org
required
string

Identifier field of the organization the resource is scoped to

query Parameters
page
integer
Default: 0

Pagination page number strategy: Specify the page number within the paginated collection related to the number of items in each page

limit
integer <= 1000
Default: 20

Number of items to return per page.

header Parameters
Harness-Account
string

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Request Body schema: application/json

List webhooks request

webhook_type
string
Enum: "GIT" "GENERIC" "SLACK" "EVENT_BRIDGE_TRIGGER"
Responses
200

Example response

post/v1/orgs/{org}/webhooks/list
Request samples
application/json
{
  • "webhook_type": "GIT"
}
Response samples
application/json
[
  • {
    }
]

Create a webhook at Org level

Create webhooks at org level

Securityx-api-key
Request
path Parameters
org
required
string

Identifier field of the organization the resource is scoped to

header Parameters
Harness-Account
string

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Request Body schema: application/json

Create webhook request

webhook_identifier
required
string^[0-9a-zA-Z-_ ]{0,127}$
webhook_name
required
string
required
object (WebhookSpec)

Details of the Webhook defined in Harness

Responses
201

Example response

post/v1/orgs/{org}/webhooks
Request samples
application/json
{
  • "webhook_identifier": "string",
  • "webhook_name": "string",
  • "spec": {
    }
}
Response samples
application/json
{
  • "webhook_identifier": "string"
}

Fetch Webhook at org level

Fetch Webhook at org level

Securityx-api-key
Request
path Parameters
org
required
string

Identifier field of the organization the resource is scoped to

webhook
required
string

Webhook identifier

header Parameters
Harness-Account
string

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Responses
200

Example response

get/v1/orgs/{org}/webhooks/{webhook}
Request samples
Response samples
application/json
{
  • "webhook_identifier": "string",
  • "webhook_name": "string",
  • "is_enabled": true,
  • "event_trigger_time": 0,
  • "spec": {
    }
}

Updates a Webhook at Org level

Updates a Webhook at Org level

Securityx-api-key
Request
path Parameters
org
required
string

Identifier field of the organization the resource is scoped to

webhook
required
string

Webhook identifier

header Parameters
Harness-Account
string

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Request Body schema: application/json

Update webhook request

webhook_name
required
string
is_enabled
required
boolean
required
object (WebhookSpec)

Details of the Webhook defined in Harness

Responses
200

Example response

put/v1/orgs/{org}/webhooks/{webhook}
Request samples
application/json
{
  • "webhook_name": "string",
  • "is_enabled": true,
  • "spec": {
    }
}
Response samples
application/json
{
  • "webhook_identifier": "string"
}

Deletes a Webhook at org level

Deletes a Webhook at org level

Securityx-api-key
Request
path Parameters
org
required
string

Identifier field of the organization the resource is scoped to

webhook
required
string

Webhook identifier

header Parameters
Harness-Account
string

Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.

Responses
204

No Content

delete/v1/orgs/{org}/webhooks/{webhook}
Request samples