cURL
curl -X POST "https://app.cotool.ai/api/agent-runs/:runId/deliveries/:deliveryId/resend" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json"import requests
url = "https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));HttpResponse<String> response = Unirest.post("https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend")
.header("Authorization", "Bearer <token>")
.asString();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"delivery": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"runId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turnId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"evalId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"destinationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"destinationType": "webhook",
"destinationName": "<string>",
"destinationDeleted": true,
"purpose": "response",
"status": "pending",
"attempt": 123,
"resendCount": 123,
"preview": {
"text": "<string>",
"title": "<string>"
},
"sentSummary": {
"target": "<string>",
"refs": [
{
"label": "<string>",
"url": "<string>",
"externalId": "<string>"
}
],
"partial": true,
"slackChannels": [
{
"channelId": "<string>",
"status": "sent",
"messageTs": "<string>",
"skipReason": "<string>"
}
]
},
"error": {
"message": "<string>",
"attempt": 123,
"at": "<string>",
"name": "<string>"
},
"lastEnqueuedAt": "<string>",
"startedAt": "<string>",
"sentAt": "<string>",
"failedAt": "<string>",
"attempts": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"number": 123,
"trigger": "initial",
"requestedByUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"jobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"jobAttempt": 123,
"status": "pending",
"error": {
"message": "<string>",
"attempt": 123,
"at": "<string>",
"name": "<string>"
},
"sentSummary": {
"target": "<string>",
"refs": [
{
"label": "<string>",
"url": "<string>",
"externalId": "<string>"
}
],
"partial": true,
"slackChannels": [
{
"channelId": "<string>",
"status": "sent",
"messageTs": "<string>",
"skipReason": "<string>"
}
]
},
"enqueuedAt": "<string>",
"startedAt": "<string>",
"finishedAt": "<string>"
}
],
"createdAt": "<string>",
"updatedAt": "<string>"
}
}{
"error": "<string>",
"issues": [
{}
]
}{
"error": "<string>"
}{
"error": "<string>",
"missingPerms": [
"<string>"
]
}{
"error": "<string>"
}Agent Runs
Resend a failed output delivery or notification
Opens a new attempt for a failed delivery, sending the content the turn and evaluation hold now. Only deliveries in the failed state whose destination still exists can be resent; the send is real and may create a message/incident/issue/case in the destination.
POST
/
api
/
agent-runs
/
{runId}
/
deliveries
/
{deliveryId}
/
resend
cURL
curl -X POST "https://app.cotool.ai/api/agent-runs/:runId/deliveries/:deliveryId/resend" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json"import requests
url = "https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));HttpResponse<String> response = Unirest.post("https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend")
.header("Authorization", "Bearer <token>")
.asString();package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.cotool.ai/api/agent-runs/{runId}/deliveries/{deliveryId}/resend"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"delivery": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"runId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turnId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"evalId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"destinationId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"destinationType": "webhook",
"destinationName": "<string>",
"destinationDeleted": true,
"purpose": "response",
"status": "pending",
"attempt": 123,
"resendCount": 123,
"preview": {
"text": "<string>",
"title": "<string>"
},
"sentSummary": {
"target": "<string>",
"refs": [
{
"label": "<string>",
"url": "<string>",
"externalId": "<string>"
}
],
"partial": true,
"slackChannels": [
{
"channelId": "<string>",
"status": "sent",
"messageTs": "<string>",
"skipReason": "<string>"
}
]
},
"error": {
"message": "<string>",
"attempt": 123,
"at": "<string>",
"name": "<string>"
},
"lastEnqueuedAt": "<string>",
"startedAt": "<string>",
"sentAt": "<string>",
"failedAt": "<string>",
"attempts": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"number": 123,
"trigger": "initial",
"requestedByUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"jobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"jobAttempt": 123,
"status": "pending",
"error": {
"message": "<string>",
"attempt": 123,
"at": "<string>",
"name": "<string>"
},
"sentSummary": {
"target": "<string>",
"refs": [
{
"label": "<string>",
"url": "<string>",
"externalId": "<string>"
}
],
"partial": true,
"slackChannels": [
{
"channelId": "<string>",
"status": "sent",
"messageTs": "<string>",
"skipReason": "<string>"
}
]
},
"enqueuedAt": "<string>",
"startedAt": "<string>",
"finishedAt": "<string>"
}
],
"createdAt": "<string>",
"updatedAt": "<string>"
}
}{
"error": "<string>",
"issues": [
{}
]
}{
"error": "<string>"
}{
"error": "<string>",
"missingPerms": [
"<string>"
]
}{
"error": "<string>"
}Authorizations
API Key authentication for programmatic access. Include your API key in the Authorization header as: Bearer your_api_key_here
Path Parameters
Agent run (chat) ID
Delivery record ID
Response
Successful response
The delivery after its new attempt was queued
Show child attributes
Show child attributes
Was this page helpful?
⌘I