curl --request GET \
--url https://api.context.dev/v1/webhooks/deliveries/{delivery_id}import requests
url = "https://api.context.dev/v1/webhooks/deliveries/{delivery_id}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.context.dev/v1/webhooks/deliveries/{delivery_id}', 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.context.dev/v1/webhooks/deliveries/{delivery_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.context.dev/v1/webhooks/deliveries/{delivery_id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.context.dev/v1/webhooks/deliveries/{delivery_id}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.context.dev/v1/webhooks/deliveries/{delivery_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"id": "<string>",
"event": "batch.completed",
"source": {
"type": "batch",
"batch_id": "<string>"
},
"url": "<string>",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"retry_expires_at": "2023-11-07T05:31:56Z",
"delivered_at": "2023-11-07T05:31:56Z",
"next_attempt_at": "2023-11-07T05:31:56Z",
"last_error": {
"code": "<string>",
"message": "<string>"
},
"event_id": "<string>",
"retry": {
"delays_seconds": [
10,
60,
300,
1800,
7200,
21600,
57600
]
},
"last_attempt": {
"attempt": 2,
"trigger": "initial",
"url": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"http_status": 123,
"error": {
"code": "<string>",
"message": "<string>"
}
},
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}Retrieve a Webhook Delivery
Get a webhook delivery, including its status and latest attempt.
curl --request GET \
--url https://api.context.dev/v1/webhooks/deliveries/{delivery_id}import requests
url = "https://api.context.dev/v1/webhooks/deliveries/{delivery_id}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.context.dev/v1/webhooks/deliveries/{delivery_id}', 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.context.dev/v1/webhooks/deliveries/{delivery_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.context.dev/v1/webhooks/deliveries/{delivery_id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.context.dev/v1/webhooks/deliveries/{delivery_id}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.context.dev/v1/webhooks/deliveries/{delivery_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"id": "<string>",
"event": "batch.completed",
"source": {
"type": "batch",
"batch_id": "<string>"
},
"url": "<string>",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"retry_expires_at": "2023-11-07T05:31:56Z",
"delivered_at": "2023-11-07T05:31:56Z",
"next_attempt_at": "2023-11-07T05:31:56Z",
"last_error": {
"code": "<string>",
"message": "<string>"
},
"event_id": "<string>",
"retry": {
"delays_seconds": [
10,
60,
300,
1800,
7200,
21600,
57600
]
},
"last_attempt": {
"attempt": 2,
"trigger": "initial",
"url": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"http_status": 123,
"error": {
"code": "<string>",
"message": "<string>"
}
},
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}{
"message": "<string>",
"error_code": "INTERNAL_ERROR",
"key_metadata": {
"credits_consumed": 123,
"credits_remaining": 123
}
}X-Context-Delivery-Id header. For the full delivery history, use List Webhook Delivery Attempts.Path Parameters
Delivery ID.
^whd_[a-f0-9]{32}$Query Parameters
Comma-separated tags for tracking request usage. Up to 20 tags, each 1-50 characters. Optional tags for tracking usage. Up to 20 tags, each 1 to 50 characters.
201 - 50["production", "team-alpha"]
Response
Webhook delivery
Delivery ID.
Webhook event type.
batch.completed, batch.failed, batch.cancelled, change.detected, run.completed Batch or monitor run that produced the event.
- Batch
- Monitor
Show child attributes
Show child attributes
Webhook destination URL.
Current delivery status.
pending, delivering, retrying, delivered, failed, cancelled Event creation time.
Manual retry deadline, seven days after event creation.
Last successful delivery time, or null if never delivered.
Next scheduled attempt, or null if none.
Latest delivery error, or null if none.
Show child attributes
Show child attributes
Stable event ID for deduplicating received webhooks.
Automatic retry settings for this event.
Show child attributes
Show child attributes
{ "delays_seconds": [10, 60, 300, 1800, 7200, 21600, 57600] }
Latest attempt, or null if none.
Show child attributes
Show child attributes
Credit usage, included whenever a valid API key is provided.
Show child attributes
Show child attributes
Was this page helpful?