الحصول على التنسيق
curl --request GET \
--url https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId} \
--header 'X-API-Key: <api-key>'const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"orchestration_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workflow_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agents": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"parameters": {},
"status": "pending",
"steps": [
{
"step_id": "<string>",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"action": "<string>",
"status": "<string>",
"result": {},
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z"
}
],
"results": {},
"receipts": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"created_at": "2023-11-07T05:31:56Z"
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}التنسيقات وسير العمل
الحصول على التنسيق
استرداد نتيجة التنفيذ الكاملة للتنسيق، بما في ذلك تفاصيل مستوى الخطوة وتتبع التكلفة.
GET
/
v1
/
orchestrate
/
executions
/
{orchestrationId}
الحصول على التنسيق
curl --request GET \
--url https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId} \
--header 'X-API-Key: <api-key>'const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.truthlocks.com/v1/orchestrate/executions/{orchestrationId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"orchestration_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workflow_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agents": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"parameters": {},
"status": "pending",
"steps": [
{
"step_id": "<string>",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"action": "<string>",
"status": "<string>",
"result": {},
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z"
}
],
"results": {},
"receipts": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"created_at": "2023-11-07T05:31:56Z"
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}يعرض حالة التنفيذ الكاملة للتنسيق، بما في ذلك حالته الحالية، وكل خطوة تم تنفيذها، والمخرجات النهائية، والتكلفة المتراكمة، وإيصال سجل الشفافية بمجرد اكتماله.
استقصاء نقطة النهاية هذه لتتبع تقدم التنسيق. للحصول على تحديثات في الوقت الفعلي، قم بتكوين webhook لأحداث
orchestration.completed و orchestration.failed.
الاستجابة
مصفوفة مرتبة لخطوات التنفيذ. تحتوي كل خطوة على: -
step_number
(عدد صحيح) — فهرس الخطوة المتسلسل (يبدأ من 1) - action (سلسلة نصية) — الإجراء
تم إجراؤه (مثل llm_inference، tool_call، decision، guardrail_check) -
result (سلسلة) — ملخص نتيجة الخطوة - duration_ms (عدد صحيح) — الخطوة
وقت التنفيذ بالمللي ثانية
