Make single API requests with flexible output formats and field filtering
anysite api <endpoint> [key=value ...] [OPTIONS]
Parameters are passed as key=value pairs. The CLI automatically converts types based on the cached schema.
anysite api /api/linkedin/user user=satyanadella
anysite api /api/linkedin/company company=anthropic
anysite api /api/linkedin/search/users keywords="CTO" count=50
anysite api /api/instagram/user user=natgeo
anysite api /api/twitter/user user=elonmusk
Control how results are displayed with --format (or -f):
```bash
anysite api /api/linkedin/user user=satyanadella --format json
```
```json
{
"name": "Satya Nadella",
"headline": "Chairman and CEO at Microsoft",
"urn": {
"value": "ACoAAA8BYqEBCGLg_vT_ca6mMEqkR9bc",
"type": "member"
},
...
}
```
```bash
anysite api /api/linkedin/search/users keywords="CTO" count=10 --format csv
```
Generates a CSV file suitable for spreadsheets and further processing.
```bash
anysite api /api/linkedin/company/employees companies=anthropic --format jsonl
```
One JSON object per line — ideal for streaming and piping to other tools.
```bash
anysite api /api/linkedin/user user=satyanadella --format table
```
Human-readable table format for quick visual inspection.
Select only the fields you need:
anysite api /api/linkedin/user user=satyanadella --fields "name,headline,urn.value"
Supports dot-notation for nested fields.
Remove verbose or unnecessary fields:
anysite api /api/linkedin/user user=satyanadella --exclude "certifications,courses,honors"
Use built-in presets for common use cases:
anysite api /api/linkedin/user user=satyanadella --fields-preset minimal
anysite api /api/linkedin/user user=satyanadella --fields-preset contact
anysite api /api/linkedin/user user=satyanadella --fields-preset recruiting
anysite api /api/linkedin/search/users keywords="CTO" count=50 \
--format csv --output ctos.csv
Minify JSON output for smaller file sizes:
anysite api /api/linkedin/user user=satyanadella --compact
Suppress progress messages for clean piping:
anysite api /api/linkedin/user user=satyanadella -q --format jsonl
Combine with database loading or other CLI commands:
# API → Database
anysite api /api/linkedin/user user=satyanadella -q --format jsonl | \
anysite db insert mydb --table profiles --stdin --auto-create
# API → File
anysite api /api/linkedin/search/users keywords="engineer" count=100 \
-q --format csv > engineers.csv
# API → jq filtering
anysite api /api/linkedin/user user=satyanadella -q | jq '.name, .headline'
| Option | Short | Description |
|---|---|---|
--format |
-f |
Output format: json, jsonl, csv, table (default: json) |
--fields |
Include only specified fields (comma-separated, dot-notation) | |
--exclude |
Exclude specified fields from output | |
--fields-preset |
Built-in field preset: minimal, contact, recruiting |
|
--compact |
Minify JSON output | |
--output |
-o |
Save output to file |
-q |
Quiet mode — suppress progress messages |
Process multiple inputs with parallelism and rate limiting
Build multi-source workflows with dependency chains