{
  "files": [
    {
      "name": "keyapis/iot_connect_sber/v1/keyapis_iot_connect_command_v1.proto",
      "description": "Сервис реализует функционал взаимодействия с Умным домом Sber",
      "package": "keyapis.iot_connect_sber.v1",
      "hasEnums": false,
      "hasExtensions": false,
      "hasMessages": true,
      "hasServices": true,
      "enums": [
        {
          "name": "KeyType",
          "longName": "DeviceCommand.KeyType",
          "fullName": "keyapis.iot_connect_sber.v1.DeviceCommand.KeyType",
          "description": "Список ключей команд на изменение статуса устройства",
          "values": [
            {
              "name": "KEY_TYPE_UNKNOWN",
              "number": "0",
              "description": "Значение не указано"
            },
            {
              "name": "REJECT_CALL",
              "number": "1",
              "description": "Отклонение звонка"
            },
            {
              "name": "UNLOCK",
              "number": "2",
              "description": "Открытие замка"
            }
          ]
        },
        {
          "name": "Type",
          "longName": "DeviceCommand.Value.Type",
          "fullName": "keyapis.iot_connect_sber.v1.DeviceCommand.Value.Type",
          "description": "Тип значения команд на изменение статуса устройства",
          "values": [
            {
              "name": "TYPE_UNKNOWN",
              "number": "0",
              "description": "Значение не указано"
            },
            {
              "name": "ENUM",
              "number": "1",
              "description": "Перечисление"
            }
          ]
        },
        {
          "name": "ValueEnumType",
          "longName": "DeviceCommand.Value.ValueEnumType",
          "fullName": "keyapis.iot_connect_sber.v1.DeviceCommand.Value.ValueEnumType",
          "description": "Значения команд на изменение статуса устройства типа перечисление",
          "values": [
            {
              "name": "VALUE_ENUM_TYPE_UNKNOWN",
              "number": "0",
              "description": "Значение не указано"
            },
            {
              "name": "REJECT",
              "number": "1",
              "description": "Отклонение звонка"
            },
            {
              "name": "UNLOCK",
              "number": "2",
              "description": "Открытие замка"
            }
          ]
        }
      ],
      "extensions": [],
      "messages": [
        {
          "name": "DeviceCommand",
          "longName": "DeviceCommand",
          "fullName": "keyapis.iot_connect_sber.v1.DeviceCommand",
          "description": "Команды на изменение статуса устройства",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "command_key_type",
              "description": "Тип команды на изменение статуса устройства",
              "label": "",
              "type": "KeyType",
              "longType": "DeviceCommand.KeyType",
              "fullType": "keyapis.iot_connect_sber.v1.DeviceCommand.KeyType",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 1
            },
            {
              "name": "value",
              "description": "Значение команды на изменение статуса устройства",
              "label": "",
              "type": "Value",
              "longType": "DeviceCommand.Value",
              "fullType": "keyapis.iot_connect_sber.v1.DeviceCommand.Value",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 2
            }
          ]
        },
        {
          "name": "Value",
          "longName": "DeviceCommand.Value",
          "fullName": "keyapis.iot_connect_sber.v1.DeviceCommand.Value",
          "description": "Значение команды на изменение статуса устройства",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": true,
          "extensions": [],
          "fields": [
            {
              "name": "type",
              "description": "Тип значения команды на изменение статуса устройства",
              "label": "",
              "type": "Type",
              "longType": "DeviceCommand.Value.Type",
              "fullType": "keyapis.iot_connect_sber.v1.DeviceCommand.Value.Type",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 1
            },
            {
              "name": "value_enum_type",
              "description": "Значения команды на изменение статуса устройства типа перечисление",
              "label": "",
              "type": "ValueEnumType",
              "longType": "DeviceCommand.Value.ValueEnumType",
              "fullType": "keyapis.iot_connect_sber.v1.DeviceCommand.Value.ValueEnumType",
              "ismap": false,
              "isoneof": true,
              "oneofdecl": "value",
              "defaultValue": "",
              "number": 2
            }
          ]
        },
        {
          "name": "DeviceCommandArray",
          "longName": "DeviceCommandArray",
          "fullName": "keyapis.iot_connect_sber.v1.DeviceCommandArray",
          "description": "Массив команд на изменение статуса устройства",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "states",
              "description": "Команды на изменение статуса устройства",
              "label": "repeated",
              "type": "DeviceCommand",
              "longType": "DeviceCommand",
              "fullType": "keyapis.iot_connect_sber.v1.DeviceCommand",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 1
            }
          ]
        },
        {
          "name": "PostCommandRequest",
          "longName": "PostCommandRequest",
          "fullName": "keyapis.iot_connect_sber.v1.PostCommandRequest",
          "description": "Запрос на изменение состояния устройства",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "devices",
              "description": "Массив домофонов со статусами",
              "label": "repeated",
              "type": "DevicesEntry",
              "longType": "PostCommandRequest.DevicesEntry",
              "fullType": "keyapis.iot_connect_sber.v1.PostCommandRequest.DevicesEntry",
              "ismap": true,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 1
            }
          ]
        },
        {
          "name": "DevicesEntry",
          "longName": "PostCommandRequest.DevicesEntry",
          "fullName": "keyapis.iot_connect_sber.v1.PostCommandRequest.DevicesEntry",
          "description": "",
          "hasExtensions": false,
          "hasFields": true,
          "hasOneofs": false,
          "extensions": [],
          "fields": [
            {
              "name": "key",
              "description": "",
              "label": "",
              "type": "string",
              "longType": "string",
              "fullType": "string",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 1
            },
            {
              "name": "value",
              "description": "",
              "label": "",
              "type": "DeviceCommandArray",
              "longType": "DeviceCommandArray",
              "fullType": "keyapis.iot_connect_sber.v1.DeviceCommandArray",
              "ismap": false,
              "isoneof": false,
              "oneofdecl": "",
              "defaultValue": "",
              "number": 2
            }
          ]
        },
        {
          "name": "PostCommandResponse",
          "longName": "PostCommandResponse",
          "fullName": "keyapis.iot_connect_sber.v1.PostCommandResponse",
          "description": "Ответ на запрос на изменение состояния устройства",
          "hasExtensions": false,
          "hasFields": false,
          "hasOneofs": false,
          "extensions": [],
          "fields": []
        }
      ],
      "services": [
        {
          "name": "CommandService",
          "longName": "CommandService",
          "fullName": "keyapis.iot_connect_sber.v1.CommandService",
          "description": "Сервис для приема комманд от Умного дома Sber",
          "methods": [
            {
              "name": "PostCommand",
              "description": "Метод приема команд на изменение состояния устройства.\nПоддерживается только открытие домофона.\nМетод доступен для: TokenACF: Scope: sber_iot",
              "requestType": "PostCommandRequest",
              "requestLongType": "PostCommandRequest",
              "requestFullType": "keyapis.iot_connect_sber.v1.PostCommandRequest",
              "requestStreaming": false,
              "responseType": "PostCommandResponse",
              "responseLongType": "PostCommandResponse",
              "responseFullType": "keyapis.iot_connect_sber.v1.PostCommandResponse",
              "responseStreaming": false,
              "options": {
                "google.api.http": {
                  "rules": [
                    {
                      "method": "POST",
                      "pattern": "/iot_connect_sber/api/v1/command",
                      "body": "*"
                    }
                  ]
                }
              }
            }
          ]
        }
      ],
      "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)"
    }
  ]
}