Create new Service object
  • 23 Jul 2025
  • 1 Minute to read
  • Contributors

    Create new Service object


      Article summary

      Post
      /v2.2/objects/services

      Required permission: ["objects:create"].

      Security
      HTTP
      Type bearer
      Body parameters
      object
      name
      string Required

      The name of the Objects

      Min length3
      Max length100
      Pattern^[a-zA-Z0-9_ ]+$
      description
      string
      protocols
      Array of object (ObjectsServicesProtocolRequestObj) Required
      AnyOf
      ObjectServiceProtocolTCPUDP
      object (ObjectServiceProtocolTCPUDP)
      OneOf
      ObjectServiceProtocolSingle
      object (ObjectServiceProtocolSingle)
      valueType
      string Required
      Valid values[ "single" ]
      value
      Array of integer (PortNumber) Required
      Min items1
      Max items1
      integer
      Minimum1
      Maximum65535
      ObjectServiceProtocolRange
      object (ObjectServiceProtocolRange)
      valueType
      string Required
      Valid values[ "range" ]
      value
      Array of integer (PortNumber) Required
      Min items2
      Max items2
      integer
      Minimum1
      Maximum65535
      ObjectServiceProtocolList
      object (ObjectServiceProtocolList)
      valueType
      string Required
      Valid values[ "list" ]
      value
      Array of integer (PortNumber) Required
      Min items1
      integer
      Minimum1
      Maximum65535
      ObjectServiceProtocolICMPRequest
      object (ObjectServiceProtocolICMPRequest)
      protocol
      string Required
      Valid values[ "icmp" ]
      protocolOptions
      integer Required

      -1 means 'any', the rest of the values are the RFC default ICMP parameters

      Valid values[ -1, 0, 3, 5, 8, 9, 10, 11, 12, 13, 14, 40, 42, 43 ]
      Responses
      201

      Created successfully

      Expand All
      object
      id
      string
      name
      string

      The name of the Objects

      Min length3
      Max length100
      Pattern^[a-zA-Z0-9_ ]+$
      description
      string
      protocols
      Array of object (ObjectsServicesProtocolResponseObj)
      AnyOf
      ObjectServiceProtocolTCPUDP
      object (ObjectServiceProtocolTCPUDP)
      OneOf
      ObjectServiceProtocolSingle
      object (ObjectServiceProtocolSingle)
      valueType
      string
      Valid values[ "single" ]
      value
      Array of integer (PortNumber)
      Min items1
      Max items1
      integer
      Minimum1
      Maximum65535
      ObjectServiceProtocolRange
      object (ObjectServiceProtocolRange)
      valueType
      string
      Valid values[ "range" ]
      value
      Array of integer (PortNumber)
      Min items2
      Max items2
      integer
      Minimum1
      Maximum65535
      ObjectServiceProtocolList
      object (ObjectServiceProtocolList)
      valueType
      string
      Valid values[ "list" ]
      value
      Array of integer (PortNumber)
      Min items1
      integer
      Minimum1
      Maximum65535
      ObjectServiceProtocolICMPResponse
      object (ObjectServiceProtocolICMPResponse)
      protocol
      string
      Valid values[ "icmp" ]
      protocolOptions
      object (ObjectServiceProtocolOptionsICMPresponse)

      -1 means 'any', the rest of the values are the RFC default ICMP parameters

      Valid values[ { "code": -1, "description": "Any" }, { "code": 0, "description": "Echo Reply" }, { "code": 3, "description": "Destination Unreachable" }, { "code": 5, "description": "Redirect" }, { "code": 8, "description": "Echo" }, { "code": 9, "description": "Router Advertisement" }, { "code": 10, "description": "Router Selection" }, { "code": 11, "description": "Time Exceeded" }, { "code": 12, "description": "Parameter Problem" }, { "code": 13, "description": "Timestamp" }, { "code": 14, "description": "Timestamp Reply" }, { "code": 40, "description": "Photuris" }, { "code": 42, "description": "Extended Echo Request" }, { "code": 43, "description": "Extended Echo Reply" } ]
      code
      integer
      description
      string
      401

      Unauthorized

      403

      Forbidden


      Was this article helpful?