Formats and fields

JSON by default, CSV for lists, plain text for transcripts, and a fields parameter that trims any response.

format

formatWorks onReturns
json (default)everythingThe { data, meta?, request_id } envelope
csvlist endpointsFlattened rows, one item per line, UTF-8
texttranscript endpointsThe plain transcript, no envelope
curl "https://api.instadata.dev/v1/instagram/comments?url=…&limit=50&format=csv" \
  -H "Authorization: Bearer ik_live_..." -o comments.csv

Nested objects flatten with underscores (author.handle becomes author_handle). Credits are identical across formats.

fields

Pass a comma-separated list of paths to keep only those keys:

curl "https://api.instadata.dev/v1/instagram/channel-stats?handle=nasa&fields=handle,followers,bio" \
  -H "Authorization: Bearer ik_live_..."