0.2.2 • Published 7 years ago

mozaik-ext-dynatrace-api v0.2.2

Weekly downloads
-
License
MIT
Repository
github
Last release
7 years ago

Mozaïk DynaTrace Api widget

Use DynaTrace's Api to display graphs and notifications from DynaTrace onto Mozaïk dashboard framework.

Preview

value

DynaTrace Api widget Configuration

Api Configuration

api: {
  dynatrace: {
    apiToken: process.env.DYNATRACE_APITOKEN
  }
}

Running tests

The tests require an environment variable, to set this run the following command to run tests with an environment variable:

set DYNATRACE_APITOKEN='api_token'&&npm test

Example Dashboard Configuration

{
  type:               'dynatrace.graph',
  title:              'Global Web App Requests',
  chartType:          'ComboChart',
  seriesType:         'bars',
  isStacked:          true,
  baseUrl: 'https://example.live.dynatrace.com',
  datasets:[
        {
            query: [{
                relativeTime: 'Day',
                entity: 'SERVICE-E7EA44342E9D42A6',
                aggregationType: 'AVG',
                timeseriesId: 'com.dynatrace.builtin:service.responsetime'
            }],
            legend: 'PPWebAppIreland__4362 Response Time',
            colour: '#a100ff',
        },
        {
            query: [{
                relativeTime: 'Day',
                entity: 'SERVICE-9A91D2F733E6322A',
                aggregationType: 'AVG',
                timeseriesId: 'com.dynatrace.builtin:service.responsetime'
            }],
            legend: 'PPWebAppJapan Response Time',
            colour: '#00b2ff',
        }
    ],
  graphID:            "dynatrace5",
  heightpx:           "812.922px",
  xLabel:             "Time",
  yLabel:             "Requests", 
  minValue:           0,
  fontsize:           20,
  columns: 2, rows: 4,
  x: 0, y: 0
},
{
    type:               'dynatrace.webcheck',
    baseUrl:            'https://example.live.dynatrace.com',
    entityId:           'SYNTHETIC_TEST-0000004500008D13',
    columns: 1, rows: 1,
    x: 1, y: 0
}

Graph Parameters

For information on obtaining your baseUrl, relativeTime, entity and timeseriesId, see the dynatrace api documentation.

keyrequireddescriptionExamples
chartTypeyesThe chart type. The types of chart you can choose from can be found here'AreaChart'
baseUrlyesYour DynaTrace base url'https://example.live.dynatrace.com'
titleyesThe widget title'App Service 1 Requests (Last day/every hour):'
datasets.queryyesThe time series query
datasets.query.timeseriesIdyessee timeseriesId in the dynatrace documentation'com.dynatrace.builtin:service.responsetime'
datasets.query.startTimestampnosee startTimestamp in the dynatrace documentation'1504188877712'
datasets.query.endTimestampnosee endTimestamp in the dynatrace documentation'1504188877712'
datasets.query.relativeTimenosee relativeTime in the dynatrace documentation'day or hour or 2hours'
datasets.query.queryModenosee queryMode in the dynatrace documentation'series'
datasets.query.aggregationTypenosee aggregationType in the dynatrace documentation'AVG'
datasets.query.percentileyes if aggregationType = percentilesee percentile in the dynatrace documentation15
datasets.query.entitynosee entity in the dynatrace documentation'HOST-B64B6B1BB11E2244'
datasets.legendyeslegend display for the query'Web App Ireland Requests'
datasets.colournolegend and line colour for the query'#00a1ff'
graphIDyesChoose a unique ID for your graph'UniqueID23'
xlabelyesChoose a label name for the x-axis of the graph'Time'
yLabelyesChoose a label name for the y-axis of the graph'Requests'
slantedTextnoChoose whether to have the xAxis value labels slantedtrue or false
slantedTextAnglenoChoose the degree of angle for the slanteed xAxis value labels25
seriesTypenoChoose the way the data is displayed on the graph'bars'
fontsizenoChoose the size of the graph's text font10
pointsizenoChoose the size of the data points5
heightpxnoChoose the height of your graph, default being 300px200px
minValuenoThe minimum value allowed to be displayed on the graph0
maxValuenoThe maximum value allowed to be displayed on the graph100
isStackednoStacks the bar lines/area lines on top of each other, false by defaulttrue
isMicroSecondsnoSome timeseriesId return the data in microseconds, this converts that data into miliseconds, false by defaulttrue
reversePercentagenoReverses the percentage of some timeseries that return a percentagetrue

WebCheck Parameters

For information on obtaining your baseUrl and entityId, see the dynatrace api documentation.

keyrequireddescriptionExamples
baseUrlyesYour DynaTrace base url'https://example.live.dynatrace.com'
entityIdyesYour entity ID'SYNTHETIC_TEST-00000004500008D13'

Problems Parameters

For information on obtaining your baseUrl and entityId, see the dynatrace api documentation.

keyrequireddescriptionExamples
baseUrlyesYour DynaTrace base url'https://example.live.dynatrace.com'
0.2.2

7 years ago

0.2.1

7 years ago

0.2.0

7 years ago

0.1.9

7 years ago

0.1.8

7 years ago

0.1.7

7 years ago

0.1.6

7 years ago

0.1.5

7 years ago

0.1.4

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.11

7 years ago

0.0.10

7 years ago

0.0.9

7 years ago

0.0.8

7 years ago

0.0.7

7 years ago

0.0.6

7 years ago

0.0.5

7 years ago

0.0.4

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago