AlexaClientSDK  1.26.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
AVSDiscoveryEndpointAttributes.h
Go to the documentation of this file.
1 /*
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License").
5  * You may not use this file except in compliance with the License.
6  * A copy of the License is located at
7  *
8  * http://aws.amazon.com/apache2.0/
9  *
10  * or in the "license" file accompanying this file. This file is distributed
11  * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12  * express or implied. See the License for the specific language governing
13  * permissions and limitations under the License.
14  */
15 #ifndef ALEXA_CLIENT_SDK_AVSCOMMON_AVS_INCLUDE_AVSCOMMON_AVS_AVSDISCOVERYENDPOINTATTRIBUTES_H_
16 #define ALEXA_CLIENT_SDK_AVSCOMMON_AVS_INCLUDE_AVSCOMMON_AVS_AVSDISCOVERYENDPOINTATTRIBUTES_H_
17 
18 #include <map>
19 #include <memory>
20 #include <string>
21 #include <vector>
22 
25 
26 namespace alexaClientSDK {
27 namespace avsCommon {
28 namespace avs {
29 
45  struct Registration {
47  std::string productId;
48 
50  std::string serialNumber;
51 
53  std::string registrationKey;
54 
56  std::string productIdKey;
57 
67  const std::string& productId,
68  const std::string& serialNumber,
69  const std::string& registrationKey,
70  const std::string& productIdKey);
71 
75  Registration() = default;
76  };
77 
85  std::string manufacturer;
87  std::string model;
89  std::string serialNumber;
91  std::string firmwareVersion;
93  std::string softwareVersion;
95  std::string customIdentifier;
96  };
97 
102  static constexpr size_t MAX_ENDPOINT_IDENTIFIER_LENGTH = 256;
103  static constexpr size_t MAX_FRIENDLY_NAME_LENGTH = 128;
104  static constexpr size_t MAX_MANUFACTURER_NAME_LENGTH = 128;
105  static constexpr size_t MAX_DESCRIPTION_LENGTH = 128;
106  static constexpr size_t MAX_ENDPOINT_ADDITIONAL_ATTRIBUTES_LENGTH = 256;
107  static constexpr size_t MAX_CONNECTIONS_VALUE_LENGTH = 256;
109 
111  static constexpr size_t MAX_COOKIES_SIZE_BYTES = 5000;
112 
115 
118  std::string friendlyName;
119 
121  std::string description;
122 
124  std::string manufacturerName;
125 
129  std::vector<std::string> displayCategories;
130 
133 
136 
140  std::vector<std::map<std::string, std::string>> connections;
141 
144  std::map<std::string, std::string> cookies;
145 };
146 
148  const std::string& productId,
149  const std::string& serialNumber,
150  const std::string& registrationKey,
151  const std::string& productIdKey) :
152  productId(productId),
153  serialNumber(serialNumber),
154  registrationKey(registrationKey),
155  productIdKey(productIdKey) {
156 }
157 
158 } // namespace avs
159 } // namespace avsCommon
160 } // namespace alexaClientSDK
161 
162 #endif // ALEXA_CLIENT_SDK_AVSCOMMON_AVS_INCLUDE_AVSCOMMON_AVS_AVSDISCOVERYENDPOINTATTRIBUTES_H_
static constexpr size_t MAX_DESCRIPTION_LENGTH
Definition: AVSDiscoveryEndpointAttributes.h:105
std::string friendlyName
Definition: AVSDiscoveryEndpointAttributes.h:118
std::string serialNumber
The device serialNumber.
Definition: AVSDiscoveryEndpointAttributes.h:50
std::vector< std::string > displayCategories
Definition: AVSDiscoveryEndpointAttributes.h:129
std::string productId
The productID of the device provided when registering the client on https://developer.amazon.com.
Definition: AVSDiscoveryEndpointAttributes.h:47
static constexpr size_t MAX_CONNECTIONS_VALUE_LENGTH
Definition: AVSDiscoveryEndpointAttributes.h:107
std::string customIdentifier
Your custom identifier for the device.
Definition: AVSDiscoveryEndpointAttributes.h:95
std::string registrationKey
The device registration key value.
Definition: AVSDiscoveryEndpointAttributes.h:53
sdkInterfaces::endpoints::EndpointIdentifier endpointId
A unique ID to identify the endpoint. See EndpointIdentifier documentation for more information...
Definition: AVSDiscoveryEndpointAttributes.h:114
static constexpr size_t MAX_COOKIES_SIZE_BYTES
Cookies cannot exceed 5KB.
Definition: AVSDiscoveryEndpointAttributes.h:111
std::string firmwareVersion
The firmware version of the device.
Definition: AVSDiscoveryEndpointAttributes.h:91
utils::Optional< Registration > registration
Registration field used to identify the default endpoint.
Definition: AVSDiscoveryEndpointAttributes.h:132
utils::Optional< AdditionalAttributes > additionalAttributes
Contains additional information that can be used to identify an endpoint.
Definition: AVSDiscoveryEndpointAttributes.h:135
std::vector< std::map< std::string, std::string > > connections
Definition: AVSDiscoveryEndpointAttributes.h:140
static constexpr size_t MAX_FRIENDLY_NAME_LENGTH
Definition: AVSDiscoveryEndpointAttributes.h:103
std::string softwareVersion
The software version of the device.
Definition: AVSDiscoveryEndpointAttributes.h:93
std::string productIdKey
The device product id key value.
Definition: AVSDiscoveryEndpointAttributes.h:56
Definition: AVSDiscoveryEndpointAttributes.h:41
std::string manufacturer
The name of the manufacturer of the device.
Definition: AVSDiscoveryEndpointAttributes.h:85
static constexpr size_t MAX_ENDPOINT_IDENTIFIER_LENGTH
Definition: AVSDiscoveryEndpointAttributes.h:102
std::map< std::string, std::string > cookies
Definition: AVSDiscoveryEndpointAttributes.h:144
Whether or not curl logs should be emitted.
Definition: AVSConnectionManager.h:36
std::string model
The name of the model of the device.
Definition: AVSDiscoveryEndpointAttributes.h:87
static constexpr size_t MAX_ENDPOINT_ADDITIONAL_ATTRIBUTES_LENGTH
Definition: AVSDiscoveryEndpointAttributes.h:106
std::string description
A non-empty string with a description about the endpoint.
Definition: AVSDiscoveryEndpointAttributes.h:121
std::string EndpointIdentifier
Definition: EndpointIdentifier.h:38
std::string manufacturerName
A non-empty string identifying the endpoint manufacturer name.
Definition: AVSDiscoveryEndpointAttributes.h:124
std::string serialNumber
The serial number of the device.
Definition: AVSDiscoveryEndpointAttributes.h:89
static constexpr size_t MAX_MANUFACTURER_NAME_LENGTH
Definition: AVSDiscoveryEndpointAttributes.h:104

AlexaClientSDK 1.26.0 - Copyright 2016-2021 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0