Skip to content

Commit 86d5d52

Browse files
Documentation edits made through Mintlify web editor
1 parent 996f2a6 commit 86d5d52

File tree

3 files changed

+116
-6
lines changed

3 files changed

+116
-6
lines changed
Lines changed: 115 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,116 @@
11
---
2-
openapi: POST /chat/topic
3-
---
2+
title: "Create Assistant Topic"
3+
api: "POST https://api.example.com/assistant/topics"
4+
description: "Create a new assistant topic to organize conversations and interactions."
5+
---
6+
7+
## Overview
8+
9+
This endpoint allows you to create a new assistant topic. Topics help organize and categorize assistant conversations, making it easier to manage different discussion threads or subjects.
10+
11+
## Request
12+
13+
<ParamField body="name" type="string" required>
14+
The name of the assistant topic
15+
</ParamField>
16+
17+
<ParamField body="description" type="string">
18+
Optional description for the assistant topic
19+
</ParamField>
20+
21+
<ParamField body="tags" type="array">
22+
Array of tags to categorize the assistant topic
23+
</ParamField>
24+
25+
## Response
26+
27+
<ResponseField name="id" type="string">
28+
Unique identifier for the created assistant topic
29+
</ResponseField>
30+
31+
<ResponseField name="name" type="string">
32+
Name of the assistant topic
33+
</ResponseField>
34+
35+
<ResponseField name="description" type="string">
36+
Description of the assistant topic
37+
</ResponseField>
38+
39+
<ResponseField name="tags" type="array">
40+
Tags associated with the assistant topic
41+
</ResponseField>
42+
43+
<ResponseField name="created_at" type="string">
44+
Timestamp when the assistant topic was created
45+
</ResponseField>
46+
47+
<ResponseField name="updated_at" type="string">
48+
Timestamp when the assistant topic was last updated
49+
</ResponseField>
50+
51+
## Example
52+
53+
<RequestExample>
54+
55+
```bash cURL
56+
curl -X POST https://api.example.com/assistant/topics \
57+
-H "Authorization: Bearer YOUR_API_KEY" \
58+
-H "Content-Type: application/json" \
59+
-d '{
60+
"name": "Customer Support Assistant",
61+
"description": "Assistant topic for handling customer support inquiries",
62+
"tags": ["support", "customer-service"]
63+
}'
64+
```
65+
66+
```javascript JavaScript
67+
const response = await fetch('https://api.example.com/assistant/topics', {
68+
method: 'POST',
69+
headers: {
70+
'Authorization': 'Bearer YOUR_API_KEY',
71+
'Content-Type': 'application/json',
72+
},
73+
body: JSON.stringify({
74+
name: 'Customer Support Assistant',
75+
description: 'Assistant topic for handling customer support inquiries',
76+
tags: ['support', 'customer-service']
77+
})
78+
});
79+
80+
const assistantTopic = await response.json();
81+
```
82+
83+
```python Python
84+
import requests
85+
86+
url = "https://api.example.com/assistant/topics"
87+
headers = {
88+
"Authorization": "Bearer YOUR_API_KEY",
89+
"Content-Type": "application/json"
90+
}
91+
data = {
92+
"name": "Customer Support Assistant",
93+
"description": "Assistant topic for handling customer support inquiries",
94+
"tags": ["support", "customer-service"]
95+
}
96+
97+
response = requests.post(url, headers=headers, json=data)
98+
assistant_topic = response.json()
99+
```
100+
101+
</RequestExample>
102+
103+
<ResponseExample>
104+
105+
```json Response
106+
{
107+
"id": "topic_12345",
108+
"name": "Customer Support Assistant",
109+
"description": "Assistant topic for handling customer support inquiries",
110+
"tags": ["support", "customer-service"],
111+
"created_at": "2023-11-20T10:30:00Z",
112+
"updated_at": "2023-11-20T10:30:00Z"
113+
}
114+
```
115+
116+
</ResponseExample>
Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +0,0 @@
1-
---
2-
openapi: POST /chat/message
3-
---

api-reference/introduction.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ Responses include citations so you can point your users to the right places they
3434
</Note>
3535

3636
Now that you have an API key, check out our [example](https://github.com/mintlify/discovery-api-example) for how to use
37-
the API for AI assistant. You can also see a deployed version of this example at [chat.mintlify.com](https://chat.mintlify.com).
37+
the API for AI assistant. You can also see a deployed version of this example at [assistant.mintlify.com](https://assistant.mintlify.com).

0 commit comments

Comments
 (0)