Radar Agent Fails to Authenticate

Symptom:

When installing an on-premise API Monitoring Radar Agent, you may encounter an "invalid username/password" error message. 

Reason:

The Radar Agent requires a Runscope API token in order to authenticate. 

Solution:

Run the agent program with the API token via the --token​ argument, then save the agent's configuration to a file. 

To create the required API token, follow these steps:

  1. Log into API Monitoring.
  2. Click your API Monitoring icon in the upper-right below your name, then select Personal Information.
  3. On the left side click Applications.
    The https://www.runscope.com/applications page opens.
  4. Click Create Application. All fields are required.
  5. Provide any Name for the app that reflects its purpose (for example, "API Monitoring Agent Token").
  6. Provide any Website URL and Callback URL.. It can be completely imaginary, so long as it "looks like" a URL to satisfy the parser on that page.

    Note: Normally this application creation process is used to set up an application for use with an OAuth flow with a third-party app, so that app can access API Monitoring. But in this case, you use it to generate a Runscope API token for general Runscope API usage, and the URLs are ignored.

  7. Click the Create Application button.
  8. On the next page, scroll down until you see the Personal Access Token.
    This is the UUID that is your API token which you'll use with the agent.

Now that you have your token, launch your agent like this:

/path/to/runscope-radar --token=whatever-your-token-is

If you are on multiple API Monitoring "Teams", you are prompted to choose which "Team" to associate the agent with. If you are on only one Team, no such prompt will occur. 

Tip: You'll have an option to save the Agent configuration to a file, do this. On future runs of the Runscope agent, you'll pass it a parameter that indicates its configuration file:

/path/to/runscope-radar -f /path/to/radar.conf

Note that the agent configuration file contains various parameters, including the API token (which you provided) as well as a unique agent ID that was generated, and the Team ID that the agent is associated with. You can read more about the agent and its options here:
https://www.runscope.com/docs/api-testing/agent/

You can now execute your API Monitoring test.