@digitalocean/dots - v1.0.1
    Preparing search index...

    Interface RulesRequestBuilder

    Builds and executes requests for operations under /v2/firewalls/{firewall_id}/rules

    interface RulesRequestBuilder {
        delete(
            body: Firewall_rules,
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<void>;
        post(
            body: Firewall_rules,
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<void>;
        toDeleteRequestInformation(
            body: Firewall_rules,
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        toPostRequestInformation(
            body: Firewall_rules,
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        withUrl(rawUrl: string): RulesRequestBuilder;
    }

    Hierarchy

    Index

    Methods

    • To remove access rules from a firewall, send a DELETE request to/v2/firewalls/$FIREWALL_ID/rules. The body of the request may include aninbound_rules and/or outbound_rules attribute containing an array of rulesto be removed.No response body will be sent back, but the response code will indicatesuccess. Specifically, the response code will be a 204, which means that theaction was successful with no returned body data.

      Parameters

      • body: Firewall_rules

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<void>

      error when the service returns a 400 status code

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    post

    • post(
          body: Firewall_rules,
          requestConfiguration?: RequestConfiguration<object>,
      ): Promise<void>

      To add additional access rules to a firewall, send a POST request to/v2/firewalls/$FIREWALL_ID/rules. The body of the request may include aninbound_rules and/or outbound_rules attribute containing an array of rules tobe added.No response body will be sent back, but the response code will indicatesuccess. Specifically, the response code will be a 204, which means that theaction was successful with no returned body data.

      Parameters

      • body: Firewall_rules

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<void>

      error when the service returns a 400 status code

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    • To remove access rules from a firewall, send a DELETE request to/v2/firewalls/$FIREWALL_ID/rules. The body of the request may include aninbound_rules and/or outbound_rules attribute containing an array of rulesto be removed.No response body will be sent back, but the response code will indicatesuccess. Specifically, the response code will be a 204, which means that theaction was successful with no returned body data.

      Parameters

      • body: Firewall_rules

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation

    • To add additional access rules to a firewall, send a POST request to/v2/firewalls/$FIREWALL_ID/rules. The body of the request may include aninbound_rules and/or outbound_rules attribute containing an array of rules tobe added.No response body will be sent back, but the response code will indicatesuccess. Specifically, the response code will be a 204, which means that theaction was successful with no returned body data.

      Parameters

      • body: Firewall_rules

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation

    • Parameters

      • rawUrl: string

      Returns RulesRequestBuilder