Transactions

Access transactions metrics.

Transactions metrics are always related to a project. This means that all endpoints have the same root so it could be helpful to wrap your api call under the same base URI:

https://app.inspector.dev/api/projects/:id

Transactions List

POST http://app.inspector.dev/api/projects/:id/transactions

Get the list of transactions in the given interval.

Path Parameters

NameTypeDescription

id*

Integer

Project's identifier

Headers

NameTypeDescription

Authentication*

string

API key

Request Body

NameTypeDescription

filter.start*

Date

ISO-8601 date format

filter.end

Date

ISO-8601 date format

filter.hosts

Array

Filter the transactions list by servers

filter.query_string

String

Filter by transaction's name

[
    {
        group_hash: "4fbb4fa36bad346bbe8a26827a244e70"
        last_record: {
            duration: 42.8,
            group_hash: "4fbb4fa36bad346bbe8a26827a244e70",
            hash: "37d6f2a1bd370759ff46cc63266603b81b60da4774bfa9a72af7bf26ba3d4fb1",
            host: {hostname: "307510.cloudwaysapps.com", ip: "127.0.0.1"},
            memory_peak: 16.98,
            name: "App\\Jobs\\ExampleJob",
            project_id: 389,
            result: "success",
            timestamp: "2021-02-04 16:52:02",
            type: "process"
        },
        memory: 16.98,
        p50: 40.15,
        performance: [
            {label: "2021-02-03 16:00", value: 38, doc_count: 61},
            {label: "2021-02-03 17:00", value: 5, doc_count: 63},
            {label: "2021-02-03 18:00", value: 65, doc_count: 123},
            {label: "2021-02-03 19:00", value: 34, doc_count: 11},
            {label: "2021-02-03 20:00", value: 43, doc_count: 110},
            {label: "2021-02-03 21:00", value: 2, doc_count: 123},
            ...
        ],
        throughput: 60
    },
    
    ...
]

Transaction occurrences

POST http://app.inspector.dev/api/projects/:id/transactions/:group_hash/occurrences

Get the last occurrences of a specific transaction.

Path Parameters

NameTypeDescription

id*

Integer

Project's Identifier

group_hash*

String

The transaction group's identifier

Query Parameters

NameTypeDescription

filter.start*

Date

ISO-8601 date format

filter.end

Date

ISO-8601 date format

filter.from

Integer

The results are paginated 25 elements at a time. Use from to advance the starting point of the list.

Headers

NameTypeDescription

Authentication*

String

API key

[
    {
        duration: 164.22,
        group_hash: "7d8647ff14a84a458b0f6xxxxxxxxxxxx",
        memory_peak: 19.09,
        name: "GET /api/users",
        result: "success",
        timestamp: "2022-04-19 14:10:04",
        type: "process"
    },
    {
        ...
    },
]

Performance Distribution

POST http://app.inspector.dev/api/projects/:id/transactions/:group_hash/time-distribution

Performance distribution of a specific transaction.

Path Parameters

NameTypeDescription

id*

integer

Project's identifier

group_hash*

String

Transaction group's identifier

Headers

NameTypeDescription

Authentication*

string

API key

Request Body

NameTypeDescription

filter.start*

Date

ISO-8601 date format

filter.end

Date

ISO-8601 date format

[
  {
    "ms": 0,
    "occurrences": 29
  },
  {
    "ms": 152,
    "occurrences": 30
  },
  {
    "ms": 304,
    "occurrences": 1
  },
  {
    "ms": 456,
    "occurrences": 0
  },
  {
    "ms": 608,
    "occurrences": 0
  },
  {
    "ms": 760,
    "occurrences": 0
  },
  {
    "ms": 912,
    "occurrences": 0
  },
  {
    "ms": 1064,
    "occurrences": 0
  },
  {
    "ms": 1216,
    "occurrences": 0
  },
  {
    "ms": 1368,
    "occurrences": 0
  },
  {
    "ms": 1520,
    "occurrences": 0
  },
  {
    "ms": 1672,
    "occurrences": 0
  },
  {
    "ms": 1824,
    "occurrences": 0
  },
  {
    "ms": 1976,
    "occurrences": 0
  },
  {
    "ms: 2128,
    "occurrences": 0
  },
  {
    "ms": 2280,
    "occurrences": 0
  },
  {
    "ms": 2432,
    "occurrences": 0
  },
  {
    "ms": 2584,
    "occurrences": 0
  },
  {
    "ms": 2736,
    "occurrences": 0
  },
  {
    "ms": 2888,
    "occurrences": 0
  },
  {
    "ms": 3040,
    "occurrences": 0
  },
  {
    "ms": 3192,
    "occurrences": 0
  },
  {
    "ms": 5776,
    "occurrences": 1
  },
  {
    "ms": 5928,
    "occurrences": 5
  },
  {
    "ms": 6080,
    "occurrences": 9
  },
]

You can get the group_hash value of a specific transaction in the address bar of your browser navigating the detail page of the transaction of your interest.

Last updated