GET Request
This operation makes a GET request to a specified url.
Note: This operation is part of the HTTP Book (BDK). To use this book, you need to first learn it in your agent.
Input Concepts
Concept | Description | Type | Required |
---|---|---|---|
url | The URL to make the GET request to. | text | Yes |
headers | The headers to include in the request. For example {"Authorization": "Bearer <token>"} . Note: If connect is set, the "Authorization" header will be added automatically to the request, and a manually set "Authorization" header will be ignored. | No |
Output Concepts
Concept | Description | Type |
---|---|---|
answer | The response from the GET request. | file or list of or text |
Examples
- Retrieve all posts
retrieve "https://jsonplaceholder.typicode.com/posts"
- Retrieve a post with an ID of 1
retrieve "https://jsonplaceholder.typicode.com/posts/1"
- Retrieve all posts by a user with an ID of 1
retrieve "https://jsonplaceholder.typicode.com/posts" whose "userId" is 1
- Retrieve all posts with an Authenticated header
create a json
use the above as the headers input
set the headers input's "Authentication" to "Bearer <token>"
retrieve "https://jsonplaceholder.typicode.com/posts"
... the headers is the headers input
Updated 8 days ago