Create Network Group icon

Create Network Group

Create a new network group

Overview

This node creates a new network group by sending a list of IP addresses or ranges to an external firewall API. It is useful for managing network security by grouping IPs into named collections, which can then be used in firewall rules or policies. For example, you might create a group called "Internal Networks" containing all your office subnets, simplifying rule management.

Properties

Name Meaning
Group Name The name of the network group to create (e.g., "Internal Networks").
IP Items A JSON array of IP addresses or CIDR ranges to include in the group (e.g., ["192.168.1.0/24", "10.0.0.1"]).

Output

The node outputs an array of JSON objects, one per input item, with the following structure:

  • success: Boolean indicating if the creation succeeded.
  • id: The unique identifier of the created network group (present if successful).
  • name: The name of the network group.
  • items: The array of IP addresses/ranges included in the group.
  • itemCount: Number of IP items in the group.
  • response: The full response from the firewall API.
  • error (if failed): Error message describing what went wrong.
  • statusCode (if failed): HTTP status code returned by the API.
  • response (if failed): Response body or data from the API error.

The node does not output binary data.

Dependencies

  • Requires an API key credential to authenticate with the external firewall API.
  • The API URL must be configured in the credentials.
  • The node sends HTTP POST requests to the endpoint /api/pt/ip/group on the configured API URL.
  • The request includes headers specifying content type as JSON and language preference.

Troubleshooting

  • Invalid JSON in IP Items: If the "IP Items" property contains invalid JSON or is not an array, the node will throw an error. Ensure the input is a valid JSON array of strings.
  • API Request Failures: Errors during the HTTP request (e.g., network issues, authentication failures, or server errors) will cause the node to fail unless "Continue On Fail" is enabled. Check the error message and HTTP status code for details.
  • Empty or Missing Group Name: The "Group Name" is required; leaving it empty will cause validation errors.
  • Malformed IP Addresses: The node does not validate IP formats beyond JSON parsing; ensure IP addresses and CIDR ranges are correctly formatted to avoid API rejection.

Links and References

  • CIDR Notation Explanation
  • Refer to your firewall API documentation for details on the /api/pt/ip/group endpoint and expected payloads.

Discussion