# apidump command reference The `apidump` command captures and stores a sequence of requests and responses to a service by observing network traffic. See [Examples](#examples). For help, use `-h` or `--help`. ## Usage ```bash postman-insights-agent apidump [flags] ``` ## Flags * `--filter string` - Match the packets going to and coming from the API service. * `--host-allow strings` - Allow only the HTTP hosts matching the regular expressions. * `--host-exclusions strings` - Remove the HTTP hosts matching the regular expressions. * `--interfaces strings` - List of network interfaces to listen on. Default: All interfaces on host. * `--path-allow strings` - Allow only the HTTP paths matching the regular expressions. * `--path-exclusions strings` - Remove the HTTP paths matching the regular expressions. * `--project string` - The Postman Insights project ID. * `--rate-limit float` - Number of requests per minute to capture. Default: 1000. ## Global flags * `--log-format string` - Set to `color`, `plain`, or `json` to control the log format. * `--proxy string` - The domain name, IP address, or URL of an HTTP proxy server to use. ## Examples * Capture all traffic from your collection and send it to the Insights Agent. ```bash postman-insights-agent apidump --project ``` * Filter out requests fetching files with `.png` or `.jpg` extensions. ```bash postman-insights-agent apidump ... --path-exclusions '.*\.png' --path-exclusions '.*\.jpg' ... ``` * Filter out requests having host `deb.debian.org`. ```bash postman-insights-agent apidump ... --host-exclusions 'deb\.debian\.org' ... ``` * Only allow requests having host `www.example.com`. ```bash postman-insights-agent apidump ... --host-allow 'www\.example\.com' ... ``` * Only allow requests related to the admin endpoints. ```bash postman-insights-agent apidump ... --path-allow '*/admin/*' ... ```