Update a specific log in an experiment using the V2 API.
Authentication
- API key:
Authorization: Bearer <API key>
Path Parameters
The ID of the experiment.
The ID of the log to update.
Request Body
{
"output": {
"output": "This is the output of the custom workflow"
}
}
Examples
import requests
experiment_id = "experiment_id_123"
log_id = "log_id_123"
url = f"https://api.keywordsai.co/api/v2/experiments/{experiment_id}/logs/{log_id}"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
}
data = {
"output": {
"output": "This is the output of the custom workflow"
}
}
response = requests.patch(url, headers=headers, json=data)
print(response.json())
Response
{
"id": "log_id_123",
"input": {},
"output": {
"output": "This is the output of the custom workflow"
}
}