create_service_object
Adds a FortiGate service object that defines protocols and ports for firewall policies. Provide device ID, service data, and optional VDOM to create TCP, UDP, or ICMP services.
Instructions
Create a new service object on a FortiGate device.
This tool adds a new network service object that defines protocols and ports for use in firewall policies.
Parameters:
device_id: Identifier of the FortiGate device
service_data: Service object configuration as JSON
vdom: Virtual Domain name (optional, uses device default)
Service data should include:
name: Service name
protocol: TCP, UDP, or ICMP
tcp-portrange: TCP port range (for TCP)
udp-portrange: UDP port range (for UDP)
comment: Optional description
Returns:
Creation status
Service configuration summary
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| vdom | No | Virtual Domain | |
| device_id | Yes | FortiGate device identifier | |
| service_data | Yes | Service object configuration |