Edit an organization webhook
curl --request PUT \
--url https://api.qovery.com/organization/{organizationId}/webhook/{webhookId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"kind": "STANDARD",
"target_url": "<string>",
"events": [],
"target_secret": "<string>",
"description": "<string>",
"enabled": true,
"project_names_filter": [
"<string>"
],
"environment_types_filter": [
"PRODUCTION"
]
}
'import requests
url = "https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}"
payload = {
"kind": "STANDARD",
"target_url": "<string>",
"events": [],
"target_secret": "<string>",
"description": "<string>",
"enabled": True,
"project_names_filter": ["<string>"],
"environment_types_filter": ["PRODUCTION"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
kind: 'STANDARD',
target_url: '<string>',
events: [],
target_secret: '<string>',
description: '<string>',
enabled: true,
project_names_filter: ['<string>'],
environment_types_filter: ['PRODUCTION']
})
};
fetch('https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'kind' => 'STANDARD',
'target_url' => '<string>',
'events' => [
],
'target_secret' => '<string>',
'description' => '<string>',
'enabled' => true,
'project_names_filter' => [
'<string>'
],
'environment_types_filter' => [
'PRODUCTION'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}"
payload := strings.NewReader("{\n \"kind\": \"STANDARD\",\n \"target_url\": \"<string>\",\n \"events\": [],\n \"target_secret\": \"<string>\",\n \"description\": \"<string>\",\n \"enabled\": true,\n \"project_names_filter\": [\n \"<string>\"\n ],\n \"environment_types_filter\": [\n \"PRODUCTION\"\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"kind\": \"STANDARD\",\n \"target_url\": \"<string>\",\n \"events\": [],\n \"target_secret\": \"<string>\",\n \"description\": \"<string>\",\n \"enabled\": true,\n \"project_names_filter\": [\n \"<string>\"\n ],\n \"environment_types_filter\": [\n \"PRODUCTION\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"kind\": \"STANDARD\",\n \"target_url\": \"<string>\",\n \"events\": [],\n \"target_secret\": \"<string>\",\n \"description\": \"<string>\",\n \"enabled\": true,\n \"project_names_filter\": [\n \"<string>\"\n ],\n \"environment_types_filter\": [\n \"PRODUCTION\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"kind": "STANDARD",
"target_url": "<string>",
"target_secret_set": true,
"description": "<string>",
"enabled": true,
"events": [
"DEPLOYMENT_STARTED"
],
"project_names_filter": [
"<string>"
],
"environment_types_filter": [
"PRODUCTION"
]
}Organization Webhook
Edit an organization webhook
Edit an organization webhook
PUT
/
organization
/
{organizationId}
/
webhook
/
{webhookId}
Edit an organization webhook
curl --request PUT \
--url https://api.qovery.com/organization/{organizationId}/webhook/{webhookId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"kind": "STANDARD",
"target_url": "<string>",
"events": [],
"target_secret": "<string>",
"description": "<string>",
"enabled": true,
"project_names_filter": [
"<string>"
],
"environment_types_filter": [
"PRODUCTION"
]
}
'import requests
url = "https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}"
payload = {
"kind": "STANDARD",
"target_url": "<string>",
"events": [],
"target_secret": "<string>",
"description": "<string>",
"enabled": True,
"project_names_filter": ["<string>"],
"environment_types_filter": ["PRODUCTION"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
kind: 'STANDARD',
target_url: '<string>',
events: [],
target_secret: '<string>',
description: '<string>',
enabled: true,
project_names_filter: ['<string>'],
environment_types_filter: ['PRODUCTION']
})
};
fetch('https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'kind' => 'STANDARD',
'target_url' => '<string>',
'events' => [
],
'target_secret' => '<string>',
'description' => '<string>',
'enabled' => true,
'project_names_filter' => [
'<string>'
],
'environment_types_filter' => [
'PRODUCTION'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}"
payload := strings.NewReader("{\n \"kind\": \"STANDARD\",\n \"target_url\": \"<string>\",\n \"events\": [],\n \"target_secret\": \"<string>\",\n \"description\": \"<string>\",\n \"enabled\": true,\n \"project_names_filter\": [\n \"<string>\"\n ],\n \"environment_types_filter\": [\n \"PRODUCTION\"\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"kind\": \"STANDARD\",\n \"target_url\": \"<string>\",\n \"events\": [],\n \"target_secret\": \"<string>\",\n \"description\": \"<string>\",\n \"enabled\": true,\n \"project_names_filter\": [\n \"<string>\"\n ],\n \"environment_types_filter\": [\n \"PRODUCTION\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.qovery.com/organization/{organizationId}/webhook/{webhookId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"kind\": \"STANDARD\",\n \"target_url\": \"<string>\",\n \"events\": [],\n \"target_secret\": \"<string>\",\n \"description\": \"<string>\",\n \"enabled\": true,\n \"project_names_filter\": [\n \"<string>\"\n ],\n \"environment_types_filter\": [\n \"PRODUCTION\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"kind": "STANDARD",
"target_url": "<string>",
"target_secret_set": true,
"description": "<string>",
"enabled": true,
"events": [
"DEPLOYMENT_STARTED"
],
"project_names_filter": [
"<string>"
],
"environment_types_filter": [
"PRODUCTION"
]
}Authorizations
bearerAuthApiKeyAuth
JWT tokens should be used with OIDC account (human to machine). JWT tokens used by the Qovery console to communicate with the API have a TTL. Curl Example ' curl https://console.qovery.com/organization -H "Authorization: Bearer $qovery_token" '
Path Parameters
Body
application/json
Events to subscribe to and send to the target_url.
DEPLOYMENT_STARTEDsend an event when a deployment is started and going to be executedDEPLOYMENT_CANCELLEDsend an event when a deployment is cancelledDEPLOYMENT_FAILUREsend an event when a deployment failedDEPLOYMENT_SUCCESSFULsend an event when a deployment is successful
Available options:
DEPLOYMENT_STARTED, DEPLOYMENT_CANCELLED, DEPLOYMENT_FAILURE, DEPLOYMENT_SUCCESSFUL Response
Edit an organization webhook
Events to subscribe to and send to the target_url.
DEPLOYMENT_STARTEDsend an event when a deployment is started and going to be executedDEPLOYMENT_CANCELLEDsend an event when a deployment is cancelledDEPLOYMENT_FAILUREsend an event when a deployment failedDEPLOYMENT_SUCCESSFULsend an event when a deployment is successful
Available options:
DEPLOYMENT_STARTED, DEPLOYMENT_CANCELLED, DEPLOYMENT_FAILURE, DEPLOYMENT_SUCCESSFUL Was this page helpful?