Дерево страниц

Сравнение версий

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.
Комментарий: Published by Scroll Versions from space TMAG and version 7.13
Sv translation
languageru

Описание:  Список Список политик отсортированный по имени.

Метод:   GET GET

Ресурс: event/policy

Параметры:

  • start — – с какой позиции начать отдавать политики, по умолчанию 0;
  • limit — – сколько политик отдавать, по умолчанию 100, не может быть больше 1000.

Ответ: Список политик, описанный следующей JSON схемой отдачи списка каталогов:

{
Блок кода
languagetext
collapsetrue
{
    "$schema": "http://json-schema.org/draft-04/schema#",

    "type": "object",

    "properties": {

        "data": {

            "type": "array",

            "description": "Массив политик",

            "items": {

                "type": "object",

                "description": "Политика",

                "properties": {

                    "POLICY_ID": {

                        "type": "string",

                        "description": "Идентификатор"

                    },

                    "DISPLAY_NAME": {

                        "type": "string",

                        "description": "Имя"

                    },

                    "CREATE_DATE": {

                        "type": "string",

                        "description": "Дата создания"

                    },

                    "IS_DELETED": {

                        "type": "integer",

                        "description": "Удалена ли из активной конфигурации",

                        "enum": [
                            0,
                            1

                            0,
                            1
                        ]

                    }

                },

                "required": [

                    "POLICY_ID",

                    "DISPLAY_NAME",

                    "CREATE_DATE",

                    "IS_DELETED"

                ]

            }

        },

        "meta": {

            "description": "Дополнительные данные",

            "type": "object",

            "properties": {

                "totalCount": {

                    "type": "integer",

                    "description": "Общее количество политик"

                },

                "start": {

                    "type": "integer",

                    "description": "С какой позиции началось отдаваться"

                },

                "limit": {

                    "type": "integer",

                    "description": "Сколько всего отдалось"

                }

            },

            "required": [

                "totalCount",

                "start",

                "limit"

            ]

        }

    },

    "required": [

        "data",

        "meta"

    ]

}

Пример:

Блок кода
languagetext
titleЗапрос
collapsetrue
GET /xapi/event/policy?start=0&limit=10

X-API-Version:
 1
 1
X-API-CompanyId: iw

X-API-ImporterName: dome

X-API-Auth-Token: brse99dugp1cdbr69axz
Блок кода
languagetext
titleОтвет
collapsetrue
{

    "data": [{

        "POLICY_ID": "3D0F8CDAF9E74F82AC85EB32D12727A700000000",

        "DISPLAY_NAME": "Грифованная информация",

        "CREATE_DATE": "2016-05-12 10:24:41.342554",

        "IS_DELETED": 0

    }],

    "meta": {

        "totalCount": 1,

        "start": 0,

        "limit": 10

    }

}
Sv translation
languageen

escription:  The The list of policies sorted by name.

Method:   GET GET

Resource: event/policy

Parameters:

  • start —  a – a position from which to start returning policies, the default value is 0;
  • limit —  the – the number of policies to be returned; the default value is 100; cannot be more than  than 1000.

Response: The list of policies described with the following JSON Schema:

Блок кода
languagetext
titleJSON schema of returing the list of policies
:
collapse
 
true
{

     "$schema" :  "http://json-schema.org/draft-04/schema#" ,

     "type" :  "object" ,

     "properties" : {

         "data" : {

             "type" :  "array" ,

             "description" :  "Array of policies" ,

             "items" : {

                 "type" :  "object" ,

                 "description" :  "Policy" ,

                 "properties" : {

                     "POLICY_ID" : {

                         "type" :  "string" ,

                         "description" :  "Identifier"

                     },

                     "DISPLAY_NAME" : {

                         "type" :  "string" ,

                         "description" :  "Name"

                     },

                     "CREATE_DATE" : {

                         "type" :  "string" ,

                         "description" :  "Creation date"

                     },

                     "IS_DELETED" : {

                         "type" :  "integer" ,

                         "description" :  "Whether it is removed from the active configuration" ,

                         "enum" : [

                             0,

                             1

                         ]

                     }

                 },

                 "required" : [

                     "POLICY_ID" ,

                     "DISPLAY_NAME" ,

                     "CREATE_DATE" ,

                     "IS_DELETED"

                 ]

             }

         },

         "meta" : {

             "description" :  "Additional data" ,

             "type" :  "object" ,

             "properties" : {

                 "totalCount" : {

                     "type" :  "integer" ,

                     "description" :  "Total number of policies"

                 },

                 "start" : {

                     "type" :  "integer" ,

                     "description" :  "A position where to start returning policies"

                 },

                 "limit" : {

                     "type" :  "integer" ,

                     "description" :  "Total number of returned policies"

                 }

             },

             "required" : [

                 "totalCount" ,

                 "start" ,

                 "limit"

             ]

         }

     },

     "required" : [

         "data" ,

         "meta"

     ]

}
 

Example:

Блок кода
languagetext
titleQuery
collapse
 
true
GET /xapi/event/policy?start= 0 &limit= 10

X-API-Version:  1

X-API-CompanyId: iw

X-API-ImporterName: dome

X-API-Auth-Token: brse99dugp1cdbr69axz
 
Блок кода
languagetext
titleResponse
 
collapsetrue
{

     "data" : [{

         "POLICY_ID" :  "3D0F8CDAF9E74F82AC85EB32D12727A700000000" ,

         "DISPLAY_NAME" :  "Security labels" ,

         "CREATE_DATE" :  "2016-05-12 10:24:41.342554" ,

         "IS_DELETED" : 0

     }],

     "meta" : {

         "totalCount" : 1,

         "start" : 0,

         "limit" : 10

     }

}