Discovery

The Discovery API allows you to find values for the various filters that are available within TraceView. Of course, for any endpoint that accepts filters, you can pass in anything you want, and we’ll try our best to return data. There are provided mostly as a conveniences to understand what values we expect, and will respond to.

Apps

GET /api-v2/apps

Returns a list of all available apps.

This list will contaion only the “Default” app if no customizations have been defined on your settings page.

Sample

{
    "data": [
        "Default",
        "Webapp",
        "API",
        "Upload"
    ],
    "response": "ok"
}

Domains

GET /api-v2/domains

Returns a list of all domains traced.

Subdomains are treated as entirely seperate domains (i.e., appneta.com and www.appneta.com are not aggregated). IPs can also appear here, if the request was made directly to that address.

Sample

{
    "data": [
        "10.0.2.132",
        "192.168.1.8",
        "helloapp.tv.appneta.com",
        "appneta.com"
    ],
    "response": "ok"
}

Controller / Actions

GET /api-v2/controllers

GET /api-v2/actions

Returns a list of all controllers or actions traced.

Controller/action pairs are captured automatically by Rails, Django, Spring, and Struts.

If you’re using an MVC framework, and not seeing anything here, you may have to add a small hook to your code to capture them. Hooks are available for CodeIgniter, Drupal, Kohana, Zend, or others.

Controllers:

{
    "data": [
        "account",
        "admin",
        "api"
        "dashboard"
    ],
    "response": "ok"
}

Actions:

{
    "data": [
        "index",
        "summary",
        "view"
        "update"
    ],
    "response": "ok"
}

Browsers

GET /api-v2/browsers

Returns a list of browser families, seen in RUM.

Browsers apply to all client-side data endpoints. Browsers are aggregated by major family (versions, while available through the web app, are not yet exposed via the API.).

{
    "data": [
        "Chrome",
        "Firefox",
        "IE",
        "Opera"
    ],
    "response": "ok"
}

Hosts

GET /api-v2/hosts

Return a list of all hosts traced.

The presence of a host in this list does not guarantee that host is currently generating traces, only that it has generated a trace within your data retention window (1 hour, 24 hours, or 7 days).

Sample

{
    "data": [
        "www01.yoursite.com",
        "www02.yoursite.com",
        "db.yoursite.com"
    ],
    "response": "ok"
}

Metrics

GET /api-v2/metrics

Return a list of all available host metrics being collected.

Note that not every metric will be available for every host (eg. JMX data will only be available on Java instrumented hosts, etc.).

Sample

{
    "data": [
        "cpu_user_frac:all",
        "device_await:sda1",
        "device_usage:/dev/sda1",
        "load",
        "mem_apps",
        "mem_cached",
        "mem_swap",
        "mem_totalused"
    ],
    "response": "ok"
}

Regions

GET /api-v2/regions

Returns a list of region codes, seen in RUM.

Regions codes are ISO 3166-1 and ISO 3166-2 codes for all regions collected in RUM. Currently, country codes (ISO-3166-1) are available worldwide, and state codes (ISO-3166-2) are available in the US and Canada.

{
    "data": [
        "BZ",
        "CA-BC",
        "US-MO",
        "US-CT"
    ],
    "response": "ok"
}

Layers

GET /api-v2/layers/<app-name>

Returns a list of all layers reporting data recently for the given app. The default recency threshold is 1 day; alternate thresholds can be specified via UTC timestamp in milliseconds via optional parameter since_time (eg. GET /api-v2/layers/<app-name>?since_time=123456789000)

Sample

{
    "data": [
        "nginx",
        "wsgi",
        "sqlalchemy",
        "httplib"
    ],
    "response": "ok"
}