{
  "files": [
    {
      "name": "deviceapis/device/v1/deviceapis_device_reader_v1.proto",
      "description": "Сервис считывателей",
      "package": "deviceapis.device.v1",
      "hasEnums": false,
      "hasExtensions": false,
      "hasMessages": true,
      "hasServices": true,
      "enums": [
        {
          "name": "DirectionType",
          "longName": "Reader.DirectionType",
          "fullName": "deviceapis.device.v1.Reader.DirectionType",
          "description": "Направление",
          "values": [
            {
              "name": "DIRECTION_TYPE_UNKNOWN",
              "number": "0",
              "description": "Значение не указано"
            },
            {
              "name": "IN",
              "number": "1",
              "description": "Вход"
            },
            {
              "name": "OUT",
              "number": "2",
              "description": "Выход"
            }
          ]
        }
      ],
      "extensions": [],
      "messages": [
        {
          "name": "EditReaderRequest",
          "longName": "EditReaderRequest",
          "fullName": "deviceapis.device.v1.EditReaderRequest",
          "description": "Запрос редактирования считывателя",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "data",
              "description": "Считыватель",
              "label": "",
              "type": "Reader",
              "longType": "Reader",
              "fullType": "deviceapis.device.v1.Reader",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "options": {
                "google.api.field_behavior": {
                  "options": [
                    "REQUIRED"
                  ]
                }
              },
              "number": 1
            },
            {
              "name": "update_mask",
              "description": "Маска полей обновления",
              "label": "",
              "type": "FieldMask",
              "longType": "google.protobuf.FieldMask",
              "fullType": "google.protobuf.FieldMask",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 2
            }
          ]
        },
        {
          "name": "EditReaderResponse",
          "longName": "EditReaderResponse",
          "fullName": "deviceapis.device.v1.EditReaderResponse",
          "description": "Ответ на запрос редактирования считывателя",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": true,
          "extensions": [],
          "fields": [
            {
              "name": "error",
              "description": "Ошибка",
              "label": "",
              "type": "Error",
              "longType": "EditReaderResponse.Error",
              "fullType": "deviceapis.device.v1.EditReaderResponse.Error",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "type",
              "defaultValue": "",
              "number": 1
            }
          ]
        },
        {
          "name": "Error",
          "longName": "EditReaderResponse.Error",
          "fullName": "deviceapis.device.v1.EditReaderResponse.Error",
          "description": "Ошибка запроса",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": true,
          "extensions": [],
          "fields": [
            {
              "name": "validation",
              "description": "Ошибка валидации",
              "label": "",
              "type": "ValidationError",
              "longType": "ValidationError",
              "fullType": "deviceapis.device.v1.ValidationError",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "reason",
              "defaultValue": "",
              "number": 1
            },
            {
              "name": "saving",
              "description": "Ошибка сохранения",
              "label": "",
              "type": "SavingError",
              "longType": "Reader.SavingError",
              "fullType": "deviceapis.device.v1.Reader.SavingError",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "reason",
              "defaultValue": "",
              "number": 2
            }
          ]
        },
        {
          "name": "GetReaderRequest",
          "longName": "GetReaderRequest",
          "fullName": "deviceapis.device.v1.GetReaderRequest",
          "description": "Запрос получения считывателя",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "id",
              "description": "Идентификатор.\nid=100 - Считыватель внутренний.\nid=1 - Считыватель внешний №1.\nid=2 - Считыватель внешний №2 и тд",
              "label": "",
              "type": "int32",
              "longType": "int32",
              "fullType": "int32",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "options": {
                "google.api.field_behavior": {
                  "options": [
                    "REQUIRED"
                  ]
                }
              },
              "number": 1
            }
          ]
        },
        {
          "name": "GetReaderResponse",
          "longName": "GetReaderResponse",
          "fullName": "deviceapis.device.v1.GetReaderResponse",
          "description": "Ответ на запрос получения считывателя",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": true,
          "extensions": [],
          "fields": [
            {
              "name": "data",
              "description": "Считыватель",
              "label": "",
              "type": "Reader",
              "longType": "Reader",
              "fullType": "deviceapis.device.v1.Reader",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "type",
              "defaultValue": "",
              "number": 1
            }
          ]
        },
        {
          "name": "Reader",
          "longName": "Reader",
          "fullName": "deviceapis.device.v1.Reader",
          "description": "Считыватель",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "id",
              "description": "Идентификатор.\nid=100 - Считыватель внутренний.\nid=1 - Считыватель внешний №1.\nid=2 - Считыватель внешний №2 и тд",
              "label": "",
              "type": "int32",
              "longType": "int32",
              "fullType": "int32",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "options": {
                "google.api.field_behavior": {
                  "options": [
                    "REQUIRED"
                  ]
                }
              },
              "number": 1
            },
            {
              "name": "encryption_profile_ids",
              "description": "Список идентификаторов профилей шифрования",
              "label": "repeated",
              "type": "int32",
              "longType": "int32",
              "fullType": "int32",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "options": {
                "google.api.field_behavior": {
                  "options": [
                    "REQUIRED"
                  ]
                }
              },
              "number": 2
            },
            {
              "name": "relay_indexes",
              "description": "Список идентификаторов реле.\nДиапазон: 1..64",
              "label": "repeated",
              "type": "int32",
              "longType": "int32",
              "fullType": "int32",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "options": {
                "google.api.field_behavior": {
                  "options": [
                    "REQUIRED"
                  ]
                }
              },
              "number": 3
            },
            {
              "name": "is_none_secure_mode",
              "description": "Считыватель работает не в безопасном режиме (по UID)",
              "label": "",
              "type": "bool",
              "longType": "bool",
              "fullType": "bool",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "options": {
                "google.api.field_behavior": {
                  "options": [
                    "REQUIRED"
                  ]
                }
              },
              "number": 4
            },
            {
              "name": "direction_type",
              "description": "Направление",
              "label": "",
              "type": "DirectionType",
              "longType": "Reader.DirectionType",
              "fullType": "deviceapis.device.v1.Reader.DirectionType",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 5
            }
          ]
        },
        {
          "name": "SavingError",
          "longName": "Reader.SavingError",
          "fullName": "deviceapis.device.v1.Reader.SavingError",
          "description": "Ошибки сохранения",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": true,
          "extensions": [],
          "fields": [
            {
              "name": "reader_not_found",
              "description": "Считыватель не найден",
              "label": "",
              "type": "ReaderNotFound",
              "longType": "Reader.SavingError.ReaderNotFound",
              "fullType": "deviceapis.device.v1.Reader.SavingError.ReaderNotFound",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "reason",
              "defaultValue": "",
              "number": 1
            },
            {
              "name": "profile_is_not_supported",
              "description": "Профиль не поддерживается для этого считывателя",
              "label": "",
              "type": "ProfileIsNotSupported",
              "longType": "Reader.SavingError.ProfileIsNotSupported",
              "fullType": "deviceapis.device.v1.Reader.SavingError.ProfileIsNotSupported",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "reason",
              "defaultValue": "",
              "number": 2
            },
            {
              "name": "profile_not_found",
              "description": "Выбранный профиль не найден",
              "label": "",
              "type": "ProfileNotFound",
              "longType": "Reader.SavingError.ProfileNotFound",
              "fullType": "deviceapis.device.v1.Reader.SavingError.ProfileNotFound",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "reason",
              "defaultValue": "",
              "number": 3
            }
          ]
        },
        {
          "name": "ProfileIsNotSupported",
          "longName": "Reader.SavingError.ProfileIsNotSupported",
          "fullName": "deviceapis.device.v1.Reader.SavingError.ProfileIsNotSupported",
          "description": "Профиль не поддерживается для этого считывателя",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "profile_ids",
              "description": "Список идентификаторов профилей, которые не поддерживаются на считывателе",
              "label": "repeated",
              "type": "int32",
              "longType": "int32",
              "fullType": "int32",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 1
            }
          ]
        },
        {
          "name": "ProfileNotFound",
          "longName": "Reader.SavingError.ProfileNotFound",
          "fullName": "deviceapis.device.v1.Reader.SavingError.ProfileNotFound",
          "description": "Выбранный профиль не найден",
          "hasExtensions": false,
          "hasFields": false,
          "hasOneofs": false,
          "extensions": [],
          "fields": []
        },
        {
          "name": "ReaderNotFound",
          "longName": "Reader.SavingError.ReaderNotFound",
          "fullName": "deviceapis.device.v1.Reader.SavingError.ReaderNotFound",
          "description": "Считыватель не найден",
          "hasExtensions": false,
          "hasFields": false,
          "hasOneofs": false,
          "extensions": [],
          "fields": []
        }
      ],
      "services": [
        {
          "name": "ReaderService",
          "longName": "ReaderService",
          "fullName": "deviceapis.device.v1.ReaderService",
          "description": "Сервис считывателей",
          "methods": [
            {
              "name": "EditReader",
              "description": "Метод редактирования считывателя",
              "requestType": "EditReaderRequest",
              "requestLongType": "EditReaderRequest",
              "requestFullType": "deviceapis.device.v1.EditReaderRequest",
              "requestStreaming": false,
              "responseType": "EditReaderResponse",
              "responseLongType": "EditReaderResponse",
              "responseFullType": "deviceapis.device.v1.EditReaderResponse",
              "responseStreaming": false,
              "options": {
                "google.api.http": {
                  "rules": [
                    {
                      "method": "PATCH",
                      "pattern": "/device/api/v1/reader/{data.id}",
                      "body": "data"
                    }
                  ]
                }
              }
            },
            {
              "name": "GetReader",
              "description": "Метод получения считывателя",
              "requestType": "GetReaderRequest",
              "requestLongType": "GetReaderRequest",
              "requestFullType": "deviceapis.device.v1.GetReaderRequest",
              "requestStreaming": false,
              "responseType": "GetReaderResponse",
              "responseLongType": "GetReaderResponse",
              "responseFullType": "deviceapis.device.v1.GetReaderResponse",
              "responseStreaming": false,
              "options": {
                "google.api.http": {
                  "rules": [
                    {
                      "method": "GET",
                      "pattern": "/device/api/v1/reader/{id}"
                    }
                  ]
                }
              }
            }
          ]
        }
      ],
      "syntax": "proto3"
    }
  ],
  "scalarValueTypes": [
    {
      "protoType": "double",
      "notes": "",
      "cppType": "double",
      "csType": "double",
      "goType": "float64",
      "javaType": "double",
      "phpType": "float",
      "pythonType": "float",
      "rubyType": "Float"
    },
    {
      "protoType": "float",
      "notes": "",
      "cppType": "float",
      "csType": "float",
      "goType": "float32",
      "javaType": "float",
      "phpType": "float",
      "pythonType": "float",
      "rubyType": "Float"
    },
    {
      "protoType": "int32",
      "notes": "Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead.",
      "cppType": "int32",
      "csType": "int",
      "goType": "int32",
      "javaType": "int",
      "phpType": "integer",
      "pythonType": "int",
      "rubyType": "Bignum or Fixnum (as required)"
    },
    {
      "protoType": "int64",
      "notes": "Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead.",
      "cppType": "int64",
      "csType": "long",
      "goType": "int64",
      "javaType": "long",
      "phpType": "integer/string",
      "pythonType": "int/long",
      "rubyType": "Bignum"
    },
    {
      "protoType": "uint32",
      "notes": "Uses variable-length encoding.",
      "cppType": "uint32",
      "csType": "uint",
      "goType": "uint32",
      "javaType": "int",
      "phpType": "integer",
      "pythonType": "int/long",
      "rubyType": "Bignum or Fixnum (as required)"
    },
    {
      "protoType": "uint64",
      "notes": "Uses variable-length encoding.",
      "cppType": "uint64",
      "csType": "ulong",
      "goType": "uint64",
      "javaType": "long",
      "phpType": "integer/string",
      "pythonType": "int/long",
      "rubyType": "Bignum or Fixnum (as required)"
    },
    {
      "protoType": "sint32",
      "notes": "Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s.",
      "cppType": "int32",
      "csType": "int",
      "goType": "int32",
      "javaType": "int",
      "phpType": "integer",
      "pythonType": "int",
      "rubyType": "Bignum or Fixnum (as required)"
    },
    {
      "protoType": "sint64",
      "notes": "Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s.",
      "cppType": "int64",
      "csType": "long",
      "goType": "int64",
      "javaType": "long",
      "phpType": "integer/string",
      "pythonType": "int/long",
      "rubyType": "Bignum"
    },
    {
      "protoType": "fixed32",
      "notes": "Always four bytes. More efficient than uint32 if values are often greater than 2^28.",
      "cppType": "uint32",
      "csType": "uint",
      "goType": "uint32",
      "javaType": "int",
      "phpType": "integer",
      "pythonType": "int",
      "rubyType": "Bignum or Fixnum (as required)"
    },
    {
      "protoType": "fixed64",
      "notes": "Always eight bytes. More efficient than uint64 if values are often greater than 2^56.",
      "cppType": "uint64",
      "csType": "ulong",
      "goType": "uint64",
      "javaType": "long",
      "phpType": "integer/string",
      "pythonType": "int/long",
      "rubyType": "Bignum"
    },
    {
      "protoType": "sfixed32",
      "notes": "Always four bytes.",
      "cppType": "int32",
      "csType": "int",
      "goType": "int32",
      "javaType": "int",
      "phpType": "integer",
      "pythonType": "int",
      "rubyType": "Bignum or Fixnum (as required)"
    },
    {
      "protoType": "sfixed64",
      "notes": "Always eight bytes.",
      "cppType": "int64",
      "csType": "long",
      "goType": "int64",
      "javaType": "long",
      "phpType": "integer/string",
      "pythonType": "int/long",
      "rubyType": "Bignum"
    },
    {
      "protoType": "bool",
      "notes": "",
      "cppType": "bool",
      "csType": "bool",
      "goType": "bool",
      "javaType": "boolean",
      "phpType": "boolean",
      "pythonType": "boolean",
      "rubyType": "TrueClass/FalseClass"
    },
    {
      "protoType": "string",
      "notes": "A string must always contain UTF-8 encoded or 7-bit ASCII text.",
      "cppType": "string",
      "csType": "string",
      "goType": "string",
      "javaType": "String",
      "phpType": "string",
      "pythonType": "str/unicode",
      "rubyType": "String (UTF-8)"
    },
    {
      "protoType": "bytes",
      "notes": "May contain any arbitrary sequence of bytes.",
      "cppType": "string",
      "csType": "ByteString",
      "goType": "[]byte",
      "javaType": "ByteString",
      "phpType": "string",
      "pythonType": "str",
      "rubyType": "String (ASCII-8BIT)"
    }
  ]
}