• EnglishEspañol日本語한국어Português
  • ログイン今すぐ開始

この機械翻訳は、参考として提供されています。

In the event of any inconsistency between the English version and the translated version, the English versionwill take priority. Please visit this page for more information.

問題を作成する

ラベル用RESTAPI(EOL)

既存ラベルの一覧表示

アカウントに存在するラベルを一覧表示するには、このコマンドを使用します。

curl 'https://api.newrelic.com/v2/labels.json' \
-H "Api-Key:NEW_RELIC_USER_KEY" -i

出力を見る

このレーベルのアウトプットには

  • ラベルの完全なキー名(たとえば、 Staging:Test1 )、およびキーのコンポーネントと名前
  • 各カテゴリのラベルのアプリケーションhealth_status (赤、オレンジ、緑、灰色)とアプリケーションID
  • このラベルが付いているアプリ。たとえば、ラベルStaging:Test1が1つのアプリケーション(4937390)と2つのホスト(3801143と5879721)に適用されています

ラベルリストの出力は以下のようになります。

{
"labels": [
{
"key": "Production:Main",
"category": "Production",
"name": "Main",
"application_health_status": {
"green": [],
"orange": [],
"red": [],
"gray": []
},
"links": {
"applications": [],
}
},
{
"key": "Staging:Test1",
"category": "Staging",
"name": "Test1",
"application_health_status": {
"green": [],
"orange": [],
"red": [
4937390
],
"gray": []
},
"links": {
"applications": [
4937390
],
}
},
...
}
Copyright © 2024 New Relic株式会社。

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.