Skip to content

Commit

Permalink
updating webhook docs to include header support
Browse files Browse the repository at this point in the history
  • Loading branch information
lylepratt committed Oct 5, 2024
1 parent 51ae961 commit ac5ba16
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions functions/webhooks.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,22 @@ Once added, you need to provide instructions to the agent on how and when to use
Here is an example of how you might configure a webhook action:

```plaintext
- **Condition**: When the caller asks for the latest news headlines.
- **HTTP Method**: GET
- **URL**: https://api.news.com/v1/latest-headlines
- **Parameters**: None for GET requests.
- **Condition**: When the caller wants to book an appointment.
- **Condition**: When the caller wants to book an appointment with authentication.
- **HTTP Method**: POST
- **URL**: https://api.scheduler.com/v2/appointments
- **Headers**: {
"Authorization": "Bearer [API_KEY]",
"Client-Id": "[Client ID]",
"Content-Type": "application/json"
}
- **Parameters**: {
"name": "[Caller Name]",
"phone": "[Caller Phone Number]",
"date": "[Preferred Date]",
"time": "[Preferred Time]"
}
- **Condition**: When the caller requests product availability.
- **HTTP Method**: GET
- **URL**: https://api.store.com/v1/check-availability?product_id=[Product ID]
Expand Down

0 comments on commit ac5ba16

Please sign in to comment.