<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Push a custom metric to a custom device to Dynatrace in Dynatrace API</title>
    <link>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109678#M514</link>
    <description>&lt;P&gt;Dear,&lt;/P&gt;
&lt;P&gt;I'm a new user, I want to post a custom metric to Dynatrace via API but I got some problems so need your help:&lt;/P&gt;
&lt;P data-unlink="true"&gt;- Firstly, I post a custom timeseries as the following: https://xxxxx.live.dynatrace.com/api-doc/index.jsp#/Timeseries/createCustomTimeseries&amp;nbsp;&lt;/P&gt;
&lt;P&gt;*timeseriesIdentifier: custom:phitestmachine&lt;/P&gt;
&lt;P&gt;Body:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;  "displayName": "PhiTestMachine",&lt;BR /&gt;  "types": ["F5-Firewall"]&lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;Response:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;    "timeseriesId": "custom:phitestmachine",&lt;BR /&gt;    "displayName": "PhiTestMachine",&lt;BR /&gt;    "dimensions": [&lt;BR /&gt;        "CUSTOM_DEVICE"&lt;BR /&gt;    ],&lt;BR /&gt;    "unit": "Count (count)",&lt;BR /&gt;    "detailedSource": "API",&lt;BR /&gt;    "types": [&lt;BR /&gt;        "F5-Firewall"&lt;BR /&gt;    ],&lt;BR /&gt;    "aggregationTypes": [&lt;BR /&gt;        "AVG",&lt;BR /&gt;        "SUM",&lt;BR /&gt;        "MIN",&lt;BR /&gt;        "MAX"&lt;BR /&gt;    ],&lt;BR /&gt;    "filter": "CUSTOM"&lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;- Next I create a custom device as the following: &lt;A href="https://www.dynatrace.com/support/help/dynatrace-api/environment/topology-and-smartscape-api/topology-smartscape-api-custom-device/create-custom-device/," target="_blank" rel="noopener"&gt;https://www.dynatrace.com/support/help/dynatrace-a...&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;entityAlias: PhiTestMachine&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Body:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;  "displayName" : "F5 Firewall 24",&lt;BR /&gt;  "ipAddresses" : ["172.16.115.211"],&lt;BR /&gt;  "listenPorts" : ["9999"],&lt;BR /&gt;  "type" : "F5-Firewall",&lt;BR /&gt;  "favicon" : "http://assets.dynatrace.com/global/icons/f5.png",&lt;BR /&gt;  "configUrl" : "http://192.128.0.1:8080",&lt;BR /&gt;  "tags": [&lt;BR /&gt;    "REST example"&lt;BR /&gt;  ],&lt;BR /&gt;  "properties" : {&lt;BR /&gt;    "Sample Property 1": "Sample value 1"    &lt;BR /&gt;  }  &lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;Response:&lt;/P&gt;
&lt;PRE&gt;CUSTOM_DEVICE-75AB78865A2AF396&lt;/PRE&gt;
&lt;P&gt;- Now I post a custom metric device as the following: &lt;A href="https://www.dynatrace.com/support/help/dynatrace-api/environment/topology-and-smartscape-api/topology-smartscape-api-custom-device/report-metric-to-custom-device/?tabgroup-66=json-model&amp;amp;post-custom-device-response=response-parameters," target="_blank" rel="noopener"&gt;https://www.dynatrace.com/support/help/dynatrace-a...&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;entityAlias: PhiTestMachine&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Body:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;"tags": [&lt;BR /&gt;    "tag2"&lt;BR /&gt;  ],&lt;BR /&gt;  "type": "F5-Firewall",&lt;BR /&gt;  "properties" : {    &lt;BR /&gt;    "Sample Property 2": "Sample value 2"&lt;BR /&gt;  },&lt;BR /&gt;  "series" : [&lt;BR /&gt;    {&lt;BR /&gt;      "timeseriesId" : "custom:phitestmachine",&lt;BR /&gt;      "dimensions" : {&lt;BR /&gt;        "CUSTOM_DEVICE" : "macbook pro"  &lt;BR /&gt;      },&lt;BR /&gt;      "dataPoints" : [&lt;BR /&gt;        [ 1539860400000, 460 ],&lt;BR /&gt;        [ 1539860460000, 456 ]&lt;BR /&gt;       ]&lt;BR /&gt;    },&lt;BR /&gt;    {&lt;BR /&gt;     "timeseriesId" : "custom:phitestmachine",&lt;BR /&gt;      "dimensions" : {&lt;BR /&gt;        "CUSTOM_DEVICE" : "macbook pro"  &lt;BR /&gt;      },&lt;BR /&gt;      "dataPoints" : [&lt;BR /&gt;        [ 1539860430000, 439 ],&lt;BR /&gt;        [ 1539860490000, 460 ]&lt;BR /&gt;       ]&lt;BR /&gt;    }&lt;BR /&gt;  ]&lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;Response:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;    "error": {&lt;BR /&gt;        "code": 400,&lt;BR /&gt;        "message": "Constraints violated.",&lt;BR /&gt;        "constraintViolations": [&lt;BR /&gt;            {&lt;BR /&gt;                "path": "series[0].dimensions",&lt;BR /&gt;                "message": "Dimensions don't match dimensions specified in configuration. No extra dimensions specified in configuration.",&lt;BR /&gt;                "parameterLocation": "PAYLOAD_BODY",&lt;BR /&gt;                "location": null&lt;BR /&gt;            }&lt;BR /&gt;        ]&lt;BR /&gt;    }&lt;BR /&gt;}	&lt;/PRE&gt;
&lt;P&gt;So I'm not sure what is the dimensions specified in configuration? The custom metric I post at the beginning returned object has dimensions key is " CUSTOM_DEVICE". Could you help me to have a look at this.&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 29 May 2023 09:32:44 GMT</pubDate>
    <dc:creator>phile</dc:creator>
    <dc:date>2023-05-29T09:32:44Z</dc:date>
    <item>
      <title>Push a custom metric to a custom device to Dynatrace</title>
      <link>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109678#M514</link>
      <description>&lt;P&gt;Dear,&lt;/P&gt;
