>_ CLI Index
← Back

curl

Built-in v8.7.1

Command-line tool for transferring data with URLs

Agent Support
3/5
Platforms
macoslinuxwindows

Agent Usage Example

shell
curl -s -X POST https://api.example.com/v1/chat -H 'Content-Type: application/json' -d '{"message": "hello"}'

Installation

brew install curl

curl is the universal data transfer tool of the internet. Supporting over 25 protocols including HTTP, HTTPS, FTP, and WebSocket, it is pre-installed on virtually every Unix-like system and has become the de facto standard for making network requests from the command line.

AI agents use curl as their primary means of interacting with web APIs — fetching data, posting payloads, downloading files, and testing endpoints. Its comprehensive flag system allows fine-grained control over headers, authentication, timeouts, retries, and output formatting.

With over two decades of continuous development, curl handles edge cases that simpler HTTP clients miss: connection reuse, redirect chains, certificate pinning, proxy tunneling, and rate limiting. Its silent mode (-s) and JSON output options make it particularly well-suited for scripted workflows where clean, parseable output is essential.

Related Tools