Cloudflare\Zone\WAF\Packages\Rules::rules PHP Метод

rules() публичный Метод

List rule (permission needed: #zone:read) Search, list, and filter rules within a package
public rules ( string $zone_id, string $package_id, string | null $description = null, object | null $mode = null, integer | null $priority = null, string | null $group_id = null, integer | null $page = null, integer | null $per_page = null, string | null $order = null, string | null $direction = null, string | null $match = null )
$zone_id string
$package_id string
$description string | null Public description of the rule
$mode object | null The rule mode
$priority integer | null The order in which the individual rule is executed within the related group
$group_id string | null WAF group identifier tag
$page integer | null Page number of paginated results
$per_page integer | null Number of rules per page
$order string | null Field to order rules by
$direction string | null Direction to order rules
$match string | null Whether to match all search requirements or at least one (any)
    public function rules($zone_id, $package_id, $description = null, $mode = null, $priority = null, $group_id = null, $page = null, $per_page = null, $order = null, $direction = null, $match = null)
    {
        $data = ['description' => $description, 'mode' => $mode, 'priority' => $priority, 'group_id' => $group_id, 'page' => $page, 'per_page' => $per_page, 'order' => $order, 'direction' => $direction, 'match' => $match];
        return $this->get('/zones/' . $zone_id . '/firewall/waf/packages/' . $package_id . '/rules', $data);
    }