Create Subscription
curl --request POST \
--url https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions \
--header 'Api-Version: <api-version>' \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"description": "Notify when an asset finishes processing",
"endpointUrl": "https://your-server.example.com/webhooks",
"eventTypes": [
"asset.processing.completed"
]
}
'import requests
url = "https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions"
payload = {
"description": "Notify when an asset finishes processing",
"endpointUrl": "https://your-server.example.com/webhooks",
"eventTypes": ["asset.processing.completed"]
}
headers = {
"Api-Version": "<api-version>",
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Api-Version': '<api-version>',
'X-API-Key': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
description: 'Notify when an asset finishes processing',
endpointUrl: 'https://your-server.example.com/webhooks',
eventTypes: ['asset.processing.completed']
})
};
fetch('https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions', 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.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'description' => 'Notify when an asset finishes processing',
'endpointUrl' => 'https://your-server.example.com/webhooks',
'eventTypes' => [
'asset.processing.completed'
]
]),
CURLOPT_HTTPHEADER => [
"Api-Version: <api-version>",
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$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.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions"
payload := strings.NewReader("{\n \"description\": \"Notify when an asset finishes processing\",\n \"endpointUrl\": \"https://your-server.example.com/webhooks\",\n \"eventTypes\": [\n \"asset.processing.completed\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Api-Version", "<api-version>")
req.Header.Add("X-API-Key", "<api-key>")
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.post("https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions")
.header("Api-Version", "<api-version>")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"description\": \"Notify when an asset finishes processing\",\n \"endpointUrl\": \"https://your-server.example.com/webhooks\",\n \"eventTypes\": [\n \"asset.processing.completed\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Api-Version"] = '<api-version>'
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"description\": \"Notify when an asset finishes processing\",\n \"endpointUrl\": \"https://your-server.example.com/webhooks\",\n \"eventTypes\": [\n \"asset.processing.completed\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"endpointUrl": "<string>",
"eventTypes": [
"<string>"
],
"enabled": true,
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"secret": "<string>",
"description": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}API Endpoints
Create Subscription
Create a new webhook subscription.
Creates a webhook subscription for receiving events (e.g., asset processing completion).
The endpoint must use HTTPS and will receive signed webhook payloads.
Authentication: Requires X-API-Key header with valid API key.
Args:
request_data: Webhook subscription creation request
identity: Authenticated API key identity
webhook_adapter: Webhook adapter for creating subscriptions (injected)
repository: Repository for persisting subscriptions (injected)
Returns:
WebhookSubscriptionResponse with subscription details and signing secret
Raises:
401: If API key missing or invalid
422: If request validation fails (e.g., non-HTTPS URL) or the
workspace has reached its webhook subscription limit
Example:
POST /api/v1/integrations/webhooks/subscriptions
{
"endpoint_url": "https://example.com/webhooks",
"event_types": ["asset.processing.completed", "asset.processing.failed"],
"description": "Production webhook endpoint"
}
Response (201):
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"workspace_id": "660e8400-e29b-41d4-a716-446655440001",
"endpoint_url": "https://example.com/webhooks",
"secret": "whsec_AbCdEf1234567890...",
"event_types": ["asset.processing.completed", "asset.processing.failed"],
"description": "Production webhook endpoint",
"enabled": true,
"created_at": "2026-04-09T12:00:00Z",
"updated_at": "2026-04-09T12:00:00Z"
}
POST
/
api
/
webhooks
/
subscriptions
Create Subscription
curl --request POST \
--url https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions \
--header 'Api-Version: <api-version>' \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"description": "Notify when an asset finishes processing",
"endpointUrl": "https://your-server.example.com/webhooks",
"eventTypes": [
"asset.processing.completed"
]
}
'import requests
url = "https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions"
payload = {
"description": "Notify when an asset finishes processing",
"endpointUrl": "https://your-server.example.com/webhooks",
"eventTypes": ["asset.processing.completed"]
}
headers = {
"Api-Version": "<api-version>",
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'Api-Version': '<api-version>',
'X-API-Key': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
description: 'Notify when an asset finishes processing',
endpointUrl: 'https://your-server.example.com/webhooks',
eventTypes: ['asset.processing.completed']
})
};
fetch('https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions', 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.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'description' => 'Notify when an asset finishes processing',
'endpointUrl' => 'https://your-server.example.com/webhooks',
'eventTypes' => [
'asset.processing.completed'
]
]),
CURLOPT_HTTPHEADER => [
"Api-Version: <api-version>",
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$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.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions"
payload := strings.NewReader("{\n \"description\": \"Notify when an asset finishes processing\",\n \"endpointUrl\": \"https://your-server.example.com/webhooks\",\n \"eventTypes\": [\n \"asset.processing.completed\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Api-Version", "<api-version>")
req.Header.Add("X-API-Key", "<api-key>")
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.post("https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions")
.header("Api-Version", "<api-version>")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"description\": \"Notify when an asset finishes processing\",\n \"endpointUrl\": \"https://your-server.example.com/webhooks\",\n \"eventTypes\": [\n \"asset.processing.completed\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.northell.io/nhl/prod/mediamagic-verify-integrations/api/webhooks/subscriptions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Api-Version"] = '<api-version>'
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"description\": \"Notify when an asset finishes processing\",\n \"endpointUrl\": \"https://your-server.example.com/webhooks\",\n \"eventTypes\": [\n \"asset.processing.completed\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"endpointUrl": "<string>",
"eventTypes": [
"<string>"
],
"enabled": true,
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"secret": "<string>",
"description": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Headers
Body
application/json
Request model for creating a webhook subscription.
Response
Successful Response
Response model for creating a webhook subscription (includes one-time secret).
The signing secret is only shown once at creation time. The customer must store this secret to verify webhook signatures from Hookdeck.