Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 33 additions & 15 deletions fern/server-url/events.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -49,17 +49,20 @@ Example assistant configuration (excerpt):
"model": {
"provider": "openai",
"model": "gpt-4o",
"functions": [
"tools": [
{
"name": "sendEmail",
"description": "Used to send an email to a client.",
"parameters": {
"type": "object",
"properties": {
"emailAddress": { "type": "string" },
"message": { "type": "string" }
},
"required": ["emailAddress", "message"]
"type": "function",
"function": {
"name": "sendEmail",
"description": "Used to send an email to a client.",
"parameters": {
"type": "object",
"properties": {
"emailAddress": { "type": "string" },
"message": { "type": "string" }
},
"required": ["emailAddress", "message"]
}
}
}
]
Expand All @@ -74,14 +77,29 @@ When tools are triggered, your Server URL receives a `tool-calls` message:
"message": {
"type": "tool-calls",
"call": { /* Call Object */ },
"toolWithToolCallList": [
"toolCallList": [
{
"name": "sendEmail",
"toolCall": { "id": "abc123", "parameters": { "emailAddress": "john@example.com", "message": "Hi!" } }
"id": "abc123",
"type": "function",
"function": {
"name": "sendEmail",
"arguments": { "emailAddress": "john@example.com", "message": "Hi!" }
}
}
],
"toolCallList": [
{ "id": "abc123", "name": "sendEmail", "parameters": { "emailAddress": "john@example.com", "message": "Hi!" } }
"toolWithToolCallList": [
{
"type": "function",
"function": { "name": "sendEmail", "parameters": { /* tool parameters schema */ } },
"toolCall": {
"id": "abc123",
"type": "function",
"function": {
"name": "sendEmail",
"arguments": { "emailAddress": "john@example.com", "message": "Hi!" }
}
}
}
]
}
}
Expand Down
Loading