| 両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン |
| ja:documentation:pandorafms:technical_reference:02_annex_externalapi [2026/06/06 23:06] – [set update_agent_field] junichi | ja:documentation:pandorafms:technical_reference:02_annex_externalapi [2026/06/06 23:13] (現在) – [set create_alerts_policy] junichi |
|---|
| * <disabled> | * <disabled> |
| * <description> | * <description> |
| |
| 書式: | |
| |
| * op=set (必須) | * op=set (必須) |
| == set create_alerts_policy == | == set create_alerts_policy == |
| |
| >= 7.0. 725 | To create standard or external alerts in a monitoring policy. |
| |
| ポリシーアラートを作成します。 | 監視ポリシーで標準アラートまたは外部アラートを作成します。 |
| |
| * 存在するポリシー ID を指定する必要があります。 | [[#ks2|Call syntax]]: |
| * 通常のタイプの場合、ポリシーモジュールIDを指定する必要があります。 | |
| * 存在するテンプレートIDを指定する必要があります。 | |
| * 外部かどうかを 0(通常)、1(外部) で設定します。デフォルトは、通常の 0 です。 | |
| * 外部タイプ(1) の場合は、名前を指定する必要があります。 | |
| |
| 0(失敗) または、ポリシーに追加したアラートID(成功) を返します。 | [[#ks2|書式]]: |
| |
| 書式: | **To create [[:en:documentation:pandorafms:complex_environments_and_optimization:02_policy#ks4_6|standard alerts]]**: |
| |
| * op=set | **[[:ja:documentation:pandorafms:complex_environments_and_optimization:02_policy#ks4_6|標準アラート]]を作成するには**: |
| * op2=create_alerts_policy | |
| * id=ポリシーID | |
| * id2=ポリシーモジュールID | |
| * other=ポリシーモジュールID|テンプレートID|0 または 1|モジュール名 | |
| * other_mode=url_encode_separator_| | |
| * return_type=(string, csv, json). | |
| |
| **例** | * ''op=set'' (required). |
| <code> | * ''op2=create_alerts_policy'' (required). |
| | * ''id='' A policy identifier that must exist (required). |
| | * ''return_type'' Output format (optional): STRING, CSV o JSON. |
| | * ''other_mode=url_encode_separator_|''. |
| | * ''other='' With the following fields properly delimited: |
| |
| http://localhost/pandora_console/include/api.php?op=set&op2=create_alerts_policy&apipass=1234&user=admin&pass=pandora&return_type=string&id=2&other=0|2|1|cpu%20load&other_mode=url_encode_separator_| | * ''op=set'' (必須)。 |
| | * ''op2=create_alerts_policy'' (必須)。 |
| | * ''id='' ポリシー識別子 (必須)。 |
| | * ''return_type'' 出力形式 (オプション):STRING、CSV、または JSON。 |
| | * ''other_mode=url_encode_separator_|''。 |
| |
| | - Existing module ID (required). |
| | - A template identifier that must exist (required). |
| | - ''0'' It is explicitly stated that this is a standard alert (optional); this parameter can also be omitted, as the default value is zero. |
| | - This parameter is omitted when creating a standard alert, as it will be generated using the name of the existing module identifier provided. |
| | |
| | - 既存のモジュールID(必須)。 |
| | - 必ず存在するテンプレート識別子(必須)。 |
| | - ''0'' は、これが標準アラートであることを明示的に示しています(オプション)。デフォルト値はゼロなので、このパラメータは省略できます。 |
| | - 標準アラートを作成する場合、このパラメータは省略されます。指定された既存のモジュール識別子の名前を使用してアラートが生成されるためです。 |
| | |
| | **To create [[:en:documentation:pandorafms:complex_environments_and_optimization:02_policy#ks4_7|external alerts]]**: |
| | |
| | **[[:ja:documentation:pandorafms:complex_environments_and_optimization:02_policy#ks4_7|外部アラート]]を作成するには**: |
| | |
| | * ''op=set'' (required). |
| | * ''op2=create_alerts_policy'' (required). |
| | * ''id='' A policy identifier that must exist (required). |
| | * ''return_type'' Output format (optional): STRING, CSV o JSON. |
| | * ''other_mode=url_encode_separator_|''. |
| | * ''other='' With the following fields properly delimited: |
| | |
| | * ''op=set'' (必須)。 |
| | * ''op2=create_alerts_policy'' (必須)。 |
| | * ''id='' ポリシー識別子 (必須)。 |
| | * ''return_type'' 出力形式 (オプション):STRING、CSV、またはJSON。 |
| | * ''other_mode=url_encode_separator_|''。 |
| | * ''other='' 以下のフィールドを適切に区切り文字で区切ってください。 |
| | |
| | - ''0'' Since the external alert does not require an existing module to be generated (optional). |
| | - A template identifier that must exist (required). |
| | - ''1'' It is explicitly stated that this is an external alert (mandatory). |
| | - Module name for the external alert (required). |
| | |
| | - ''0'' 外部アラートは既存のモジュールを生成する必要がないため(オプション)。 |
| | - 必ず存在しなければならないテンプレート識別子(必須)。 |
| | - ''1'' これが外部アラートであることを明示的に指定する(必須)。 |
| | - 外部アラートのモジュール名(必須)。 |
| | |
| | **Result**: |
| | |
| | **結果**: |
| | |
| | Returns '0' (//false//) or the identifier of the alert added to the policy (//true//). |
| | |
| | '0' (//false//) またはポリシーに追加されたアラートの識別子 (//true//) を返します。 |
| | |
| | **Example of a standard alert (see [[#ks2|call syntax]]):** |
| | |
| | **標準アラートの例([[#ks2|書式]]を参照):** |
| | |
| | <code bash> |
| | …/include/api.php?op=set&op2=create_alerts_policy&apipass=1234&user=admin&pass=pandora&return_type=string&id=7&other=39|1|0|&other_mode=url_encode_separator_| |
| | </code> |
| | |
| | **Example of an external alert (see [[#ks2|call syntax]]):** |
| | |
| | **外部アラートの例([[#ks2|書式]]を参照):** |
| | |
| | <code bash> |
| | …/include/api.php?op=set&op2=create_alerts_policy&apipass=1234&user=admin&pass=pandora&return_type=string&id=8&other=0|1|1|ESET%20logd&other_mode=url_encode_separator_| |
| </code> | </code> |
| |