You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+30-24Lines changed: 30 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,36 +13,42 @@ You can use AgentAPI:
13
13
14
14
## Quickstart
15
15
16
-
Install `agentapi`:
16
+
1.Install `agentapi` by either:
17
17
18
-
1. Download the latest release binary from the [releases page](https://github.com/coder/agentapi/releases)
19
-
2. Rename it (e.g. `mv agentapi-darwin-arm64 agentapi`)
20
-
3. Make it executable (`chmod +x agentapi`)
21
-
4. Put it in your PATH (e.g. `sudo mv agentapi /usr/local/bin`)
22
-
5. Verify the installation (`agentapi --help`)
23
-
6. (macOS) If you're prompted that macOS was unable to verify the binary, go to `System Settings -> Privacy & Security`, click "Open Anyway", and run the command again.
18
+
- Downloading the latest release binary from the [releases page](https://github.com/coder/agentapi/releases)
19
+
- Or building from source:
20
+
```bash
21
+
go install github.com/coder/agentapi@latest
22
+
```
24
23
25
-
Run a Claude Code server (assumes `claude` is installed on your system):
24
+
1. Verify the installation:
26
25
27
-
```bash
28
-
agentapi server -- claude
29
-
```
26
+
```bash
27
+
agentapi --help
28
+
```
30
29
31
-
Send a message to the agent:
30
+
1. (macOS) If you're prompted that macOS was unable to verify the binary, go to `System Settings -> Privacy & Security`, click "Open Anyway", and run the command again.
31
+
1. Run a Claude Code server (assumes `claude` is installed on your system):
32
32
33
-
```bash
34
-
curl -X POST localhost:3284/message \
35
-
-H "Content-Type: application/json" \
36
-
-d '{"content": "Hello, agent!", "type": "user"}'
37
-
```
33
+
```bash
34
+
agentapi server -- claude
35
+
```
38
36
39
-
Get the conversation history:
37
+
1. Send a message to the agent:
40
38
41
-
```bash
42
-
curl localhost:3284/messages
43
-
```
39
+
```bash
40
+
curl -X POST localhost:3284/message \
41
+
-H "Content-Type: application/json" \
42
+
-d '{"content": "Hello, agent!", "type": "user"}'
43
+
```
44
+
45
+
1. Get the conversation history:
46
+
47
+
```bash
48
+
curl localhost:3284/messages
49
+
```
44
50
45
-
We host a demo web chat interface at https://coder.github.io/agentapi/chat which will connect to your local AgentAPI server and let you test it out.
51
+
1. Try the demo web chat interface at https://coder.github.io/agentapi/chat. Even though it's hosted on GitHub Pages, the chat will connect to your AgentAPI server running on `localhost:3284`.
The OpenAPI schema is available in this repository:[openapi.json](openapi.json).
70
+
An OpenAPI schema is available in [openapi.json](openapi.json).
65
71
66
-
By default, the server runs on port 3284. Additionally, the server exposes an OpenAPI schema at http://localhost:3284/openapi.json. You may also inspect the available endpoints at http://localhost:3284/docs.
72
+
By default, the server runs on port 3284. Additionally, the server exposes the same OpenAPI schema at http://localhost:3284/openapi.json and the available endpoints in a documentation UI at http://localhost:3284/docs.
0 commit comments