&lt;P&gt;I'm a new user, I want to post a custom metric to Dynatrace via API but I got some problems so need your help:&lt;/P&gt;
&lt;P data-unlink="true"&gt;- Firstly, I post a custom timeseries as the following: https://xxxxx.live.dynatrace.com/api-doc/index.jsp#/Timeseries/createCustomTimeseries&amp;nbsp;&lt;/P&gt;
&lt;P&gt;*timeseriesIdentifier: custom:phitestmachine&lt;/P&gt;
&lt;P&gt;Body:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;  "displayName": "PhiTestMachine",&lt;BR /&gt;  "types": ["F5-Firewall"]&lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;Response:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;    "timeseriesId": "custom:phitestmachine",&lt;BR /&gt;    "displayName": "PhiTestMachine",&lt;BR /&gt;    "dimensions": [&lt;BR /&gt;        "CUSTOM_DEVICE"&lt;BR /&gt;    ],&lt;BR /&gt;    "unit": "Count (count)",&lt;BR /&gt;    "detailedSource": "API",&lt;BR /&gt;    "types": [&lt;BR /&gt;        "F5-Firewall"&lt;BR /&gt;    ],&lt;BR /&gt;    "aggregationTypes": [&lt;BR /&gt;        "AVG",&lt;BR /&gt;        "SUM",&lt;BR /&gt;        "MIN",&lt;BR /&gt;        "MAX"&lt;BR /&gt;    ],&lt;BR /&gt;    "filter": "CUSTOM"&lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;- Next I create a custom device as the following: &lt;A href="https://www.dynatrace.com/support/help/dynatrace-api/environment/topology-and-smartscape-api/topology-smartscape-api-custom-device/create-custom-device/," target="_blank" rel="noopener"&gt;https://www.dynatrace.com/support/help/dynatrace-a...&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;entityAlias: PhiTestMachine&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Body:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;  "displayName" : "F5 Firewall 24",&lt;BR /&gt;  "ipAddresses" : ["172.16.115.211"],&lt;BR /&gt;  "listenPorts" : ["9999"],&lt;BR /&gt;  "type" : "F5-Firewall",&lt;BR /&gt;  "favicon" : "http://assets.dynatrace.com/global/icons/f5.png",&lt;BR /&gt;  "configUrl" : "http://192.128.0.1:8080",&lt;BR /&gt;  "tags": [&lt;BR /&gt;    "REST example"&lt;BR /&gt;  ],&lt;BR /&gt;  "properties" : {&lt;BR /&gt;    "Sample Property 1": "Sample value 1"    &lt;BR /&gt;  }  &lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;Response:&lt;/P&gt;
&lt;PRE&gt;CUSTOM_DEVICE-75AB78865A2AF396&lt;/PRE&gt;
&lt;P&gt;- Now I post a custom metric device as the following: &lt;A href="https://www.dynatrace.com/support/help/dynatrace-api/environment/topology-and-smartscape-api/topology-smartscape-api-custom-device/report-metric-to-custom-device/?tabgroup-66=json-model&amp;amp;post-custom-device-response=response-parameters," target="_blank" rel="noopener"&gt;https://www.dynatrace.com/support/help/dynatrace-a...&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;entityAlias: PhiTestMachine&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Body:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;"tags": [&lt;BR /&gt;    "tag2"&lt;BR /&gt;  ],&lt;BR /&gt;  "type": "F5-Firewall",&lt;BR /&gt;  "properties" : {    &lt;BR /&gt;    "Sample Property 2": "Sample value 2"&lt;BR /&gt;  },&lt;BR /&gt;  "series" : [&lt;BR /&gt;    {&lt;BR /&gt;      "timeseriesId" : "custom:phitestmachine",&lt;BR /&gt;      "dimensions" : {&lt;BR /&gt;        "CUSTOM_DEVICE" : "macbook pro"  &lt;BR /&gt;      },&lt;BR /&gt;      "dataPoints" : [&lt;BR /&gt;        [ 1539860400000, 460 ],&lt;BR /&gt;        [ 1539860460000, 456 ]&lt;BR /&gt;       ]&lt;BR /&gt;    },&lt;BR /&gt;    {&lt;BR /&gt;     "timeseriesId" : "custom:phitestmachine",&lt;BR /&gt;      "dimensions" : {&lt;BR /&gt;        "CUSTOM_DEVICE" : "macbook pro"  &lt;BR /&gt;      },&lt;BR /&gt;      "dataPoints" : [&lt;BR /&gt;        [ 1539860430000, 439 ],&lt;BR /&gt;        [ 1539860490000, 460 ]&lt;BR /&gt;       ]&lt;BR /&gt;    }&lt;BR /&gt;  ]&lt;BR /&gt;}&lt;/PRE&gt;
&lt;P&gt;Response:&lt;/P&gt;
&lt;PRE&gt;{&lt;BR /&gt;    "error": {&lt;BR /&gt;        "code": 400,&lt;BR /&gt;        "message": "Constraints violated.",&lt;BR /&gt;        "constraintViolations": [&lt;BR /&gt;            {&lt;BR /&gt;                "path": "series[0].dimensions",&lt;BR /&gt;                "message": "Dimensions don't match dimensions specified in configuration. No extra dimensions specified in configuration.",&lt;BR /&gt;                "parameterLocation": "PAYLOAD_BODY",&lt;BR /&gt;                "location": null&lt;BR /&gt;            }&lt;BR /&gt;        ]&lt;BR /&gt;    }&lt;BR /&gt;}	&lt;/PRE&gt;
&lt;P&gt;So I'm not sure what is the dimensions specified in configuration? The custom metric I post at the beginning returned object has dimensions key is " CUSTOM_DEVICE". Could you help me to have a look at this.&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 May 2023 09:32:44 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109678#M514</guid>
      <dc:creator>phile</dc:creator>
      <dc:date>2023-05-29T09:32:44Z</dc:date>
    </item>
    <item>
      <title>Re: Push a custom metric to a custom device to dynatrace</title>
      <link>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109679#M515</link>
      <description>&lt;P&gt;You don't have to specify the primary dimension, which is the custom device as you already have to put that id in the POST path. So just leave the dimensions set empty within your POST body.&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 03 Dec 2018 07:11:46 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109679#M515</guid>
      <dc:creator>wolfgang_beer</dc:creator>
      <dc:date>2018-12-03T07:11:46Z</dc:date>
    </item>
    <item>
      <title>Re: Push a custom metric to a custom device to dynatrace</title>
      <link>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109680#M516</link>
      <description>&lt;P&gt;Can you please advise with an example as to how I could go about omitting "primary dimension".&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Sun, 26 May 2019 22:03:39 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Dynatrace-API/Push-a-custom-metric-to-a-custom-device-to-Dynatrace/m-p/109680#M516</guid>
      <dc:creator>thobishim</dc:creator>
      <dc:date>2019-05-26T22:03:39Z</dc:date>
    </item>
  </channel>
</rss>

