Infraon API Guide
Product DocsSchemaAuthentication
  • Welcome
    • Base URL
    • Authorization
    • Responses
  • Modules
    • Schema
    • Authentication
    • Announcement
    • API Registration
    • Async Tasks
    • BusinessRule
    • BusinessServiceConfiguration
    • Service Catalogue
    • CMDBBlacklistWhitelist
    • CMDBCategory
    • CMDBConsumables
    • Ux
    • CMDBSoftwareLicense
    • Cmdb
    • CMDBRelation
    • CMDBSoftware
    • ContractManagement
    • Department
    • Events
    • Field Configuration
    • IMACD
    • Knowledge Base
    • Leaves
    • Chat
    • Marketplace
    • APIViewSet
    • BeepViewSet
    • SMSviewset
    • Suppressedviewset
    • Organization Location
    • Partner
    • Predicted Events
    • Requester
    • Service Feasibility Requests
    • Role Profile
    • Tag
    • Service_outage
    • Teams
    • Telecom Settings
    • Trap Configurations
    • User Profile
    • Vendor Managemment
    • Association Events
    • Device Template
    • Discovery Configuration
    • Jobs
    • MIB Explorer
    • Seasonal Events
    • IPAM
    • Log Grok Pattern Configuration
    • Log Pipeline Configuration
    • Log Integraion
    • Log Search
    • CLI Download Jobs
    • Configuration Profiles
    • Configuration Policies
    • Configuration Rules
    • Configuration Search
    • Configuration Template
    • Configuration Trigger
    • Jobs Account Audit
    • Manage Vulnerabilities
    • OS Image Download
    • Rule Group
    • Configuration Upload Jobs
    • Work Flow Jobs
    • Change
    • Checklist
    • Incident
    • Problem
    • Release
    • Request Process
    • Task
    • Models
Powered by GitBook
On this page
  1. Modules

BusinessRule

PreviousAsync TasksNextBusinessServiceConfiguration

Gets a business_rule with the given id

get

This endpoint is used to fetch a business_rule details in the current organization

Authorizations
Path parameters
idstringRequired
Responses
200Success
application/json
get
GET /ux/common/business_rule/business_rule/{id}/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Accept: */*
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}

Deletes the business_rule with given id

delete

This endpoint is used to delete an existing business_rule for the current organization

Authorizations
Path parameters
idstringRequired
Responses
204
No response body
delete
DELETE /ux/common/business_rule/business_rule/{id}/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Accept: */*
204

No response body

No content

get

API endpoint that allows users to be viewed or edited.

Authorizations
Responses
200Success
application/json
get
GET /ux/common/business_rule/business_rule/download_rule_csv/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Accept: */*
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
get

API endpoint that allows users to be viewed or edited.

Authorizations
Responses
200Success
application/json
get
GET /ux/common/business_rule/business_rule/options/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Accept: */*
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
get

API endpoint that allows users to be viewed or edited.

