运行应用(同步接口)
curl --request POST \
--url https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"application_id": "app_abc123",
"inputs": {
"query": "请帮我分析这份采购单"
},
"files": [
{
"url": "https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400",
"name": "采购单.pdf",
"mime_type": "application/pdf"
}
]
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
application_id: 'app_abc123',
inputs: {query: '请帮我分析这份采购单'},
files: [
{
url: 'https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400',
name: '采购单.pdf',
mime_type: 'application/pdf'
}
]
})
};
fetch('https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run"
payload = {
"application_id": "app_abc123",
"inputs": { "query": "请帮我分析这份采购单" },
"files": [
{
"url": "https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400",
"name": "采购单.pdf",
"mime_type": "application/pdf"
}
]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)HttpResponse<String> response = Unirest.post("https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"application_id\": \"app_abc123\",\n \"inputs\": {\n \"query\": \"请帮我分析这份采购单\"\n },\n \"files\": [\n {\n \"url\": \"https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400\",\n \"name\": \"采购单.pdf\",\n \"mime_type\": \"application/pdf\"\n }\n ]\n}")
.asString();const url = 'https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run';
const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
application_id: 'app_abc123',
inputs: {query: '请帮我分析这份采购单'},
files: [
{
url: 'https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400',
name: '采购单.pdf',
mime_type: 'application/pdf'
}
]
})
};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run"
payload := strings.NewReader("{\n \"application_id\": \"app_abc123\",\n \"inputs\": {\n \"query\": \"请帮我分析这份采购单\"\n },\n \"files\": [\n {\n \"url\": \"https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400\",\n \"name\": \"采购单.pdf\",\n \"mime_type\": \"application/pdf\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
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))
}using RestSharp;
var options = new RestClientOptions("https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-API-Key", "<api-key>");
request.AddJsonBody("{\n \"application_id\": \"app_abc123\",\n \"inputs\": {\n \"query\": \"请帮我分析这份采购单\"\n },\n \"files\": [\n {\n \"url\": \"https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400\",\n \"name\": \"采购单.pdf\",\n \"mime_type\": \"application/pdf\"\n }\n ]\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run",
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([
'application_id' => 'app_abc123',
'inputs' => [
'query' => '请帮我分析这份采购单'
],
'files' => [
[
'url' => 'https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400',
'name' => '采购单.pdf',
'mime_type' => 'application/pdf'
]
]
]),
CURLOPT_HTTPHEADER => [
"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;
}{
"code": "success",
"message": "",
"data": {
"run_id": "run_xyz789",
"status": "succeeded",
"output": {
"result": "采购单分析完成"
},
"error": null,
"started_at": "2026-04-30T10:00:00Z",
"ended_at": "2026-04-30T10:00:15Z"
}
}{
"code": "<string>",
"message": "<string>",
"tips": "<string>"
}工作流
运行应用(同步接口)
同步运行工作流应用的发布版本,阻塞等待执行完成后返回结果。
POST
/
open
/
agentic_engine
/
laiye
/
v1
/
app
/
run
运行应用(同步接口)
curl --request POST \
--url https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"application_id": "app_abc123",
"inputs": {
"query": "请帮我分析这份采购单"
},
"files": [
{
"url": "https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400",
"name": "采购单.pdf",
"mime_type": "application/pdf"
}
]
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
application_id: 'app_abc123',
inputs: {query: '请帮我分析这份采购单'},
files: [
{
url: 'https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400',
name: '采购单.pdf',
mime_type: 'application/pdf'
}
]
})
};
fetch('https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run"
payload = {
"application_id": "app_abc123",
"inputs": { "query": "请帮我分析这份采购单" },
"files": [
{
"url": "https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400",
"name": "采购单.pdf",
"mime_type": "application/pdf"
}
]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)HttpResponse<String> response = Unirest.post("https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"application_id\": \"app_abc123\",\n \"inputs\": {\n \"query\": \"请帮我分析这份采购单\"\n },\n \"files\": [\n {\n \"url\": \"https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400\",\n \"name\": \"采购单.pdf\",\n \"mime_type\": \"application/pdf\"\n }\n ]\n}")
.asString();const url = 'https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run';
const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
application_id: 'app_abc123',
inputs: {query: '请帮我分析这份采购单'},
files: [
{
url: 'https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400',
name: '采购单.pdf',
mime_type: 'application/pdf'
}
]
})
};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run"
payload := strings.NewReader("{\n \"application_id\": \"app_abc123\",\n \"inputs\": {\n \"query\": \"请帮我分析这份采购单\"\n },\n \"files\": [\n {\n \"url\": \"https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400\",\n \"name\": \"采购单.pdf\",\n \"mime_type\": \"application/pdf\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
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))
}using RestSharp;
var options = new RestClientOptions("https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-API-Key", "<api-key>");
request.AddJsonBody("{\n \"application_id\": \"app_abc123\",\n \"inputs\": {\n \"query\": \"请帮我分析这份采购单\"\n },\n \"files\": [\n {\n \"url\": \"https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400\",\n \"name\": \"采购单.pdf\",\n \"mime_type\": \"application/pdf\"\n }\n ]\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://adp.laiye.com/open/agentic_engine/laiye/v1/app/run",
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([
'application_id' => 'app_abc123',
'inputs' => [
'query' => '请帮我分析这份采购单'
],
'files' => [
[
'url' => 'https://adp.laiye.com/web/agentic_doc_processor/laiye/file/2003c711818811f1a36200163e358400',
'name' => '采购单.pdf',
'mime_type' => 'application/pdf'
]
]
]),
CURLOPT_HTTPHEADER => [
"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;
}{
"code": "success",
"message": "",
"data": {
"run_id": "run_xyz789",
"status": "succeeded",
"output": {
"result": "采购单分析完成"
},
"error": null,
"started_at": "2026-04-30T10:00:00Z",
"ended_at": "2026-04-30T10:00:15Z"
}
}{
"code": "<string>",
"message": "<string>",
"tips": "<string>"
}授权
工作流智能引擎 API 访问密钥。
请求体
application/json
⌘I
