mirror of
https://github.com/langgenius/dify.git
synced 2026-04-20 18:57:19 +08:00
Merge remote-tracking branch 'origin/feat/plugins' into dev/plugin-deploy
This commit is contained in:
@ -379,10 +379,107 @@ The text generation application offers non-session support and is ideal for tran
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/text-to-audio'
|
||||
method='POST'
|
||||
title='Text to Audio'
|
||||
name='#audio'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Text to speech.
|
||||
|
||||
### Request Body
|
||||
|
||||
<Properties>
|
||||
<Property name='message_id' type='str' key='text'>
|
||||
For text messages generated by Dify, simply pass the generated message-id directly. The backend will use the message-id to look up the corresponding content and synthesize the voice information directly. If both message_id and text are provided simultaneously, the message_id is given priority.
|
||||
</Property>
|
||||
<Property name='text' type='str' key='text'>
|
||||
Speech generated content。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
The user identifier, defined by the developer, must ensure uniqueness within the app.
|
||||
</Property>
|
||||
</Properties>
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/text-to-audio" targetCode={`curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n "message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",\n "text": "Hello Dify",\n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",
|
||||
"text": "Hello Dify",
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="headers">
|
||||
```json {{ title: 'headers' }}
|
||||
{
|
||||
"Content-Type": "audio/wav"
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='Get Application Basic Information'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Used to get basic information about this application
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
User identifier, defined by the developer's rules, must be unique within the application.
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) application name
|
||||
- `description` (string) application description
|
||||
- `tags` (array[string]) application tags
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='Get Application Information'
|
||||
title='Get Application Parameters Information'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -497,56 +594,3 @@ The text generation application offers non-session support and is ideal for tran
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/text-to-audio'
|
||||
method='POST'
|
||||
title='Text to Audio'
|
||||
name='#audio'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Text to speech.
|
||||
|
||||
### Request Body
|
||||
|
||||
<Properties>
|
||||
<Property name='message_id' type='str' key='text'>
|
||||
For text messages generated by Dify, simply pass the generated message-id directly. The backend will use the message-id to look up the corresponding content and synthesize the voice information directly. If both message_id and text are provided simultaneously, the message_id is given priority.
|
||||
</Property>
|
||||
<Property name='text' type='str' key='text'>
|
||||
Speech generated content。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
The user identifier, defined by the developer, must ensure uniqueness within the app.
|
||||
</Property>
|
||||
</Properties>
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/text-to-audio" targetCode={`curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n "message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",\n "text": "Hello Dify",\n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",
|
||||
"text": "Hello Dify",
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="headers">
|
||||
```json {{ title: 'headers' }}
|
||||
{
|
||||
"Content-Type": "audio/wav"
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
@ -375,13 +375,109 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/text-to-audio'
|
||||
method='POST'
|
||||
title='テキストから音声'
|
||||
name='#audio'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
テキストを音声に変換します。
|
||||
|
||||
### リクエストボディ
|
||||
|
||||
<Properties>
|
||||
<Property name='message_id' type='str' key='text'>
|
||||
Difyが生成したテキストメッセージの場合、生成されたmessage-idを直接渡すだけです。バックエンドはmessage-idを使用して対応するコンテンツを検索し、音声情報を直接合成します。message_idとtextの両方が同時に提供された場合、message_idが優先されます。
|
||||
</Property>
|
||||
<Property name='text' type='str' key='text'>
|
||||
音声生成コンテンツ。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
開発者が定義したユーザー識別子。アプリ内で一意性を確保する必要があります。
|
||||
</Property>
|
||||
</Properties>
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/text-to-audio" targetCode={`curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n "message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",\n "text": "Hello Dify",\n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",
|
||||
"text": "Hello Dify",
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="headers">
|
||||
```json {{ title: 'headers' }}
|
||||
{
|
||||
"Content-Type": "audio/wav"
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='アプリケーションの基本情報を取得'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
このアプリケーションの基本情報を取得するために使用されます
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者のルールによって定義され、アプリケーション内で一意でなければなりません。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) アプリケーションの名前
|
||||
- `description` (string) アプリケーションの説明
|
||||
- `tags` (array[string]) アプリケーションのタグ
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='アプリケーション情報の取得'
|
||||
title='アプリケーションのパラメータ情報を取得'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -496,56 +592,3 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/text-to-audio'
|
||||
method='POST'
|
||||
title='テキストから音声'
|
||||
name='#audio'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
テキストを音声に変換します。
|
||||
|
||||
### リクエストボディ
|
||||
|
||||
<Properties>
|
||||
<Property name='message_id' type='str' key='text'>
|
||||
Difyが生成したテキストメッセージの場合、生成されたmessage-idを直接渡すだけです。バックエンドはmessage-idを使用して対応するコンテンツを検索し、音声情報を直接合成します。message_idとtextの両方が同時に提供された場合、message_idが優先されます。
|
||||
</Property>
|
||||
<Property name='text' type='str' key='text'>
|
||||
音声生成コンテンツ。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
開発者が定義したユーザー識別子。アプリ内で一意性を確保する必要があります。
|
||||
</Property>
|
||||
</Properties>
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/text-to-audio" targetCode={`curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n "message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",\n "text": "Hello Dify",\n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",
|
||||
"text": "Hello Dify",
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="headers">
|
||||
```json {{ title: 'headers' }}
|
||||
{
|
||||
"Content-Type": "audio/wav"
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
@ -353,10 +353,108 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/text-to-audio'
|
||||
method='POST'
|
||||
title='文字转语音'
|
||||
name='#audio'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
文字转语音。
|
||||
|
||||
### Request Body
|
||||
|
||||
<Properties>
|
||||
<Property name='message_id' type='str' key='text'>
|
||||
Dify 生成的文本消息,那么直接传递生成的message-id 即可,后台会通过 message_id 查找相应的内容直接合成语音信息。如果同时传 message_id 和 text,优先使用 message_id。
|
||||
</Property>
|
||||
<Property name='text' type='str' key='text'>
|
||||
语音生成内容。如果没有传 message-id的话,则会使用这个字段的内容
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/text-to-audio" targetCode={`curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n "message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",\n "text": "你好Dify",\n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",
|
||||
"text": "你好Dify",
|
||||
"user": "abc-123",
|
||||
"streaming": false
|
||||
}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="headers">
|
||||
```json {{ title: 'headers' }}
|
||||
{
|
||||
"Content-Type": "audio/wav"
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='获取应用基本信息'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
用于获取应用的基本信息
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) 应用名称
|
||||
- `description` (string) 应用描述
|
||||
- `tags` (array[string]) 应用标签
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='获取应用配置信息'
|
||||
title='获取应用参数'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -461,57 +559,3 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/text-to-audio'
|
||||
method='POST'
|
||||
title='文字转语音'
|
||||
name='#audio'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
文字转语音。
|
||||
|
||||
### Request Body
|
||||
|
||||
<Properties>
|
||||
<Property name='message_id' type='str' key='text'>
|
||||
Dify 生成的文本消息,那么直接传递生成的message-id 即可,后台会通过 message_id 查找相应的内容直接合成语音信息。如果同时传 message_id 和 text,优先使用 message_id。
|
||||
</Property>
|
||||
<Property name='text' type='str' key='text'>
|
||||
语音生成内容。如果没有传 message-id的话,则会使用这个字段的内容
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/text-to-audio" targetCode={`curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n "message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",\n "text": "你好Dify",\n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -o text-to-audio.mp3 -X POST '${props.appDetail.api_base_url}/text-to-audio' \
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"message_id": "5ad4cb98-f0c7-4085-b384-88c403be6290",
|
||||
"text": "你好Dify",
|
||||
"user": "abc-123",
|
||||
"streaming": false
|
||||
}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="headers">
|
||||
```json {{ title: 'headers' }}
|
||||
{
|
||||
"Content-Type": "audio/wav"
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
@ -161,7 +161,7 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
- `title` (string) name of node
|
||||
- `index` (int) Execution sequence number, used to display Tracing Node sequence
|
||||
- `predecessor_node_id` (string) optional Prefix node ID, used for canvas display execution path
|
||||
- `inputs` (array[object]) Contents of all preceding node variables used in the node
|
||||
- `inputs` (object) Contents of all preceding node variables used in the node
|
||||
- `created_at` (timestamp) timestamp of start, e.g., 1705395332
|
||||
- `event: node_finished` node execution ends, success or failure in different states in the same event
|
||||
- `task_id` (string) Task ID, used for request tracking and the below Stop Generate API
|
||||
@ -174,7 +174,7 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
- `title` (string) name of node
|
||||
- `index` (int) Execution sequence number, used to display Tracing Node sequence
|
||||
- `predecessor_node_id` (string) optional Prefix node ID, used for canvas display execution path
|
||||
- `inputs` (array[object]) Contents of all preceding node variables used in the node
|
||||
- `inputs` (object) Contents of all preceding node variables used in the node
|
||||
- `process_data` (json) Optional node process data
|
||||
- `outputs` (json) Optional content of output
|
||||
- `status` (string) status of execution, `running` / `succeeded` / `failed` / `stopped`
|
||||
@ -564,7 +564,7 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
- `data` (array[object]) Message list
|
||||
- `id` (string) Message ID
|
||||
- `conversation_id` (string) Conversation ID
|
||||
- `inputs` (array[object]) User input parameters.
|
||||
- `inputs` (object) User input parameters.
|
||||
- `query` (string) User input / question content.
|
||||
- `message_files` (array[object]) Message files
|
||||
- `id` (string) ID
|
||||
@ -648,16 +648,13 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
Should be uniquely defined by the developer within the application.
|
||||
</Property>
|
||||
<Property name='last_id' type='string' key='last_id'>
|
||||
The ID of the last record on the current page, default is null.
|
||||
(Optional) The ID of the last record on the current page, default is null.
|
||||
</Property>
|
||||
<Property name='limit' type='int' key='limit'>
|
||||
How many records to return in one request, default is the most recent 20 entries.
|
||||
</Property>
|
||||
<Property name='pinned' type='bool' key='pinned'>
|
||||
Return only pinned conversations as `true`, only non-pinned as `false`
|
||||
(Optional) How many records to return in one request, default is the most recent 20 entries. Maximum 100, minimum 1.
|
||||
</Property>
|
||||
<Property name='sort_by' type='string' key='sort_by'>
|
||||
Sorting Field (Optional), Default: -updated_at (sorted in descending order by update time)
|
||||
(Optional) Sorting Field, Default: -updated_at (sorted in descending order by update time)
|
||||
- Available Values: created_at, -created_at, updated_at, -updated_at
|
||||
- The symbol before the field represents the order or reverse, "-" represents reverse order.
|
||||
</Property>
|
||||
@ -667,9 +664,11 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
- `data` (array[object]) List of conversations
|
||||
- `id` (string) Conversation ID
|
||||
- `name` (string) Conversation name, by default, is generated by LLM.
|
||||
- `inputs` (array[object]) User input parameters.
|
||||
- `inputs` (object) User input parameters.
|
||||
- `status` (string) Conversation status
|
||||
- `introduction` (string) Introduction
|
||||
- `created_at` (timestamp) Creation timestamp, e.g., 1705395332
|
||||
- `updated_at` (timestamp) Update timestamp, e.g., 1705395332
|
||||
- `has_more` (bool)
|
||||
- `limit` (int) Number of entries returned, if input exceeds system limit, system limit number is returned
|
||||
|
||||
@ -699,7 +698,8 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
"myName": "Lucy"
|
||||
},
|
||||
"status": "normal",
|
||||
"created_at": 1679667915
|
||||
"created_at": 1679667915,
|
||||
"updated_at": 1679667915
|
||||
},
|
||||
{
|
||||
"id": "hSIhXBhNe8X1d8Et"
|
||||
@ -781,10 +781,10 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
|
||||
<Properties>
|
||||
<Property name='name' type='string' key='name'>
|
||||
The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
|
||||
(Optional) The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
|
||||
</Property>
|
||||
<Property name='auto_generate' type='bool' key='auto_generate'>
|
||||
Automatically generate the title, default is `false`
|
||||
(Optional) Automatically generate the title, default is `false`
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
The user identifier, defined by the developer, must ensure uniqueness within the application.
|
||||
@ -794,13 +794,15 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
### Response
|
||||
- `id` (string) Conversation ID
|
||||
- `name` (string) Conversation name
|
||||
- `inputs` array[object] User input parameters.
|
||||
- `inputs` (object) User input parameters
|
||||
- `status` (string) Conversation status
|
||||
- `introduction` (string) Introduction
|
||||
- `created_at` (timestamp) Creation timestamp, e.g., 1705395332
|
||||
- `updated_at` (timestamp) Update timestamp, e.g., 1705395332
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
|
||||
@ -808,6 +810,7 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--data-raw '{
|
||||
"name": "",
|
||||
"auto_generate": true,
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
@ -820,8 +823,10 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
"id": "cd78daf6-f9e4-4463-9ff2-54257230a0ce",
|
||||
"name": "Chat vs AI",
|
||||
"inputs": {},
|
||||
"status": "normal",
|
||||
"introduction": "",
|
||||
"created_at": 1705569238
|
||||
"created_at": 1705569238,
|
||||
"updated_at": 1705569238
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
@ -931,13 +936,57 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='Get Application Basic Information'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Used to get basic information about this application
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
User identifier, defined by the developer's rules, must be unique within the application.
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) application name
|
||||
- `description` (string) application description
|
||||
- `tags` (array[string]) application tags
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='Get Application Information'
|
||||
title='Get Application Parameters Information'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -1091,14 +1140,14 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"tool_icons": {
|
||||
"tool_icons": {
|
||||
"dalle2": "https://cloud.dify.ai/console/api/workspaces/current/tool-provider/builtin/dalle/icon",
|
||||
"api_tool": {
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
|
||||
@ -161,7 +161,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `title` (string) ノードの名前
|
||||
- `index` (int) 実行シーケンス番号、トレースノードシーケンスを表示するために使用
|
||||
- `predecessor_node_id` (string) オプションのプレフィックスノードID、キャンバス表示実行パスに使用
|
||||
- `inputs` (array[object]) ノードで使用されるすべての前のノード変数の内容
|
||||
- `inputs` (object) ノードで使用されるすべての前のノード変数の内容
|
||||
- `created_at` (timestamp) 開始のタイムスタンプ、例:1705395332
|
||||
- `event: node_finished` ノード実行が終了、成功または失敗は同じイベント内で異なる状態で示されます
|
||||
- `task_id` (string) タスクID、リクエスト追跡と以下のStop Generate APIに使用
|
||||
@ -174,7 +174,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `title` (string) ノードの名前
|
||||
- `index` (int) 実行シーケンス番号、トレースノードシーケンスを表示するために使用
|
||||
- `predecessor_node_id` (string) オプションのプレフィックスノードID、キャンバス表示実行パスに使用
|
||||
- `inputs` (array[object]) ノードで使用されるすべての前のノード変数の内容
|
||||
- `inputs` (object) ノードで使用されるすべての前のノード変数の内容
|
||||
- `process_data` (json) オプションのノードプロセスデータ
|
||||
- `outputs` (json) オプションの出力内容
|
||||
- `status` (string) 実行の状態、`running` / `succeeded` / `failed` / `stopped`
|
||||
@ -564,7 +564,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `data` (array[object]) メッセージリスト
|
||||
- `id` (string) メッセージID
|
||||
- `conversation_id` (string) 会話ID
|
||||
- `inputs` (array[object]) ユーザー入力パラメータ。
|
||||
- `inputs` (object) ユーザー入力パラメータ。
|
||||
- `query` (string) ユーザー入力/質問内容。
|
||||
- `message_files` (array[object]) メッセージファイル
|
||||
- `id` (string) ID
|
||||
@ -648,16 +648,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
アプリケーション内で開発者によって一意に定義されるべきです。
|
||||
</Property>
|
||||
<Property name='last_id' type='string' key='last_id'>
|
||||
現在のページの最後の記録のID、デフォルトはnullです。
|
||||
(Optional)現在のページの最後の記録のID、デフォルトはnullです。
|
||||
</Property>
|
||||
<Property name='limit' type='int' key='limit'>
|
||||
1回のリクエストで返す記録の数、デフォルトは最新の20件です。
|
||||
</Property>
|
||||
<Property name='pinned' type='bool' key='pinned'>
|
||||
ピン留めされた会話のみを`true`として返し、非ピン留めを`false`として返します
|
||||
(Optional)1回のリクエストで返す記録の数、デフォルトは最新の20件です。最大100、最小1。
|
||||
</Property>
|
||||
<Property name='sort_by' type='string' key='sort_by'>
|
||||
ソートフィールド(オプション)、デフォルト:-updated_at(更新時間で降順にソート)
|
||||
(Optional)ソートフィールド、デフォルト:-updated_at(更新時間で降順にソート)
|
||||
- 利用可能な値:created_at, -created_at, updated_at, -updated_at
|
||||
- フィールドの前の記号は順序または逆順を表し、"-"は逆順を表します。
|
||||
</Property>
|
||||
@ -667,9 +664,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `data` (array[object]) 会話のリスト
|
||||
- `id` (string) 会話ID
|
||||
- `name` (string) 会話名、デフォルトではLLMによって生成されます。
|
||||
- `inputs` (array[object]) ユーザー入力パラメータ。
|
||||
- `inputs` (object) ユーザー入力パラメータ。
|
||||
- `introduction` (string) 紹介
|
||||
- `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
|
||||
- `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
|
||||
- `has_more` (bool)
|
||||
- `limit` (int) 返されたエントリ数、入力がシステム制限を超える場合、システム制限数が返されます
|
||||
|
||||
@ -699,7 +697,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
"myName": "Lucy"
|
||||
},
|
||||
"status": "normal",
|
||||
"created_at": 1679667915
|
||||
"created_at": 1679667915,
|
||||
"updated_at": 1679667915
|
||||
},
|
||||
{
|
||||
"id": "hSIhXBhNe8X1d8Et"
|
||||
@ -781,10 +780,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
|
||||
<Properties>
|
||||
<Property name='name' type='string' key='name'>
|
||||
会話の名前。`auto_generate`が`true`に設定されている場合、このパラメータは省略できます。
|
||||
(Optional)会話の名前。`auto_generate`が`true`に設定されている場合、このパラメータは省略できます。
|
||||
</Property>
|
||||
<Property name='auto_generate' type='bool' key='auto_generate'>
|
||||
タイトルを自動生成、デフォルトは`false`
|
||||
(Optional)タイトルを自動生成、デフォルトは`false`
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者によって定義され、アプリケーション内で一意であることを保証しなければなりません。
|
||||
@ -794,13 +793,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
### 応答
|
||||
- `id` (string) 会話ID
|
||||
- `name` (string) 会話名
|
||||
- `inputs` array[object] ユーザー入力パラメータ。
|
||||
- `inputs` (object) ユーザー入力パラメータ
|
||||
- `status` (string) 会話状態
|
||||
- `introduction` (string) 紹介
|
||||
- `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
|
||||
- `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
|
||||
<CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
|
||||
@ -808,6 +809,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--data-raw '{
|
||||
"name": "",
|
||||
"auto_generate": true,
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
@ -820,8 +822,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
"id": "cd78daf6-f9e4-4463-9ff2-54257230a0ce",
|
||||
"name": "チャット vs AI",
|
||||
"inputs": {},
|
||||
"status": "normal",
|
||||
"introduction": "",
|
||||
"created_at": 1705569238
|
||||
"created_at": 1705569238,
|
||||
"updated_at": 1705569238
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
@ -931,13 +935,57 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='アプリケーションの基本情報を取得'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
このアプリケーションの基本情報を取得するために使用されます
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者のルールによって定義され、アプリケーション内で一意でなければなりません。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) アプリケーションの名前
|
||||
- `description` (string) アプリケーションの説明
|
||||
- `tags` (array[string]) アプリケーションのタグ
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='アプリケーション情報を取得'
|
||||
title='アプリケーションのパラメータ情報を取得'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -1057,7 +1105,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
<Heading
|
||||
url='/meta'
|
||||
method='GET'
|
||||
title='アプリケーションメタ情報を取得'
|
||||
title='アプリケーションのメタ情報を取得'
|
||||
name='#meta'
|
||||
/>
|
||||
<Row>
|
||||
@ -1091,14 +1139,14 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
<CodeGroup title="応答">
|
||||
```json {{ title: '応答' }}
|
||||
{
|
||||
"tool_icons": {
|
||||
"tool_icons": {
|
||||
"dalle2": "https://cloud.dify.ai/console/api/workspaces/current/tool-provider/builtin/dalle/icon",
|
||||
"api_tool": {
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
|
||||
@ -162,7 +162,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
- `title` (string) 节点名称
|
||||
- `index` (int) 执行序号,用于展示 Tracing Node 顺序
|
||||
- `predecessor_node_id` (string) 前置节点 ID,用于画布展示执行路径
|
||||
- `inputs` (array[object]) 节点中所有使用到的前置节点变量内容
|
||||
- `inputs` (object) 节点中所有使用到的前置节点变量内容
|
||||
- `created_at` (timestamp) 开始时间
|
||||
- `event: node_finished` node 执行结束,成功失败同一事件中不同状态
|
||||
- `task_id` (string) 任务 ID,用于请求跟踪和下方的停止响应接口
|
||||
@ -173,7 +173,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
- `node_id` (string) 节点 ID
|
||||
- `index` (int) 执行序号,用于展示 Tracing Node 顺序
|
||||
- `predecessor_node_id` (string) optional 前置节点 ID,用于画布展示执行路径
|
||||
- `inputs` (array[object]) 节点中所有使用到的前置节点变量内容
|
||||
- `inputs` (object) 节点中所有使用到的前置节点变量内容
|
||||
- `process_data` (json) Optional 节点过程数据
|
||||
- `outputs` (json) Optional 输出内容
|
||||
- `status` (string) 执行状态 `running` / `succeeded` / `failed` / `stopped`
|
||||
@ -570,7 +570,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
- `data` (array[object]) 消息列表
|
||||
- `id` (string) 消息 ID
|
||||
- `conversation_id` (string) 会话 ID
|
||||
- `inputs` (array[object]) 用户输入参数。
|
||||
- `inputs` (object) 用户输入参数。
|
||||
- `query` (string) 用户输入 / 提问内容。
|
||||
- `message_files` (array[object]) 消息文件
|
||||
- `id` (string) ID
|
||||
@ -683,16 +683,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
<Property name='last_id' type='string' key='last_id'>
|
||||
当前页最后面一条记录的 ID,默认 null
|
||||
(选填)当前页最后面一条记录的 ID,默认 null
|
||||
</Property>
|
||||
<Property name='limit' type='int' key='limit'>
|
||||
一次请求返回多少条记录
|
||||
</Property>
|
||||
<Property name='pinned' type='bool' key='pinned'>
|
||||
只返回置顶 true,只返回非置顶 false
|
||||
(选填)一次请求返回多少条记录,默认 20 条,最大 100 条,最小 1 条。
|
||||
</Property>
|
||||
<Property name='sort_by' type='string' key='sort_by'>
|
||||
排序字段(选题),默认 -updated_at(按更新时间倒序排列)
|
||||
(选填)排序字段,默认 -updated_at(按更新时间倒序排列)
|
||||
- 可选值:created_at, -created_at, updated_at, -updated_at
|
||||
- 字段前面的符号代表顺序或倒序,-代表倒序
|
||||
</Property>
|
||||
@ -702,9 +699,11 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
- `data` (array[object]) 会话列表
|
||||
- `id` (string) 会话 ID
|
||||
- `name` (string) 会话名称,默认由大语言模型生成。
|
||||
- `inputs` (array[object]) 用户输入参数。
|
||||
- `inputs` (object) 用户输入参数。
|
||||
- `status` (string) 会话状态
|
||||
- `introduction` (string) 开场白
|
||||
- `created_at` (timestamp) 创建时间
|
||||
- `updated_at` (timestamp) 更新时间
|
||||
- `has_more` (bool)
|
||||
- `limit` (int) 返回条数,若传入超过系统限制,返回系统限制数量
|
||||
|
||||
@ -734,7 +733,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
"myName": "Lucy"
|
||||
},
|
||||
"status": "normal",
|
||||
"created_at": 1679667915
|
||||
"created_at": 1679667915,
|
||||
"updated_at": 1679667915
|
||||
},
|
||||
{
|
||||
"id": "hSIhXBhNe8X1d8Et"
|
||||
@ -817,10 +817,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
|
||||
<Properties>
|
||||
<Property name='name' type='string' key='name'>
|
||||
名称,若 `auto_generate` 为 `true` 时,该参数可不传。
|
||||
(选填)名称,若 `auto_generate` 为 `true` 时,该参数可不传。
|
||||
</Property>
|
||||
<Property name='auto_generate' type='string' key='auto_generate'>
|
||||
自动生成标题,默认 false。
|
||||
<Property name='auto_generate' type='bool' key='auto_generate'>
|
||||
(选填)自动生成标题,默认 false。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
@ -830,13 +830,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
### Response
|
||||
- `id` (string) 会话 ID
|
||||
- `name` (string) 会话名称
|
||||
- `inputs` array[object] 用户输入参数。
|
||||
- `inputs` (object) 用户输入参数
|
||||
- `status` (string) 会话状态
|
||||
- `introduction` (string) 开场白
|
||||
- `created_at` (timestamp) 创建时间
|
||||
- `updated_at` (timestamp) 更新时间
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
|
||||
@ -844,6 +846,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"name": "",
|
||||
"auto_generate": true,
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
@ -853,7 +856,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"result": "success"
|
||||
"id": "34d511d5-56de-4f16-a997-57b379508443",
|
||||
"name": "hello",
|
||||
"inputs": {},
|
||||
"status": "normal",
|
||||
"introduction": "",
|
||||
"created_at": 1732731141,
|
||||
"updated_at": 1732734510
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
@ -960,13 +969,57 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='获取应用基本信息'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
用于获取应用的基本信息
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) 应用名称
|
||||
- `description` (string) 应用描述
|
||||
- `tags` (array[string]) 应用标签
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='获取应用配置信息'
|
||||
title='获取应用参数'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
|
||||
@ -528,7 +528,7 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
- `data` (array[object]) Message list
|
||||
- `id` (string) Message ID
|
||||
- `conversation_id` (string) Conversation ID
|
||||
- `inputs` (array[object]) User input parameters.
|
||||
- `inputs` (object) User input parameters.
|
||||
- `query` (string) User input / question content.
|
||||
- `message_files` (array[object]) Message files
|
||||
- `id` (string) ID
|
||||
@ -682,16 +682,13 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
Should be uniquely defined by the developer within the application.
|
||||
</Property>
|
||||
<Property name='last_id' type='string' key='last_id'>
|
||||
The ID of the last record on the current page, default is null.
|
||||
(Optional) The ID of the last record on the current page, default is null.
|
||||
</Property>
|
||||
<Property name='limit' type='int' key='limit'>
|
||||
How many records to return in one request, default is the most recent 20 entries.
|
||||
</Property>
|
||||
<Property name='pinned' type='bool' key='pinned'>
|
||||
Return only pinned conversations as `true`, only non-pinned as `false`
|
||||
(Optional) How many records to return in one request, default is the most recent 20 entries. Maximum 100, minimum 1.
|
||||
</Property>
|
||||
<Property name='sort_by' type='string' key='sort_by'>
|
||||
Sorting Field (Optional), Default: -updated_at (sorted in descending order by update time)
|
||||
(Optional) Sorting Field, Default: -updated_at (sorted in descending order by update time)
|
||||
- Available Values: created_at, -created_at, updated_at, -updated_at
|
||||
- The symbol before the field represents the order or reverse, "-" represents reverse order.
|
||||
</Property>
|
||||
@ -701,9 +698,11 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
- `data` (array[object]) List of conversations
|
||||
- `id` (string) Conversation ID
|
||||
- `name` (string) Conversation name, by default, is a snippet of the first question asked by the user in the conversation.
|
||||
- `inputs` (array[object]) User input parameters.
|
||||
- `inputs` (object) User input parameters.
|
||||
- `status` (string) Conversation status
|
||||
- `introduction` (string) Introduction
|
||||
- `created_at` (timestamp) Creation timestamp, e.g., 1705395332
|
||||
- `updated_at` (timestamp) Update timestamp, e.g., 1705395332
|
||||
- `has_more` (bool)
|
||||
- `limit` (int) Number of entries returned, if input exceeds system limit, system limit number is returned
|
||||
|
||||
@ -733,7 +732,8 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
"myName": "Lucy"
|
||||
},
|
||||
"status": "normal",
|
||||
"created_at": 1679667915
|
||||
"created_at": 1679667915,
|
||||
"updated_at": 1679667915
|
||||
},
|
||||
{
|
||||
"id": "hSIhXBhNe8X1d8Et"
|
||||
@ -815,10 +815,10 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
|
||||
<Properties>
|
||||
<Property name='name' type='string' key='name'>
|
||||
The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
|
||||
(Optional) The name of the conversation. This parameter can be omitted if `auto_generate` is set to `true`.
|
||||
</Property>
|
||||
<Property name='auto_generate' type='bool' key='auto_generate'>
|
||||
Automatically generate the title, default is `false`
|
||||
(Optional) Automatically generate the title, default is `false`
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
The user identifier, defined by the developer, must ensure uniqueness within the application.
|
||||
@ -828,13 +828,15 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
### Response
|
||||
- `id` (string) Conversation ID
|
||||
- `name` (string) Conversation name
|
||||
- `inputs` array[object] User input parameters.
|
||||
- `inputs` (object) User input parameters
|
||||
- `status` (string) Conversation status
|
||||
- `introduction` (string) Introduction
|
||||
- `created_at` (timestamp) Creation timestamp, e.g., 1705395332
|
||||
- `updated_at` (timestamp) Update timestamp, e.g., 1705395332
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
|
||||
@ -842,6 +844,7 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--data-raw '{
|
||||
"name": "",
|
||||
"auto_generate": true,
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
@ -854,8 +857,10 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
"id": "cd78daf6-f9e4-4463-9ff2-54257230a0ce",
|
||||
"name": "Chat vs AI",
|
||||
"inputs": {},
|
||||
"status": "normal",
|
||||
"introduction": "",
|
||||
"created_at": 1705569238
|
||||
"created_at": 1705569238,
|
||||
"updated_at": 1705569238
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
@ -960,13 +965,57 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='Get Application Basic Information'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Used to get basic information about this application
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
User identifier, defined by the developer's rules, must be unique within the application.
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) application name
|
||||
- `description` (string) application description
|
||||
- `tags` (array[string]) application tags
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='Get Application Information'
|
||||
title='Get Application Parameters Information'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -1120,14 +1169,14 @@ Chat applications support session persistence, allowing previous chat history to
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"tool_icons": {
|
||||
"tool_icons": {
|
||||
"dalle2": "https://cloud.dify.ai/console/api/workspaces/current/tool-provider/builtin/dalle/icon",
|
||||
"api_tool": {
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
|
||||
@ -528,7 +528,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `data` (array[object]) メッセージリスト
|
||||
- `id` (string) メッセージID
|
||||
- `conversation_id` (string) 会話ID
|
||||
- `inputs` (array[object]) ユーザー入力パラメータ。
|
||||
- `inputs` (object) ユーザー入力パラメータ。
|
||||
- `query` (string) ユーザー入力/質問内容。
|
||||
- `message_files` (array[object]) メッセージファイル
|
||||
- `id` (string) ID
|
||||
@ -682,16 +682,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
アプリケーション内で開発者によって一意に定義される必要があります。
|
||||
</Property>
|
||||
<Property name='last_id' type='string' key='last_id'>
|
||||
現在のページの最後のレコードのID、デフォルトはnullです。
|
||||
(Optional)現在のページの最後のレコードのID、デフォルトはnullです。
|
||||
</Property>
|
||||
<Property name='limit' type='int' key='limit'>
|
||||
1回のリクエストで返すレコードの数、デフォルトは最新の20件です。
|
||||
</Property>
|
||||
<Property name='pinned' type='bool' key='pinned'>
|
||||
ピン留めされた会話のみを`true`として返し、ピン留めされていないもののみを`false`として返します
|
||||
(Optional)1回のリクエストで返すレコードの数、デフォルトは最新の20件です。最大100、最小1。
|
||||
</Property>
|
||||
<Property name='sort_by' type='string' key='sort_by'>
|
||||
ソートフィールド(オプション)、デフォルト:-updated_at(更新時間で降順にソート)
|
||||
(Optional)ソートフィールド、デフォルト:-updated_at(更新時間で降順にソート)
|
||||
- 利用可能な値:created_at, -created_at, updated_at, -updated_at
|
||||
- フィールドの前の記号は順序または逆順を表し、"-"は逆順を表します。
|
||||
</Property>
|
||||
@ -701,9 +698,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `data` (array[object]) 会話のリスト
|
||||
- `id` (string) 会話ID
|
||||
- `name` (string) 会話名、デフォルトでは、ユーザーが会話で最初に尋ねた質問のスニペットです。
|
||||
- `inputs` (array[object]) ユーザー入力パラメータ。
|
||||
- `inputs` (object) ユーザー入力パラメータ。
|
||||
- `introduction` (string) 紹介
|
||||
- `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
|
||||
- `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
|
||||
- `has_more` (bool)
|
||||
- `limit` (int) 返されたエントリの数、入力がシステム制限を超える場合、システム制限の数を返します
|
||||
|
||||
@ -733,7 +731,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
"myName": "Lucy"
|
||||
},
|
||||
"status": "normal",
|
||||
"created_at": 1679667915
|
||||
"created_at": 1679667915,
|
||||
"updated_at": 1679667915
|
||||
},
|
||||
{
|
||||
"id": "hSIhXBhNe8X1d8Et"
|
||||
@ -815,10 +814,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
|
||||
<Properties>
|
||||
<Property name='name' type='string' key='name'>
|
||||
会話の名前。このパラメータは、`auto_generate`が`true`に設定されている場合、省略できます。
|
||||
(Optional)会話の名前。このパラメータは、`auto_generate`が`true`に設定されている場合、省略できます。
|
||||
</Property>
|
||||
<Property name='auto_generate' type='bool' key='auto_generate'>
|
||||
タイトルを自動生成します。デフォルトは`false`です。
|
||||
(Optional)タイトルを自動生成します。デフォルトは`false`です。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者によって定義され、アプリケーション内で一意である必要があります。
|
||||
@ -828,13 +827,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
### 応答
|
||||
- `id` (string) 会話ID
|
||||
- `name` (string) 会話名
|
||||
- `inputs` array[object] ユーザー入力パラメータ。
|
||||
- `inputs` (object) ユーザー入力パラメータ
|
||||
- `status` (string) 会話状態
|
||||
- `introduction` (string) 紹介
|
||||
- `created_at` (timestamp) 作成タイムスタンプ、例:1705395332
|
||||
- `updated_at` (timestamp) 更新タイムスタンプ、例:1705395332
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
|
||||
<CodeGroup title="リクエスト" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
|
||||
@ -842,6 +843,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
--header 'Authorization: Bearer {api_key}' \
|
||||
--data-raw '{
|
||||
"name": "",
|
||||
"auto_generate": true,
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
@ -855,7 +857,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
"name": "Chat vs AI",
|
||||
"inputs": {},
|
||||
"introduction": "",
|
||||
"created_at": 1705569238
|
||||
"created_at": 1705569238,
|
||||
"updated_at": 1705569238
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
@ -960,13 +963,57 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='アプリケーションの基本情報を取得'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
このアプリケーションの基本情報を取得するために使用されます
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者のルールによって定義され、アプリケーション内で一意でなければなりません。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) アプリケーションの名前
|
||||
- `description` (string) アプリケーションの説明
|
||||
- `tags` (array[string]) アプリケーションのタグ
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='アプリケーション情報を取得'
|
||||
title='アプリケーションのパラメータ情報を取得'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
@ -1086,7 +1133,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
<Heading
|
||||
url='/meta'
|
||||
method='GET'
|
||||
title='アプリケーションメタ情報を取得'
|
||||
title='アプリケーションのメタ情報を取得'
|
||||
name='#meta'
|
||||
/>
|
||||
<Row>
|
||||
@ -1120,14 +1167,14 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
<CodeGroup title="応答">
|
||||
```json {{ title: '応答' }}
|
||||
{
|
||||
"tool_icons": {
|
||||
"tool_icons": {
|
||||
"dalle2": "https://cloud.dify.ai/console/api/workspaces/current/tool-provider/builtin/dalle/icon",
|
||||
"api_tool": {
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
"background": "#252525",
|
||||
"content": "\ud83d\ude01"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
|
||||
@ -543,7 +543,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
- `data` (array[object]) 消息列表
|
||||
- `id` (string) 消息 ID
|
||||
- `conversation_id` (string) 会话 ID
|
||||
- `inputs` (array[object]) 用户输入参数。
|
||||
- `inputs` (object) 用户输入参数。
|
||||
- `query` (string) 用户输入 / 提问内容。
|
||||
- `message_files` (array[object]) 消息文件
|
||||
- `id` (string) ID
|
||||
@ -697,16 +697,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
<Property name='last_id' type='string' key='last_id'>
|
||||
当前页最后面一条记录的 ID,默认 null
|
||||
(选填)当前页最后面一条记录的 ID,默认 null
|
||||
</Property>
|
||||
<Property name='limit' type='int' key='limit'>
|
||||
一次请求返回多少条记录
|
||||
</Property>
|
||||
<Property name='pinned' type='bool' key='pinned'>
|
||||
只返回置顶 true,只返回非置顶 false
|
||||
(选填)一次请求返回多少条记录,默认 20 条,最大 100 条,最小 1 条。
|
||||
</Property>
|
||||
<Property name='sort_by' type='string' key='sort_by'>
|
||||
排序字段(选题),默认 -updated_at(按更新时间倒序排列)
|
||||
(选填)排序字段,默认 -updated_at(按更新时间倒序排列)
|
||||
- 可选值:created_at, -created_at, updated_at, -updated_at
|
||||
- 字段前面的符号代表顺序或倒序,-代表倒序
|
||||
</Property>
|
||||
@ -716,9 +713,11 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
- `data` (array[object]) 会话列表
|
||||
- `id` (string) 会话 ID
|
||||
- `name` (string) 会话名称,默认为会话中用户最开始问题的截取。
|
||||
- `inputs` (array[object]) 用户输入参数。
|
||||
- `inputs` (object) 用户输入参数。
|
||||
- `status` (string) 会话状态
|
||||
- `introduction` (string) 开场白
|
||||
- `created_at` (timestamp) 创建时间
|
||||
- `updated_at` (timestamp) 更新时间
|
||||
- `has_more` (bool)
|
||||
- `limit` (int) 返回条数,若传入超过系统限制,返回系统限制数量
|
||||
|
||||
@ -748,7 +747,8 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
"myName": "Lucy"
|
||||
},
|
||||
"status": "normal",
|
||||
"created_at": 1679667915
|
||||
"created_at": 1679667915,
|
||||
"updated_at": 1679667915
|
||||
},
|
||||
{
|
||||
"id": "hSIhXBhNe8X1d8Et"
|
||||
@ -831,10 +831,10 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
|
||||
<Properties>
|
||||
<Property name='name' type='string' key='name'>
|
||||
名称,若 `auto_generate` 为 `true` 时,该参数可不传。
|
||||
(选填)名称,若 `auto_generate` 为 `true` 时,该参数可不传。
|
||||
</Property>
|
||||
<Property name='auto_generate' type='string' key='auto_generate'>
|
||||
自动生成标题,默认 false。
|
||||
<Property name='auto_generate' type='bool' key='auto_generate'>
|
||||
(选填)自动生成标题,默认 false。
|
||||
</Property>
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
@ -844,13 +844,15 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
### Response
|
||||
- `id` (string) 会话 ID
|
||||
- `name` (string) 会话名称
|
||||
- `inputs` array[object] 用户输入参数。
|
||||
- `inputs` (object) 用户输入参数
|
||||
- `status` (string) 会话状态
|
||||
- `introduction` (string) 开场白
|
||||
- `created_at` (timestamp) 创建时间
|
||||
- `updated_at` (timestamp) 更新时间
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "user": "abc-123"\n}'`}>
|
||||
<CodeGroup title="Request" tag="POST" label="/conversations/:conversation_id/name" targetCode={`curl -X POST '${props.appDetail.api_base_url}/conversations/:conversation_id/name' \\\n--header 'Authorization: Bearer {api_key}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{ \n "name": "", \n "auto_generate": true, \n "user": "abc-123"\n}'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X POST '${props.appDetail.api_base_url}/conversations/{conversation_id}/name' \
|
||||
@ -858,6 +860,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
--header 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"name": "",
|
||||
"auto_generate": true,
|
||||
"user": "abc-123"
|
||||
}'
|
||||
```
|
||||
@ -867,7 +870,13 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"result": "success"
|
||||
"id": "34d511d5-56de-4f16-a997-57b379508443",
|
||||
"name": "hello",
|
||||
"inputs": {},
|
||||
"status": "normal",
|
||||
"introduction": "",
|
||||
"created_at": 1732731141,
|
||||
"updated_at": 1732734510
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
@ -969,13 +978,57 @@ import { Row, Col, Properties, Property, Heading, SubProperty } from '../md.tsx'
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='获取应用基本信息'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
用于获取应用的基本信息
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) 应用名称
|
||||
- `description` (string) 应用描述
|
||||
- `tags` (array[string]) 应用标签
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='获取应用配置信息'
|
||||
title='获取应用参数'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
|
||||
@ -113,7 +113,7 @@ Workflow applications offers non-session support and is ideal for translation, a
|
||||
- `title` (string) name of node
|
||||
- `index` (int) Execution sequence number, used to display Tracing Node sequence
|
||||
- `predecessor_node_id` (string) optional Prefix node ID, used for canvas display execution path
|
||||
- `inputs` (array[object]) Contents of all preceding node variables used in the node
|
||||
- `inputs` (object) Contents of all preceding node variables used in the node
|
||||
- `created_at` (timestamp) timestamp of start, e.g., 1705395332
|
||||
- `event: node_finished` node execution ends, success or failure in different states in the same event
|
||||
- `task_id` (string) Task ID, used for request tracking and the below Stop Generate API
|
||||
@ -126,7 +126,7 @@ Workflow applications offers non-session support and is ideal for translation, a
|
||||
- `title` (string) name of node
|
||||
- `index` (int) Execution sequence number, used to display Tracing Node sequence
|
||||
- `predecessor_node_id` (string) optional Prefix node ID, used for canvas display execution path
|
||||
- `inputs` (array[object]) Contents of all preceding node variables used in the node
|
||||
- `inputs` (object) Contents of all preceding node variables used in the node
|
||||
- `process_data` (json) Optional node process data
|
||||
- `outputs` (json) Optional content of output
|
||||
- `status` (string) status of execution, `running` / `succeeded` / `failed` / `stopped`
|
||||
@ -498,104 +498,6 @@ Workflow applications offers non-session support and is ideal for translation, a
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='Get Application Information'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Used at the start of entering the page to obtain information such as features, input parameter names, types, and default values.
|
||||
|
||||
### Query
|
||||
|
||||
<Properties>
|
||||
<Property name='user' type='string' key='user'>
|
||||
User identifier, defined by the developer's rules, must be unique within the application.
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
### Response
|
||||
- `user_input_form` (array[object]) User input form configuration
|
||||
- `text-input` (object) Text input control
|
||||
- `label` (string) Variable display label name
|
||||
- `variable` (string) Variable ID
|
||||
- `required` (bool) Whether it is required
|
||||
- `default` (string) Default value
|
||||
- `paragraph` (object) Paragraph text input control
|
||||
- `label` (string) Variable display label name
|
||||
- `variable` (string) Variable ID
|
||||
- `required` (bool) Whether it is required
|
||||
- `default` (string) Default value
|
||||
- `select` (object) Dropdown control
|
||||
- `label` (string) Variable display label name
|
||||
- `variable` (string) Variable ID
|
||||
- `required` (bool) Whether it is required
|
||||
- `default` (string) Default value
|
||||
- `options` (array[string]) Option values
|
||||
- `file_upload` (object) File upload configuration
|
||||
- `image` (object) Image settings
|
||||
Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`
|
||||
- `enabled` (bool) Whether it is enabled
|
||||
- `number_limits` (int) Image number limit, default is 3
|
||||
- `transfer_methods` (array[string]) List of transfer methods, remote_url, local_file, must choose one
|
||||
- `system_parameters` (object) System parameters
|
||||
- `file_size_limit` (int) Document upload size limit (MB)
|
||||
- `image_file_size_limit` (int) Image file upload size limit (MB)
|
||||
- `audio_file_size_limit` (int) Audio file upload size limit (MB)
|
||||
- `video_file_size_limit` (int) Video file upload size limit (MB)
|
||||
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="GET" label="/parameters" targetCode={` curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123' \
|
||||
--header 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"user_input_form": [
|
||||
{
|
||||
"paragraph": {
|
||||
"label": "Query",
|
||||
"variable": "query",
|
||||
"required": true,
|
||||
"default": ""
|
||||
}
|
||||
}
|
||||
],
|
||||
"file_upload": {
|
||||
"image": {
|
||||
"enabled": false,
|
||||
"number_limits": 3,
|
||||
"detail": "high",
|
||||
"transfer_methods": [
|
||||
"remote_url",
|
||||
"local_file"
|
||||
]
|
||||
}
|
||||
},
|
||||
"system_parameters": {
|
||||
"file_size_limit": 15,
|
||||
"image_file_size_limit": 10,
|
||||
"audio_file_size_limit": 50,
|
||||
"video_file_size_limit": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/workflows/logs'
|
||||
method='GET'
|
||||
@ -699,3 +601,145 @@ Workflow applications offers non-session support and is ideal for translation, a
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='Get Application Basic Information'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Used to get basic information about this application
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
User identifier, defined by the developer's rules, must be unique within the application.
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) application name
|
||||
- `description` (string) application description
|
||||
- `tags` (array[string]) application tags
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='Get Application Parameters Information'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
Used at the start of entering the page to obtain information such as features, input parameter names, types, and default values.
|
||||
|
||||
### Query
|
||||
|
||||
<Properties>
|
||||
<Property name='user' type='string' key='user'>
|
||||
User identifier, defined by the developer's rules, must be unique within the application.
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
### Response
|
||||
- `user_input_form` (array[object]) User input form configuration
|
||||
- `text-input` (object) Text input control
|
||||
- `label` (string) Variable display label name
|
||||
- `variable` (string) Variable ID
|
||||
- `required` (bool) Whether it is required
|
||||
- `default` (string) Default value
|
||||
- `paragraph` (object) Paragraph text input control
|
||||
- `label` (string) Variable display label name
|
||||
- `variable` (string) Variable ID
|
||||
- `required` (bool) Whether it is required
|
||||
- `default` (string) Default value
|
||||
- `select` (object) Dropdown control
|
||||
- `label` (string) Variable display label name
|
||||
- `variable` (string) Variable ID
|
||||
- `required` (bool) Whether it is required
|
||||
- `default` (string) Default value
|
||||
- `options` (array[string]) Option values
|
||||
- `file_upload` (object) File upload configuration
|
||||
- `image` (object) Image settings
|
||||
Currently only supports image types: `png`, `jpg`, `jpeg`, `webp`, `gif`
|
||||
- `enabled` (bool) Whether it is enabled
|
||||
- `number_limits` (int) Image number limit, default is 3
|
||||
- `transfer_methods` (array[string]) List of transfer methods, remote_url, local_file, must choose one
|
||||
- `system_parameters` (object) System parameters
|
||||
- `file_size_limit` (int) Document upload size limit (MB)
|
||||
- `image_file_size_limit` (int) Image file upload size limit (MB)
|
||||
- `audio_file_size_limit` (int) Audio file upload size limit (MB)
|
||||
- `video_file_size_limit` (int) Video file upload size limit (MB)
|
||||
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="GET" label="/parameters" targetCode={` curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123' \
|
||||
--header 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"user_input_form": [
|
||||
{
|
||||
"paragraph": {
|
||||
"label": "Query",
|
||||
"variable": "query",
|
||||
"required": true,
|
||||
"default": ""
|
||||
}
|
||||
}
|
||||
],
|
||||
"file_upload": {
|
||||
"image": {
|
||||
"enabled": false,
|
||||
"number_limits": 3,
|
||||
"detail": "high",
|
||||
"transfer_methods": [
|
||||
"remote_url",
|
||||
"local_file"
|
||||
]
|
||||
}
|
||||
},
|
||||
"system_parameters": {
|
||||
"file_size_limit": 15,
|
||||
"image_file_size_limit": 10,
|
||||
"audio_file_size_limit": 50,
|
||||
"video_file_size_limit": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
@ -113,7 +113,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `title` (string) ノードの名前
|
||||
- `index` (int) 実行シーケンス番号、トレースノードシーケンスを表示するために使用
|
||||
- `predecessor_node_id` (string) オプションのプレフィックスノードID、キャンバス表示実行パスに使用
|
||||
- `inputs` (array[object]) ノードで使用されるすべての前のノード変数の内容
|
||||
- `inputs` (object) ノードで使用されるすべての前のノード変数の内容
|
||||
- `created_at` (timestamp) 開始のタイムスタンプ、例:1705395332
|
||||
- `event: node_finished` ノード実行終了、同じイベントで異なる状態で成功または失敗
|
||||
- `task_id` (string) タスクID、リクエスト追跡と以下のStop Generate APIに使用
|
||||
@ -126,7 +126,7 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
- `title` (string) ノードの名前
|
||||
- `index` (int) 実行シーケンス番号、トレースノードシーケンスを表示するために使用
|
||||
- `predecessor_node_id` (string) オプションのプレフィックスノードID、キャンバス表示実行パスに使用
|
||||
- `inputs` (array[object]) ノードで使用されるすべての前のノード変数の内容
|
||||
- `inputs` (object) ノードで使用されるすべての前のノード変数の内容
|
||||
- `process_data` (json) オプションのノードプロセスデータ
|
||||
- `outputs` (json) オプションの出力内容
|
||||
- `status` (string) 実行のステータス、`running` / `succeeded` / `failed` / `stopped`
|
||||
@ -498,104 +498,6 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='アプリケーション情報を取得'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
ページに入る際に、機能、入力パラメータ名、タイプ、デフォルト値などの情報を取得するために使用されます。
|
||||
|
||||
### クエリ
|
||||
|
||||
<Properties>
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者のルールで定義され、アプリケーション内で一意でなければなりません。
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
### 応答
|
||||
- `user_input_form` (array[object]) ユーザー入力フォームの設定
|
||||
- `text-input` (object) テキスト入力コントロール
|
||||
- `label` (string) 変数表示ラベル名
|
||||
- `variable` (string) 変数ID
|
||||
- `required` (bool) 必須かどうか
|
||||
- `default` (string) デフォルト値
|
||||
- `paragraph` (object) 段落テキスト入力コントロール
|
||||
- `label` (string) 変数表示ラベル名
|
||||
- `variable` (string) 変数ID
|
||||
- `required` (bool) 必須かどうか
|
||||
- `default` (string) デフォルト値
|
||||
- `select` (object) ドロップダウンコントロール
|
||||
- `label` (string) 変数表示ラベル名
|
||||
- `variable` (string) 変数ID
|
||||
- `required` (bool) 必須かどうか
|
||||
- `default` (string) デフォルト値
|
||||
- `options` (array[string]) オプション値
|
||||
- `file_upload` (object) ファイルアップロード設定
|
||||
- `image` (object) 画像設定
|
||||
現在サポートされている画像タイプのみ:`png`, `jpg`, `jpeg`, `webp`, `gif`
|
||||
- `enabled` (bool) 有効かどうか
|
||||
- `number_limits` (int) 画像数の制限、デフォルトは3
|
||||
- `transfer_methods` (array[string]) 転送方法のリスト、remote_url, local_file、いずれかを選択する必要があります
|
||||
- `system_parameters` (object) システムパラメータ
|
||||
- `file_size_limit` (int) ドキュメントアップロードサイズ制限(MB)
|
||||
- `image_file_size_limit` (int) 画像ファイルアップロードサイズ制限(MB)
|
||||
- `audio_file_size_limit` (int) オーディオファイルアップロードサイズ制限(MB)
|
||||
- `video_file_size_limit` (int) ビデオファイルアップロードサイズ制限(MB)
|
||||
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="リクエスト" tag="GET" label="/parameters" targetCode={` curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123' \
|
||||
--header 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="応答">
|
||||
```json {{ title: '応答' }}
|
||||
{
|
||||
"user_input_form": [
|
||||
{
|
||||
"paragraph": {
|
||||
"label": "Query",
|
||||
"variable": "query",
|
||||
"required": true,
|
||||
"default": ""
|
||||
}
|
||||
}
|
||||
],
|
||||
"file_upload": {
|
||||
"image": {
|
||||
"enabled": false,
|
||||
"number_limits": 3,
|
||||
"detail": "high",
|
||||
"transfer_methods": [
|
||||
"remote_url",
|
||||
"local_file"
|
||||
]
|
||||
}
|
||||
},
|
||||
"system_parameters": {
|
||||
"file_size_limit": 15,
|
||||
"image_file_size_limit": 10,
|
||||
"audio_file_size_limit": 50,
|
||||
"video_file_size_limit": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/workflows/logs'
|
||||
method='GET'
|
||||
@ -699,3 +601,145 @@ import { Row, Col, Properties, Property, Heading, SubProperty, Paragraph } from
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='アプリケーションの基本情報を取得'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
このアプリケーションの基本情報を取得するために使用されます
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者のルールによって定義され、アプリケーション内で一意でなければなりません。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) アプリケーションの名前
|
||||
- `description` (string) アプリケーションの説明
|
||||
- `tags` (array[string]) アプリケーションのタグ
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='アプリケーションのパラメータ情報を取得'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
ページに入る際に、機能、入力パラメータ名、タイプ、デフォルト値などの情報を取得するために使用されます。
|
||||
|
||||
### クエリ
|
||||
|
||||
<Properties>
|
||||
<Property name='user' type='string' key='user'>
|
||||
ユーザー識別子、開発者のルールで定義され、アプリケーション内で一意でなければなりません。
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
### 応答
|
||||
- `user_input_form` (array[object]) ユーザー入力フォームの設定
|
||||
- `text-input` (object) テキスト入力コントロール
|
||||
- `label` (string) 変数表示ラベル名
|
||||
- `variable` (string) 変数ID
|
||||
- `required` (bool) 必須かどうか
|
||||
- `default` (string) デフォルト値
|
||||
- `paragraph` (object) 段落テキスト入力コントロール
|
||||
- `label` (string) 変数表示ラベル名
|
||||
- `variable` (string) 変数ID
|
||||
- `required` (bool) 必須かどうか
|
||||
- `default` (string) デフォルト値
|
||||
- `select` (object) ドロップダウンコントロール
|
||||
- `label` (string) 変数表示ラベル名
|
||||
- `variable` (string) 変数ID
|
||||
- `required` (bool) 必須かどうか
|
||||
- `default` (string) デフォルト値
|
||||
- `options` (array[string]) オプション値
|
||||
- `file_upload` (object) ファイルアップロード設定
|
||||
- `image` (object) 画像設定
|
||||
現在サポートされている画像タイプのみ:`png`, `jpg`, `jpeg`, `webp`, `gif`
|
||||
- `enabled` (bool) 有効かどうか
|
||||
- `number_limits` (int) 画像数の制限、デフォルトは3
|
||||
- `transfer_methods` (array[string]) 転送方法のリスト、remote_url, local_file、いずれかを選択する必要があります
|
||||
- `system_parameters` (object) システムパラメータ
|
||||
- `file_size_limit` (int) ドキュメントアップロードサイズ制限(MB)
|
||||
- `image_file_size_limit` (int) 画像ファイルアップロードサイズ制限(MB)
|
||||
- `audio_file_size_limit` (int) オーディオファイルアップロードサイズ制限(MB)
|
||||
- `video_file_size_limit` (int) ビデオファイルアップロードサイズ制限(MB)
|
||||
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="リクエスト" tag="GET" label="/parameters" targetCode={` curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123' \
|
||||
--header 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="応答">
|
||||
```json {{ title: '応答' }}
|
||||
{
|
||||
"user_input_form": [
|
||||
{
|
||||
"paragraph": {
|
||||
"label": "Query",
|
||||
"variable": "query",
|
||||
"required": true,
|
||||
"default": ""
|
||||
}
|
||||
}
|
||||
],
|
||||
"file_upload": {
|
||||
"image": {
|
||||
"enabled": false,
|
||||
"number_limits": 3,
|
||||
"detail": "high",
|
||||
"transfer_methods": [
|
||||
"remote_url",
|
||||
"local_file"
|
||||
]
|
||||
}
|
||||
},
|
||||
"system_parameters": {
|
||||
"file_size_limit": 15,
|
||||
"image_file_size_limit": 10,
|
||||
"audio_file_size_limit": 50,
|
||||
"video_file_size_limit": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
@ -111,7 +111,7 @@ Workflow 应用无会话支持,适合用于翻译/文章写作/总结 AI 等
|
||||
- `title` (string) 节点名称
|
||||
- `index` (int) 执行序号,用于展示 Tracing Node 顺序
|
||||
- `predecessor_node_id` (string) 前置节点 ID,用于画布展示执行路径
|
||||
- `inputs` (array[object]) 节点中所有使用到的前置节点变量内容
|
||||
- `inputs` (object) 节点中所有使用到的前置节点变量内容
|
||||
- `created_at` (timestamp) 开始时间
|
||||
- `event: node_finished` node 执行结束,成功失败同一事件中不同状态
|
||||
- `task_id` (string) 任务 ID,用于请求跟踪和下方的停止响应接口
|
||||
@ -122,7 +122,7 @@ Workflow 应用无会话支持,适合用于翻译/文章写作/总结 AI 等
|
||||
- `node_id` (string) 节点 ID
|
||||
- `index` (int) 执行序号,用于展示 Tracing Node 顺序
|
||||
- `predecessor_node_id` (string) optional 前置节点 ID,用于画布展示执行路径
|
||||
- `inputs` (array[object]) 节点中所有使用到的前置节点变量内容
|
||||
- `inputs` (object) 节点中所有使用到的前置节点变量内容
|
||||
- `process_data` (json) Optional 节点过程数据
|
||||
- `outputs` (json) Optional 输出内容
|
||||
- `status` (string) 执行状态 `running` / `succeeded` / `failed` / `stopped`
|
||||
@ -490,104 +490,6 @@ Workflow 应用无会话支持,适合用于翻译/文章写作/总结 AI 等
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='获取应用配置信息'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
用于进入页面一开始,获取功能开关、输入参数名称、类型及默认值等使用。
|
||||
|
||||
### Query
|
||||
|
||||
<Properties>
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
### Response
|
||||
- `user_input_form` (array[object]) 用户输入表单配置
|
||||
- `text-input` (object) 文本输入控件
|
||||
- `label` (string) 控件展示标签名
|
||||
- `variable` (string) 控件 ID
|
||||
- `required` (bool) 是否必填
|
||||
- `default` (string) 默认值
|
||||
- `paragraph` (object) 段落文本输入控件
|
||||
- `label` (string) 控件展示标签名
|
||||
- `variable` (string) 控件 ID
|
||||
- `required` (bool) 是否必填
|
||||
- `default` (string) 默认值
|
||||
- `select` (object) 下拉控件
|
||||
- `label` (string) 控件展示标签名
|
||||
- `variable` (string) 控件 ID
|
||||
- `required` (bool) 是否必填
|
||||
- `default` (string) 默认值
|
||||
- `options` (array[string]) 选项值
|
||||
- `file_upload` (object) 文件上传配置
|
||||
- `image` (object) 图片设置
|
||||
当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`
|
||||
- `enabled` (bool) 是否开启
|
||||
- `number_limits` (int) 图片数量限制,默认 3
|
||||
- `transfer_methods` (array[string]) 传递方式列表,remote_url , local_file,必选一个
|
||||
- `system_parameters` (object) 系统参数
|
||||
- `file_size_limit` (int) 文档上传大小限制 (MB)
|
||||
- `image_file_size_limit` (int) 图片文件上传大小限制(MB)
|
||||
- `audio_file_size_limit` (int) 音频文件上传大小限制 (MB)
|
||||
- `video_file_size_limit` (int) 视频文件上传大小限制 (MB)
|
||||
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="GET" label="/parameters" targetCode={` curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123' \
|
||||
--header 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"user_input_form": [
|
||||
{
|
||||
"paragraph": {
|
||||
"label": "Query",
|
||||
"variable": "query",
|
||||
"required": true,
|
||||
"default": ""
|
||||
}
|
||||
}
|
||||
],
|
||||
"file_upload": {
|
||||
"image": {
|
||||
"enabled": false,
|
||||
"number_limits": 3,
|
||||
"detail": "high",
|
||||
"transfer_methods": [
|
||||
"remote_url",
|
||||
"local_file"
|
||||
]
|
||||
}
|
||||
},
|
||||
"system_parameters": {
|
||||
"file_size_limit": 15,
|
||||
"image_file_size_limit": 10,
|
||||
"audio_file_size_limit": 50,
|
||||
"video_file_size_limit": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/workflows/logs'
|
||||
method='GET'
|
||||
@ -691,3 +593,145 @@ Workflow 应用无会话支持,适合用于翻译/文章写作/总结 AI 等
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/info'
|
||||
method='GET'
|
||||
title='获取应用基本信息'
|
||||
name='#info'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
用于获取应用的基本信息
|
||||
### Query
|
||||
<Properties>
|
||||
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
### Response
|
||||
- `name` (string) 应用名称
|
||||
- `description` (string) 应用描述
|
||||
- `tags` (array[string]) 应用标签
|
||||
</Col>
|
||||
<Col>
|
||||
<CodeGroup title="Request" tag="GET" label="/info" targetCode={`curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \\\n-H 'Authorization: Bearer {api_key}'`}>
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/info?user=abc-123' \
|
||||
-H 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
</CodeGroup>
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"name": "My App",
|
||||
"description": "This is my app.",
|
||||
"tags": [
|
||||
"tag1",
|
||||
"tag2"
|
||||
]
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
---
|
||||
|
||||
<Heading
|
||||
url='/parameters'
|
||||
method='GET'
|
||||
title='获取应用参数'
|
||||
name='#parameters'
|
||||
/>
|
||||
<Row>
|
||||
<Col>
|
||||
用于进入页面一开始,获取功能开关、输入参数名称、类型及默认值等使用。
|
||||
|
||||
### Query
|
||||
|
||||
<Properties>
|
||||
<Property name='user' type='string' key='user'>
|
||||
用户标识,由开发者定义规则,需保证用户标识在应用内唯一。
|
||||
</Property>
|
||||
</Properties>
|
||||
|
||||
### Response
|
||||
- `user_input_form` (array[object]) 用户输入表单配置
|
||||
- `text-input` (object) 文本输入控件
|
||||
- `label` (string) 控件展示标签名
|
||||
- `variable` (string) 控件 ID
|
||||
- `required` (bool) 是否必填
|
||||
- `default` (string) 默认值
|
||||
- `paragraph` (object) 段落文本输入控件
|
||||
- `label` (string) 控件展示标签名
|
||||
- `variable` (string) 控件 ID
|
||||
- `required` (bool) 是否必填
|
||||
- `default` (string) 默认值
|
||||
- `select` (object) 下拉控件
|
||||
- `label` (string) 控件展示标签名
|
||||
- `variable` (string) 控件 ID
|
||||
- `required` (bool) 是否必填
|
||||
- `default` (string) 默认值
|
||||
- `options` (array[string]) 选项值
|
||||
- `file_upload` (object) 文件上传配置
|
||||
- `image` (object) 图片设置
|
||||
当前仅支持图片类型:`png`, `jpg`, `jpeg`, `webp`, `gif`
|
||||
- `enabled` (bool) 是否开启
|
||||
- `number_limits` (int) 图片数量限制,默认 3
|
||||
- `transfer_methods` (array[string]) 传递方式列表,remote_url , local_file,必选一个
|
||||
- `system_parameters` (object) 系统参数
|
||||
- `file_size_limit` (int) 文档上传大小限制 (MB)
|
||||
- `image_file_size_limit` (int) 图片文件上传大小限制(MB)
|
||||
- `audio_file_size_limit` (int) 音频文件上传大小限制 (MB)
|
||||
- `video_file_size_limit` (int) 视频文件上传大小限制 (MB)
|
||||
|
||||
</Col>
|
||||
<Col sticky>
|
||||
|
||||
<CodeGroup title="Request" tag="GET" label="/parameters" targetCode={` curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123'`}>
|
||||
|
||||
```bash {{ title: 'cURL' }}
|
||||
curl -X GET '${props.appDetail.api_base_url}/parameters?user=abc-123' \
|
||||
--header 'Authorization: Bearer {api_key}'
|
||||
```
|
||||
|
||||
</CodeGroup>
|
||||
|
||||
<CodeGroup title="Response">
|
||||
```json {{ title: 'Response' }}
|
||||
{
|
||||
"user_input_form": [
|
||||
{
|
||||
"paragraph": {
|
||||
"label": "Query",
|
||||
"variable": "query",
|
||||
"required": true,
|
||||
"default": ""
|
||||
}
|
||||
}
|
||||
],
|
||||
"file_upload": {
|
||||
"image": {
|
||||
"enabled": false,
|
||||
"number_limits": 3,
|
||||
"detail": "high",
|
||||
"transfer_methods": [
|
||||
"remote_url",
|
||||
"local_file"
|
||||
]
|
||||
}
|
||||
},
|
||||
"system_parameters": {
|
||||
"file_size_limit": 15,
|
||||
"image_file_size_limit": 10,
|
||||
"audio_file_size_limit": 50,
|
||||
"video_file_size_limit": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
</CodeGroup>
|
||||
</Col>
|
||||
</Row>
|
||||
|
||||
Reference in New Issue
Block a user