Authorizations
Responses
200Success
application/json
get
GET /ux/common/business_rule/business_rule/rule_count/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Accept: */*
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
  • GETGets a list of business_rule
  • POSTCreates a new business_rule
  • GETGets a business_rule with the given id
  • PUTEdits the business_rule with given id
  • DELETEDeletes the business_rule with given id
  • POST/ux/common/business_rule/business_rule/create-csv/
  • POST/ux/common/business_rule/business_rule/csv_cols/
  • GET/ux/common/business_rule/business_rule/download_rule_csv/
  • POST/ux/common/business_rule/business_rule/multidelete/
  • GET/ux/common/business_rule/business_rule/options/
  • GET/ux/common/business_rule/business_rule/rule_count/
  • POST/ux/common/business_rule/business_rule/upload-csv/

Gets a list of business_rule

get

This endpoint is used to fetch all the business_rule in the current organization

Authorizations
Query parameters
items_per_pageintegerRequired

Items Per Page

pageintegerRequired

Page Number

reversebooleanOptional

Sorting Order

sortstringOptional

Sorting Key

Responses
200Success
application/json
get
GET /ux/common/business_rule/business_rule/?items_per_page=1&page=1 HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Accept: */*
200Success
[
  {
    "id": "text",
    "module_name": "text",
    "rule_id": "text",
    "name": "text",
    "type": {
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "is_enable": true,
    "is_override": true,
    "precedence": {
      "ANY_ADDITIONAL_PROPERTY": "anything"
    },
    "module_id": 1,
    "depth": 1,
    "description": "text",
    "is_deleted": true,
    "is_pre_configured": true
  }
]

Creates a new business_rule

post

This endpoint is used to save a new business_rule for the current organization

Authorizations
Body
Other propertiesanyOptional
Responses
201
No response body
post
POST /ux/common/business_rule/business_rule/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 48

{
  "business_rule": "business_rule1",
  "type": "User"
}
201

No response body

No content

Edits the business_rule with given id

put

This endpoint is used to edit an existing business_rule for the current organization

Authorizations
Path parameters
idstringRequired
Body

Serializer for Documents.

Recognized primitve fields:

* ``StringField``
* ``URLField``
* ``EmailField``
* ``IntField``
* ``LongField``
* ``FloatField``
* ``DecimalField``
* ``BooleanField``
* ``DateTimeField``
* ``ComplexDateTimeField``
* ``ObjectIdField``
* ``SequenceField`` (assumes it has integer counter)
* ``UUIDField``
* ``GeoPointField``
* ``GeoJsonBaseField`` (all those fields)
* ``DateField``

Compound fields: ListField and DictField are mapped to corresponding DRF fields, with respect to nested field specification.

The ReferenceField is handled like ForeignKey in DRF: there nested serializer autogenerated if serializer depth greater then 0, otherwise it's handled by it's own (results as str(id)).

For EmbeddedDocumentField also nested serializer autogenerated for non-zero depth, otherwise it is skipped. TODO: THIS IS PROBABLY WRONG AND SHOULD BE FIXED.

Generic fields GenericReferenceField and GenericEmbeddedDocumentField are handled by their own with corresponding serializer fields.

Not well supported or untested:

``FileField``
``ImageField``
``BinaryField``

All other fields are mapped to DocumentField and probably will work wrong.

idstringRead-onlyRequired
module_namestringRead-onlyRequired
rule_idstringOptional
namestring · max: 255Optional
is_enablebooleanOptionalDefault: true
is_overridebooleanOptional
module_idintegerOptional
depthintegerOptionalDefault: 1
descriptionstring | nullableOptional
is_deletedbooleanOptional
is_pre_configuredbooleanOptional
Responses
200Success
application/json
put
PUT /ux/common/business_rule/business_rule/{id}/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 254

{
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
post

API endpoint that allows users to be viewed or edited.

Authorizations
Body

Serializer for Documents.

Recognized primitve fields:

* ``StringField``
* ``URLField``
* ``EmailField``
* ``IntField``
* ``LongField``
* ``FloatField``
* ``DecimalField``
* ``BooleanField``
* ``DateTimeField``
* ``ComplexDateTimeField``
* ``ObjectIdField``
* ``SequenceField`` (assumes it has integer counter)
* ``UUIDField``
* ``GeoPointField``
* ``GeoJsonBaseField`` (all those fields)
* ``DateField``

Compound fields: ListField and DictField are mapped to corresponding DRF fields, with respect to nested field specification.

The ReferenceField is handled like ForeignKey in DRF: there nested serializer autogenerated if serializer depth greater then 0, otherwise it's handled by it's own (results as str(id)).

For EmbeddedDocumentField also nested serializer autogenerated for non-zero depth, otherwise it is skipped. TODO: THIS IS PROBABLY WRONG AND SHOULD BE FIXED.

Generic fields GenericReferenceField and GenericEmbeddedDocumentField are handled by their own with corresponding serializer fields.

Not well supported or untested:

``FileField``
``ImageField``
``BinaryField``

All other fields are mapped to DocumentField and probably will work wrong.

idstringRead-onlyRequired
module_namestringRead-onlyRequired
rule_idstringOptional
namestring · max: 255Optional
is_enablebooleanOptionalDefault: true
is_overridebooleanOptional
module_idintegerOptional
depthintegerOptionalDefault: 1
descriptionstring | nullableOptional
is_deletedbooleanOptional
is_pre_configuredbooleanOptional
Responses
200Success
application/json
post
POST /ux/common/business_rule/business_rule/create-csv/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 254

{
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
post

API endpoint that allows users to be viewed or edited.

Authorizations
Body

Serializer for Documents.

Recognized primitve fields:

* ``StringField``
* ``URLField``
* ``EmailField``
* ``IntField``
* ``LongField``
* ``FloatField``
* ``DecimalField``
* ``BooleanField``
* ``DateTimeField``
* ``ComplexDateTimeField``
* ``ObjectIdField``
* ``SequenceField`` (assumes it has integer counter)
* ``UUIDField``
* ``GeoPointField``
* ``GeoJsonBaseField`` (all those fields)
* ``DateField``

Compound fields: ListField and DictField are mapped to corresponding DRF fields, with respect to nested field specification.

The ReferenceField is handled like ForeignKey in DRF: there nested serializer autogenerated if serializer depth greater then 0, otherwise it's handled by it's own (results as str(id)).

For EmbeddedDocumentField also nested serializer autogenerated for non-zero depth, otherwise it is skipped. TODO: THIS IS PROBABLY WRONG AND SHOULD BE FIXED.

Generic fields GenericReferenceField and GenericEmbeddedDocumentField are handled by their own with corresponding serializer fields.

Not well supported or untested:

``FileField``
``ImageField``
``BinaryField``

All other fields are mapped to DocumentField and probably will work wrong.

idstringRead-onlyRequired
module_namestringRead-onlyRequired
rule_idstringOptional
namestring · max: 255Optional
is_enablebooleanOptionalDefault: true
is_overridebooleanOptional
module_idintegerOptional
depthintegerOptionalDefault: 1
descriptionstring | nullableOptional
is_deletedbooleanOptional
is_pre_configuredbooleanOptional
Responses
200Success
application/json
post
POST /ux/common/business_rule/business_rule/csv_cols/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 254

{
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
post

API endpoint that allows users to be viewed or edited.

Authorizations
Body

Serializer for Documents.

Recognized primitve fields:

* ``StringField``
* ``URLField``
* ``EmailField``
* ``IntField``
* ``LongField``
* ``FloatField``
* ``DecimalField``
* ``BooleanField``
* ``DateTimeField``
* ``ComplexDateTimeField``
* ``ObjectIdField``
* ``SequenceField`` (assumes it has integer counter)
* ``UUIDField``
* ``GeoPointField``
* ``GeoJsonBaseField`` (all those fields)
* ``DateField``

Compound fields: ListField and DictField are mapped to corresponding DRF fields, with respect to nested field specification.

The ReferenceField is handled like ForeignKey in DRF: there nested serializer autogenerated if serializer depth greater then 0, otherwise it's handled by it's own (results as str(id)).

For EmbeddedDocumentField also nested serializer autogenerated for non-zero depth, otherwise it is skipped. TODO: THIS IS PROBABLY WRONG AND SHOULD BE FIXED.

Generic fields GenericReferenceField and GenericEmbeddedDocumentField are handled by their own with corresponding serializer fields.

Not well supported or untested:

``FileField``
``ImageField``
``BinaryField``

All other fields are mapped to DocumentField and probably will work wrong.

idstringRead-onlyRequired
module_namestringRead-onlyRequired
rule_idstringOptional
namestring · max: 255Optional
is_enablebooleanOptionalDefault: true
is_overridebooleanOptional
module_idintegerOptional
depthintegerOptionalDefault: 1
descriptionstring | nullableOptional
is_deletedbooleanOptional
is_pre_configuredbooleanOptional
Responses
200Success
application/json
post
POST /ux/common/business_rule/business_rule/multidelete/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 254

{
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
post

API endpoint that allows users to be viewed or edited.

Authorizations
Body

Serializer for Documents.

Recognized primitve fields:

* ``StringField``
* ``URLField``
* ``EmailField``
* ``IntField``
* ``LongField``
* ``FloatField``
* ``DecimalField``
* ``BooleanField``
* ``DateTimeField``
* ``ComplexDateTimeField``
* ``ObjectIdField``
* ``SequenceField`` (assumes it has integer counter)
* ``UUIDField``
* ``GeoPointField``
* ``GeoJsonBaseField`` (all those fields)
* ``DateField``

Compound fields: ListField and DictField are mapped to corresponding DRF fields, with respect to nested field specification.

The ReferenceField is handled like ForeignKey in DRF: there nested serializer autogenerated if serializer depth greater then 0, otherwise it's handled by it's own (results as str(id)).

For EmbeddedDocumentField also nested serializer autogenerated for non-zero depth, otherwise it is skipped. TODO: THIS IS PROBABLY WRONG AND SHOULD BE FIXED.

Generic fields GenericReferenceField and GenericEmbeddedDocumentField are handled by their own with corresponding serializer fields.

Not well supported or untested:

``FileField``
``ImageField``
``BinaryField``

All other fields are mapped to DocumentField and probably will work wrong.

idstringRead-onlyRequired
module_namestringRead-onlyRequired
rule_idstringOptional
namestring · max: 255Optional
is_enablebooleanOptionalDefault: true
is_overridebooleanOptional
module_idintegerOptional
depthintegerOptionalDefault: 1
descriptionstring | nullableOptional
is_deletedbooleanOptional
is_pre_configuredbooleanOptional
Responses
200Success
application/json
post
POST /ux/common/business_rule/business_rule/upload-csv/ HTTP/1.1
Host: 
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 254

{
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}
200Success
{
  "id": "text",
  "module_name": "text",
  "rule_id": "text",
  "name": "text",
  "type": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "is_enable": true,
  "is_override": true,
  "precedence": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "module_id": 1,
  "depth": 1,
  "description": "text",
  "is_deleted": true,
  "is_pre_configured": true
}