Beta feature

Install Postman Insights Agent on EC2

The Postman Insights Agent listens to the traffic arriving at the service you want to monitor and automatically populates your Insights project with endpoints.

To use the Insights Agent with a standalone Linux instance of Amazon EC2, complete the following steps.

Estimated time: 10-minute setup, 5-minute wait

After onboarding a service, you'll see your endpoints and their insights. Then, you can leverage the Insights' Repro Mode to debug your failing endpoints.

Requirements

  • SSH access to your virtual EC2 machine.
  • Your server's OS supports systemd.
  • Root user privileges in order to edit systemd files.
  • Insights project. See Get started with Postman Insights to learn more.

Install Insights Agent on EC2

To install the Insights Agent, do the following:

  1. From the Setup tab of your workspace, select AWS EC2.

    Select your environment
  2. Log in to the EC2 instance. For more information, see Connect to your EC2 Instance.

  3. As shown on the Insights onboarding screen, run the install script on that instance.

    bash -c "$(curl -L https://releases.observability.postman.com/scripts/install-postman-insights-agent.sh)"
    
  4. On the Insights onboarding screen, select Add API key to copy and paste it with the next command.

    In the example command below, the angle brackets and the text between them are placeholders. The command you copy in the onboarding screen will contain your correct API key and project ID.

    sudo POSTMAN_API_KEY=<your-api-key> postman-insights-agent ec2 setup --project <projectId> --repro-mode
    

    The --repro-mode flag allows the agent to send encrypted payload data for rerunning requests.

    In the resulting output, the server checks for user permissions and the presence of systemd, configures systemd files, and enables Postman Insights Agent as a systemd service.

  5. Check the status or logs. Run the journalctl command:

    sudo journalctl -fu postman-insights-agent
    
  6. In Postman, check out the Insight Project's Endpoints tab to see the list of endpoints the Insights Agent generates as it gathers data.

Run the help command for other configuration parameters.

postman-insights-agent ec2 --help

Tip: If you're not seeing your endpoints right away, traffic may be taking some time to collect. See the next section for more information.

Wait for the Insights Agent to collect traffic

After Insights detects traffic from the Insights Agent, you'll get automatically redirected to the Overview page. The Insights Agent needs 5-8 minutes to use AI to generate endpoints.

If you're only seeing health checks, your traffic may be affected. If you're not seeing what you expect after 10 minutes, see Diagnose and troubleshoot Insights Agent errors.

Activate Repro Mode

To make it possible to make API calls using real user data, you need to activate Repro Mode. Go to your Insights project and select Settings. Then, toggle on Activate Repro Mode.

Only a Workspace Admin can enable Repro Mode.

Activate repro mode

Default data redactions. Postman Insights automatically redacts a set of sensitive values including authentication tokens. See the full list. You can also add fields to redact ahead of turning on the feature.

Uninstall the Insights Agent

To stop the systemd service, run the following:

sudo systemctl disable postman-insights-agent.service

Last modified: 2025/05/30