Skip to content

非公式 / UnofficialCloudflare, Inc. 非提携。アカウント情報は入力しないでください。Not affiliated with Cloudflare, Inc. Do not enter Cloudflare credentials here.Official docsこのサイトについてプライバシー

Programmable Flow Protection

最終更新 Markdown で表示Agent セットアップ

Cloudflare API を使って Programmable Flow Protection を設定します。

API 呼び出しの例は、よく使う API 呼び出し を参照してください。

エンドポイント

次に示す Programmable Flow Protection の API エンドポイントを、Cloudflare API のベース URL に連結すると、完全なエンドポイントになります。

https://api.cloudflare.com/client/v4

{account_id} 引数は アカウント ID(16 進文字列)です。この値は Cloudflare ダッシュボードで確認できます。

以降の表は、利用できる操作の要約です。

プログラム操作

操作 メソッドとエンドポイント / 説明
プログラムを一覧する

GET accounts/{account_id}/magic/programmable_flow_protection/configs/programs

アカウント内のすべての Programmable Flow Protection プログラムを取得します。
プログラムをアップロードする

POST accounts/{account_id}/magic/programmable_flow_protection/configs/programs

新しいプログラムをアカウントにアップロードします。人が読めるプログラム名を指定するには、任意の X-Program-Name ヘッダーを含めます。省略すると、API がプログラム名として UUID を生成します。
プログラムを取得する

GET accounts/{account_id}/magic/programmable_flow_protection/configs/programs/{program_id}

既存プログラムの詳細を取得します。
プログラムを更新する

PATCH accounts/{account_id}/magic/programmable_flow_protection/configs/programs/{program_id}

既存プログラムを更新します。
プログラムを削除する

DELETE accounts/{account_id}/magic/programmable_flow_protection/configs/programs/{program_id}

アカウントから既存プログラムを削除します。
すべてのプログラムを削除する

DELETE accounts/{account_id}/magic/programmable_flow_protection/configs/programs

アカウントから既存プログラムをすべて削除します。

ルール操作

操作 メソッドとエンドポイント / 説明
ルールを一覧する

GET accounts/{account_id}/magic/programmable_flow_protection/configs/rules

アカウント内のすべての Programmable Flow Protection ルールを取得します。
ルールを作成する

POST accounts/{account_id}/magic/programmable_flow_protection/configs/rules

アカウントに新しいルールを作成します。
ルールを取得する

GET accounts/{account_id}/magic/programmable_flow_protection/configs/rules/{rule_id}

既存ルールの詳細を取得します。
ルールを更新する

PATCH accounts/{account_id}/magic/programmable_flow_protection/configs/rules/{rule_id}

アカウント内の既存ルールを更新します。
ルールを削除する

DELETE accounts/{account_id}/magic/programmable_flow_protection/configs/rules/{rule_id}

アカウントから既存ルールを削除します。
すべてのルールを削除する

DELETE accounts/{account_id}/magic/programmable_flow_protection/configs/rules

アカウントから既存ルールをすべて削除します。

デバッグ操作

操作 メソッドとエンドポイント / 説明
PCAP でデバッグする

POST accounts/{account_id}/magic/programmable_flow_protection/configs/programs/{program_id}/pcap

PCAP ファイルに対してプログラムを実行し、プログラムの判定を付与した注釈付き PCAP を返します。

ページネーション

項目一覧を返す API 操作はページネーションを使います。利用できるページネーション用クエリパラメーターの詳細は、ページネーション を参照してください。

役に立ちましたか?