<reponame>RyanJarv/Pacu2
# generated by datamodel-codegen:
#   filename:  openapi.yaml
#   timestamp: 2021-12-31T02:51:07+00:00

from __future__ import annotations

from enum import Enum
from typing import Annotated, Any, List, Optional

from pydantic import BaseModel, Field, SecretStr


class AmazonId(BaseModel):
    __root__: Annotated[
        str, Field(description='The Sidewalk Amazon ID.', max_length=2048)
    ]


class AppServerPrivateKey(BaseModel):
    __root__: Annotated[
        SecretStr, Field(max_length=4096, min_length=1, regex='[a-fA-F0-9]{64}')
    ]


class ValidationException(BaseModel):
    __root__: Any


class ResourceNotFoundException(ValidationException):
    pass


class InternalServerException(ValidationException):
    pass


class ThrottlingException(ValidationException):
    pass


class ConflictException(ValidationException):
    pass


class AccessDeniedException(ValidationException):
    pass


class AssociateWirelessDeviceWithThingResponse(BaseModel):
    pass


class AssociateWirelessGatewayWithThingResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class SupportsClassB(BaseModel):
    __root__: bool


class ClassBTimeout(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=1000.0)]


class PingSlotPeriod(BaseModel):
    __root__: Annotated[int, Field(ge=128.0, le=4096.0)]


class PingSlotDr(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=15.0)]


class PingSlotFreq(BaseModel):
    __root__: Annotated[int, Field(ge=1000000.0, le=16700000.0)]


class SupportsClassC(SupportsClassB):
    pass


class ClassCTimeout(ClassBTimeout):
    pass


class MacVersion(BaseModel):
    __root__: Annotated[str, Field(max_length=64)]


class RegParamsRevision(MacVersion):
    pass


class RxDelay1(PingSlotDr):
    pass


class RxDrOffset1(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=7.0)]


class RxDataRate2(PingSlotDr):
    pass


class RxFreq2(PingSlotFreq):
    pass


class MaxEirp(PingSlotDr):
    pass


class MaxDutyCycle(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=100.0)]


class RfRegion(MacVersion):
    pass


class SupportsJoin(SupportsClassB):
    pass


class Supports32BitFCnt(SupportsClassB):
    pass


class AddGwMetadata(SupportsClassB):
    pass


class DevEui(BaseModel):
    __root__: Annotated[str, Field(regex='[a-fA-F0-9]{16}')]


class DeviceProfileId(BaseModel):
    __root__: Annotated[str, Field(max_length=256)]


class ServiceProfileId(DeviceProfileId):
    pass


class GatewayEui(BaseModel):
    __root__: Annotated[
        str,
        Field(
            regex='^(([0-9A-Fa-f]{2}-){7}|([0-9A-Fa-f]{2}:){7}|([0-9A-Fa-f]{2}\\s){7}|([0-9A-Fa-f]{2}){7})([0-9A-Fa-f]{2})$'
        ),
    ]


class UpdateDataSource(BaseModel):
    __root__: Annotated[str, Field(max_length=4096, min_length=1)]


class DeleteDestinationResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteDeviceProfileResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteServiceProfileResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessDeviceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessGatewayResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessGatewayTaskResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessGatewayTaskDefinitionResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateAwsAccountFromPartnerAccountResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateWirelessDeviceFromThingResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateWirelessGatewayFromCertificateResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateWirelessGatewayFromThingResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class PutResourceLogLevelResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class ResetAllResourceLogLevelsResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class ResetResourceLogLevelResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class TagResourceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class TooManyTagsException(ValidationException):
    pass


class UntagResourceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class TagKey(BaseModel):
    __root__: Annotated[str, Field(max_length=128, min_length=1)]


class UpdateDestinationResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdateLogLevelsByResourceTypesResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdatePartnerAccountResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdateWirelessDeviceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdateWirelessGatewayResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class NetId(BaseModel):
    __root__: Annotated[
        str, Field(description='LoRaWAN network ID.', regex='[a-fA-F0-9]{6}')
    ]


class DevAddr(BaseModel):
    __root__: Annotated[str, Field(regex='[a-fA-F0-9]{8}')]


class AccountLinked(SupportsClassB):
    pass


class AmazonResourceName(BaseModel):
    __root__: Annotated[str, Field(max_length=1011, min_length=1)]


class AppEui(DevEui):
    pass


class AppKey(BaseModel):
    __root__: Annotated[str, Field(regex='[a-fA-F0-9]{32}')]


class AppSKey(AppKey):
    pass


class SidewalkAccountInfo(BaseModel):
    """
    Information about a Sidewalk account.
    """

    AmazonId: Optional[AmazonId] = None
    AppServerPrivateKey: Optional[AppServerPrivateKey] = None


class ClientRequestToken(BaseModel):
    __root__: Annotated[
        str, Field(max_length=64, min_length=1, regex='^[a-zA-Z0-9-_]+$')
    ]


class PartnerAccountArn(BaseModel):
    __root__: str


class WirelessDeviceId(DeviceProfileId):
    pass


class ThingArn(PartnerAccountArn):
    pass


class AssociateWirelessDeviceWithThingRequest(BaseModel):
    ThingArn: ThingArn


class WirelessGatewayId(DeviceProfileId):
    pass


class IotCertificateId(UpdateDataSource):
    pass


class AssociateWirelessGatewayWithCertificateRequest(BaseModel):
    IotCertificateId: IotCertificateId


class AssociateWirelessGatewayWithThingRequest(BaseModel):
    ThingArn: ThingArn


class AutoCreateTasks(SupportsClassB):
    pass


class BatteryLevel(Enum):
    """
    Sidewalk device battery level.
    """

    normal = 'normal'
    low = 'low'
    critical = 'critical'


class SigningAlg(Enum):
    """
    The certificate chain algorithm provided by sidewalk.
    """

    Ed25519 = 'Ed25519'
    P256r1 = 'P256r1'


class CertificateValue(BaseModel):
    __root__: Annotated[
        str, Field(description='Certificate value.', max_length=2048, min_length=0)
    ]


class CertificateList(BaseModel):
    """
    List of sidewalk certificates.
    """

    SigningAlg: SigningAlg
    Value: CertificateValue


class CertificatePEM(BaseModel):
    __root__: Annotated[
        str,
        Field(
            max_length=4096,
            min_length=1,
            regex='[^-A-Za-z0-9\\+/=]\\|=[^=]\\|=\\{3,\\}$\\{1,4096\\}',
        ),
    ]


class ChannelMask(BaseModel):
    __root__: Annotated[str, Field(max_length=2048)]


class ConnectionStatus(Enum):
    Connected = 'Connected'
    Disconnected = 'Disconnected'


class Crc(BaseModel):
    __root__: Annotated[int, Field(ge=1.0, le=4294967295.0)]


class DestinationName(BaseModel):
    __root__: Annotated[str, Field(max_length=128, regex='[a-zA-Z0-9-_]+')]


class ExpressionType(Enum):
    RuleName = 'RuleName'
    MqttTopic = 'MqttTopic'


class Expression(ChannelMask):
    pass


class Description(ChannelMask):
    pass


class RoleArn(BaseModel):
    __root__: Annotated[str, Field(max_length=2048, min_length=20)]


class DestinationArn(PartnerAccountArn):
    pass


class DeviceProfileName(DeviceProfileId):
    pass


class DeviceProfileArn(PartnerAccountArn):
    pass


class ServiceProfileName(DeviceProfileId):
    pass


class LoRaWANServiceProfile(BaseModel):
    """
    LoRaWANServiceProfile object.
    """

    AddGwMetadata: Optional[AddGwMetadata] = None


class ServiceProfileArn(PartnerAccountArn):
    pass


class WirelessDeviceType(Enum):
    Sidewalk = 'Sidewalk'
    LoRaWAN = 'LoRaWAN'


class WirelessDeviceName(DeviceProfileId):
    pass


class WirelessDeviceArn(PartnerAccountArn):
    pass


class WirelessGatewayName(DeviceProfileId):
    pass


class WirelessGatewayArn(PartnerAccountArn):
    pass


class WirelessGatewayTaskName(BaseModel):
    __root__: Annotated[str, Field(max_length=2048, min_length=1)]


class WirelessGatewayTaskDefinitionId(BaseModel):
    __root__: Annotated[
        str,
        Field(
            max_length=36,
            regex='[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}',
        ),
    ]


class WirelessGatewayTaskDefinitionArn(PartnerAccountArn):
    pass


class CreateWirelessGatewayTaskRequest(BaseModel):
    WirelessGatewayTaskDefinitionId: WirelessGatewayTaskDefinitionId


class WirelessGatewayTaskStatus(Enum):
    PENDING = 'PENDING'
    IN_PROGRESS = 'IN_PROGRESS'
    FIRST_RETRY = 'FIRST_RETRY'
    SECOND_RETRY = 'SECOND_RETRY'
    COMPLETED = 'COMPLETED'
    FAILED = 'FAILED'


class DeleteDestinationRequest(BaseModel):
    pass


class DeleteDeviceProfileRequest(BaseModel):
    pass


class DeleteServiceProfileRequest(BaseModel):
    pass


class DeleteWirelessDeviceRequest(BaseModel):
    pass


class DeleteWirelessGatewayRequest(BaseModel):
    pass


class DeleteWirelessGatewayTaskDefinitionRequest(BaseModel):
    pass


class DeleteWirelessGatewayTaskRequest(BaseModel):
    pass


class Destinations(BaseModel):
    """
    Describes a destination.
    """

    Arn: Optional[DestinationArn] = None
    Name: Optional[DestinationName] = None
    ExpressionType: Optional[ExpressionType] = None
    Expression: Optional[Expression] = None
    Description: Optional[Description] = None
    RoleArn: Optional[RoleArn] = None


class DestinationList(BaseModel):
    __root__: List[Destinations]


class DevStatusReqFreq(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=2147483647.0)]


class DeviceCertificateList(BaseModel):
    """
    List of device certificate chain.
    """

    __root__: Annotated[
        List[CertificateList], Field(description='List of device certificate chain.')
    ]


class DeviceProfile(BaseModel):
    """
    Describes a device profile.
    """

    Arn: Optional[DeviceProfileArn] = None
    Name: Optional[DeviceProfileName] = None
    Id: Optional[DeviceProfileId] = None


class DeviceProfileList(BaseModel):
    __root__: List[DeviceProfile]


class DeviceState(Enum):
    """
    Device state defines the device status of sidewalk device.
    """

    Provisioned = 'Provisioned'
    RegisteredNotSeen = 'RegisteredNotSeen'
    RegisteredReachable = 'RegisteredReachable'
    RegisteredUnreachable = 'RegisteredUnreachable'


class PartnerAccountId(DeviceProfileId):
    pass


class PartnerType(Enum):
    Sidewalk = 'Sidewalk'


class DisassociateAwsAccountFromPartnerAccountRequest(BaseModel):
    pass


class DisassociateWirelessDeviceFromThingRequest(BaseModel):
    pass


class DisassociateWirelessGatewayFromCertificateRequest(BaseModel):
    pass


class DisassociateWirelessGatewayFromThingRequest(BaseModel):
    pass


class DlBucketSize(DevStatusReqFreq):
    pass


class DlRate(DevStatusReqFreq):
    pass


class DlRatePolicy(DeviceProfileId):
    pass


class Double(BaseModel):
    __root__: float


class DrMax(PingSlotDr):
    pass


class DrMin(PingSlotDr):
    pass


class EndPoint(BaseModel):
    __root__: Annotated[str, Field(max_length=256, min_length=1)]


class Event(Enum):
    """
    Sidewalk device status notification.
    """

    discovered = 'discovered'
    lost = 'lost'
    ack = 'ack'
    nack = 'nack'
    passthrough = 'passthrough'


class FNwkSIntKey(AppKey):
    pass


class FPort(BaseModel):
    __root__: Annotated[int, Field(ge=1.0, le=223.0)]


class PresetFreq(PingSlotFreq):
    pass


class Fingerprint(BaseModel):
    __root__: Annotated[
        SecretStr, Field(max_length=64, min_length=64, regex='[a-fA-F0-9]{64}')
    ]


class GetDestinationRequest(BaseModel):
    pass


class GetDeviceProfileRequest(BaseModel):
    pass


class GetLogLevelsByResourceTypesRequest(BaseModel):
    pass


class LogLevel(Enum):
    """
    The log level for a log message.
    """

    INFO = 'INFO'
    ERROR = 'ERROR'
    DISABLED = 'DISABLED'


class GetPartnerAccountRequest(BaseModel):
    pass


class SidewalkAccountInfoWithFingerprint(BaseModel):
    """
    Information about a Sidewalk account.
    """

    AmazonId: Optional[AmazonId] = None
    Fingerprint: Optional[Fingerprint] = None
    Arn: Optional[PartnerAccountArn] = None


class ResourceIdentifier(BaseModel):
    __root__: Annotated[
        str,
        Field(
            description='The identifier of the resource. For a Wireless Device, it is the wireless device ID. For a wireless gateway, it is the wireless gateway ID.',
            max_length=256,
        ),
    ]


class ResourceType(PartnerAccountArn):
    pass


class GetResourceLogLevelRequest(BaseModel):
    pass


class WirelessGatewayServiceType(Enum):
    CUPS = 'CUPS'
    LNS = 'LNS'


class GetServiceEndpointRequest(BaseModel):
    pass


class GetServiceProfileRequest(BaseModel):
    pass


class Identifier(DeviceProfileId):
    pass


class WirelessDeviceIdType(Enum):
    WirelessDeviceId = 'WirelessDeviceId'
    DevEui = 'DevEui'
    ThingName = 'ThingName'
    SidewalkManufacturingSn = 'SidewalkManufacturingSn'


class GetWirelessDeviceRequest(BaseModel):
    pass


class ThingName(PartnerAccountArn):
    pass


class GetWirelessDeviceStatisticsRequest(BaseModel):
    pass


class ISODateTimeString(BaseModel):
    __root__: Annotated[
        str,
        Field(
            regex='^([\\+-]?\\d{4}(?!\\d{2}\\b))((-?)((0[1-9]|1[0-2])(\\3([12]\\d|0[1-9]|3[01]))?|W([0-4]\\d|5[0-2])(-?[1-7])?|(00[1-9]|0[1-9]\\d|[12]\\d{2}|3([0-5]\\d|6[1-6])))([T\\s]((([01]\\d|2[0-3])((:?)[0-5]\\d)?|24\\:?00)([\\.,]\\d+(?!:))?)?(\\17[0-5]\\d([\\.,]\\d+)?)?([zZ]|([\\+-])([01]\\d|2[0-3]):?([0-5]\\d)?)?)?)?$'
        ),
    ]


class GetWirelessGatewayCertificateRequest(BaseModel):
    pass


class GetWirelessGatewayFirmwareInformationRequest(BaseModel):
    pass


class WirelessGatewayIdType(Enum):
    GatewayEui = 'GatewayEui'
    WirelessGatewayId = 'WirelessGatewayId'
    ThingName = 'ThingName'


class GetWirelessGatewayRequest(BaseModel):
    pass


class GetWirelessGatewayStatisticsRequest(BaseModel):
    pass


class GetWirelessGatewayTaskDefinitionRequest(BaseModel):
    pass


class GetWirelessGatewayTaskRequest(BaseModel):
    pass


class HrAllowed(SupportsClassB):
    pass


class Integer(BaseModel):
    __root__: int


class JoinEui(DevEui):
    pass


class MaxResults(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=250.0)]


class NextToken(BaseModel):
    __root__: Annotated[str, Field(max_length=4096)]


class ListDestinationsRequest(BaseModel):
    pass


class ListDeviceProfilesRequest(BaseModel):
    pass


class ListPartnerAccountsRequest(BaseModel):
    pass


class SidewalkAccountList(BaseModel):
    __root__: List[SidewalkAccountInfoWithFingerprint]


class ListServiceProfilesRequest(BaseModel):
    pass


class ListTagsForResourceRequest(BaseModel):
    pass


class ListWirelessDevicesRequest(BaseModel):
    pass


class WirelessGatewayTaskDefinitionType(Enum):
    UPDATE = 'UPDATE'


class ListWirelessGatewayTaskDefinitionsRequest(BaseModel):
    pass


class ListWirelessGatewaysRequest(BaseModel):
    pass


class LoRaWANGatewayMetadata(BaseModel):
    """
    LoRaWAN gateway metatdata.
    """

    GatewayEui: Optional[GatewayEui] = None
    Snr: Optional[Double] = None
    Rssi: Optional[Double] = None


class PackageVersion(BaseModel):
    __root__: Annotated[str, Field(max_length=32, min_length=1)]


class Model(UpdateDataSource):
    pass


class Station(UpdateDataSource):
    pass


class UlRate(DevStatusReqFreq):
    pass


class UlBucketSize(DevStatusReqFreq):
    pass


class UlRatePolicy(DeviceProfileId):
    pass


class ReportDevStatusBattery(SupportsClassB):
    pass


class ReportDevStatusMargin(SupportsClassB):
    pass


class PrAllowed(SupportsClassB):
    pass


class RaAllowed(SupportsClassB):
    pass


class NwkGeoLoc(SupportsClassB):
    pass


class TargetPer(MaxDutyCycle):
    pass


class MinGwDiversity(BaseModel):
    __root__: Annotated[int, Field(ge=1.0, le=100.0)]


class LoRaWANListDevice(BaseModel):
    """
    LoRaWAN object for list functions.
    """

    DevEui: Optional[DevEui] = None


class LoRaWANUpdateDevice(BaseModel):
    """
    LoRaWAN object for update functions.
    """

    DeviceProfileId: Optional[DeviceProfileId] = None
    ServiceProfileId: Optional[ServiceProfileId] = None


class UpdateSignature(UpdateDataSource):
    pass


class MessageId(PartnerAccountArn):
    pass


class MessageType(Enum):
    """
    Sidewalk device message type. Default value is <code>CUSTOM_COMMAND_ID_NOTIFY</code>.
    """

    CUSTOM_COMMAND_ID_NOTIFY = 'CUSTOM_COMMAND_ID_NOTIFY'
    CUSTOM_COMMAND_ID_GET = 'CUSTOM_COMMAND_ID_GET'
    CUSTOM_COMMAND_ID_SET = 'CUSTOM_COMMAND_ID_SET'
    CUSTOM_COMMAND_ID_RESP = 'CUSTOM_COMMAND_ID_RESP'


class NwkKey(AppKey):
    pass


class NwkSEncKey(AppKey):
    pass


class NwkSKey(AppKey):
    pass


class PayloadData(BaseModel):
    __root__: Annotated[
        str,
        Field(
            max_length=2048,
            regex='^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$',
        ),
    ]


class PutResourceLogLevelRequest(BaseModel):
    LogLevel: LogLevel


class ResetAllResourceLogLevelsRequest(BaseModel):
    pass


class ResetResourceLogLevelRequest(BaseModel):
    pass


class Result(ChannelMask):
    pass


class SNwkSIntKey(AppKey):
    pass


class TransmitMode(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=1.0)]


class Seq(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=16383.0)]


class ServiceProfile(BaseModel):
    """
    Information about a service profile.
    """

    Arn: Optional[ServiceProfileArn] = None
    Name: Optional[ServiceProfileName] = None
    Id: Optional[ServiceProfileId] = None


class SidewalkId(BaseModel):
    __root__: Annotated[
        str, Field(description='The sidewalk device identification.', max_length=256)
    ]


class SidewalkManufacturingSn(MacVersion):
    pass


class SidewalkListDevice(BaseModel):
    """
    Sidewalk object used by list functions.
    """

    AmazonId: Optional[AmazonId] = None
    SidewalkId: Optional[SidewalkId] = None
    SidewalkManufacturingSn: Optional[SidewalkManufacturingSn] = None
    DeviceCertificates: Optional[DeviceCertificateList] = None


class SidewalkUpdateAccount(BaseModel):
    """
    Sidewalk update.
    """

    AppServerPrivateKey: Optional[AppServerPrivateKey] = None


class SubBand(BaseModel):
    __root__: Annotated[
        int,
        Field(
            description='A subset of supported frequency channels in a certain RFRegion.',
            ge=1.0,
            le=8.0,
        ),
    ]


class TagValue(BaseModel):
    __root__: Annotated[str, Field(max_length=256, min_length=0)]


class TagKeyList(BaseModel):
    __root__: Annotated[List[TagKey], Field(max_items=200, min_items=0)]


class TestWirelessDeviceRequest(BaseModel):
    pass


class UntagResourceRequest(BaseModel):
    pass


class UpdateDestinationRequest(BaseModel):
    ExpressionType: Optional[ExpressionType] = None
    Expression: Optional[Expression] = None
    Description: Optional[Description] = None
    RoleArn: Optional[RoleArn] = None


class UpdatePartnerAccountRequest(BaseModel):
    Sidewalk: SidewalkUpdateAccount


class UpdateWirelessDeviceRequest(BaseModel):
    DestinationName: Optional[DestinationName] = None
    Name: Optional[WirelessDeviceName] = None
    Description: Optional[Description] = None
    LoRaWAN: Optional[LoRaWANUpdateDevice] = None


class WirelessDeviceEvent(Enum):
    """
    The event for a log message, if the log message is tied to a wireless device.
    """

    Join = 'Join'
    Rejoin = 'Rejoin'
    Uplink_Data = 'Uplink_Data'
    Downlink_Data = 'Downlink_Data'
    Registration = 'Registration'


class WirelessDeviceEventLogOption(BaseModel):
    """
    <p>The log options for a wireless device event and can be used to set log levels for a specific wireless device event.</p> <p>For a LoRaWAN device, possible events for a log messsage are: <code>Join</code>, <code>Rejoin</code>, <code>Downlink_Data</code>, and <code>Uplink_Data</code>. For a Sidewalk device, possible events for a log message are <code>Registration</code>, <code>Downlink_Data</code>, and <code>Uplink_Data</code>.</p>
    """

    Event: WirelessDeviceEvent
    LogLevel: LogLevel


class WirelessDeviceEventLogOptionList(BaseModel):
    """
    The list of wireless device event log options.
    """

    __root__: Annotated[
        List[WirelessDeviceEventLogOption],
        Field(description='The list of wireless device event log options.'),
    ]


class WirelessDeviceStatistics(BaseModel):
    """
    Information about a wireless device's operation.
    """

    Arn: Optional[WirelessDeviceArn] = None
    Id: Optional[WirelessDeviceId] = None
    Type: Optional[WirelessDeviceType] = None
    Name: Optional[WirelessDeviceName] = None
    DestinationName: Optional[DestinationName] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    LoRaWAN: Optional[LoRaWANListDevice] = None
    Sidewalk: Optional[SidewalkListDevice] = None


class WirelessGatewayEvent(Enum):
    """
    The event for a log message, if the log message is tied to a wireless gateway.
    """

    CUPS_Request = 'CUPS_Request'
    Certificate = 'Certificate'


class WirelessGatewayEventLogOption(BaseModel):
    """
    <p>The log options for a wireless gateway event and can be used to set log levels for a specific wireless gateway event.</p> <p>For a LoRaWAN gateway, possible events for a log message are <code>CUPS_Request</code> and <code>Certificate</code>.</p>
    """

    Event: WirelessGatewayEvent
    LogLevel: LogLevel


class WirelessGatewayEventLogOptionList(BaseModel):
    """
    The list of wireless gateway event log options.
    """

    __root__: Annotated[
        List[WirelessGatewayEventLogOption],
        Field(description='The list of wireless gateway event log options.'),
    ]


class WirelessGatewayType(Enum):
    """
    The wireless gateway type.
    """

    LoRaWAN = 'LoRaWAN'


class AssociateAwsAccountWithPartnerAccountResponse(BaseModel):
    Sidewalk: Optional[SidewalkAccountInfo] = None
    Arn: Optional[PartnerAccountArn] = None


class Tag(BaseModel):
    """
    A simple label consisting of a customer-defined key-value pair
    """

    Key: TagKey
    Value: TagValue


class AssociateWirelessGatewayWithCertificateResponse(BaseModel):
    IotCertificateId: Optional[IotCertificateId] = None


class CreateDestinationResponse(BaseModel):
    Arn: Optional[DestinationArn] = None
    Name: Optional[DestinationName] = None


class CreateDeviceProfileResponse(BaseModel):
    Arn: Optional[DeviceProfileArn] = None
    Id: Optional[DeviceProfileId] = None


class FactoryPresetFreqsList(BaseModel):
    __root__: Annotated[List[PresetFreq], Field(max_items=20, min_items=0)]


class CreateServiceProfileResponse(BaseModel):
    Arn: Optional[ServiceProfileArn] = None
    Id: Optional[ServiceProfileId] = None


class CreateWirelessDeviceResponse(BaseModel):
    Arn: Optional[WirelessDeviceArn] = None
    Id: Optional[WirelessDeviceId] = None


class OtaaV11(BaseModel):
    """
    OTAA device object for v1.1
    """

    AppKey: Optional[AppKey] = None
    NwkKey: Optional[NwkKey] = None
    JoinEui: Optional[JoinEui] = None


class OtaaV10X(BaseModel):
    """
    OTAA device object for v1.0.x
    """

    AppKey: Optional[AppKey] = None
    AppEui: Optional[AppEui] = None


class CreateWirelessGatewayResponse(BaseModel):
    Arn: Optional[WirelessGatewayArn] = None
    Id: Optional[WirelessDeviceId] = None


class NetIdFilters(BaseModel):
    """
    A list of NetId values that are used by LoRa gateways to filter the uplink frames.
    """

    __root__: Annotated[
        List[NetId],
        Field(
            description='A list of NetId values that are used by LoRa gateways to filter the uplink frames.',
            max_items=10,
            min_items=0,
        ),
    ]


class SubBands(BaseModel):
    """
    A list of integer indicating which sub bands are supported by LoRa gateway.
    """

    __root__: Annotated[
        List[SubBand],
        Field(
            description='A list of integer indicating which sub bands are supported by LoRa gateway.',
            max_items=8,
            min_items=0,
        ),
    ]


class CreateWirelessGatewayTaskResponse(BaseModel):
    WirelessGatewayTaskDefinitionId: Optional[WirelessGatewayTaskDefinitionId] = None
    Status: Optional[WirelessGatewayTaskStatus] = None


class CreateWirelessGatewayTaskDefinitionResponse(BaseModel):
    Id: Optional[WirelessGatewayTaskDefinitionId] = None
    Arn: Optional[WirelessGatewayTaskDefinitionArn] = None


class GetDestinationResponse(BaseModel):
    Arn: Optional[DestinationArn] = None
    Name: Optional[DestinationName] = None
    Expression: Optional[Expression] = None
    ExpressionType: Optional[ExpressionType] = None
    Description: Optional[Description] = None
    RoleArn: Optional[RoleArn] = None


class GetPartnerAccountResponse(BaseModel):
    Sidewalk: Optional[SidewalkAccountInfoWithFingerprint] = None
    AccountLinked: Optional[AccountLinked] = None


class GetResourceLogLevelResponse(BaseModel):
    LogLevel: Optional[LogLevel] = None


class GetServiceEndpointResponse(BaseModel):
    ServiceType: Optional[WirelessGatewayServiceType] = None
    ServiceEndpoint: Optional[EndPoint] = None
    ServerTrust: Optional[CertificatePEM] = None


class GetWirelessGatewayCertificateResponse(BaseModel):
    IotCertificateId: Optional[IotCertificateId] = None
    LoRaWANNetworkServerCertificateId: Optional[IotCertificateId] = None


class GetWirelessGatewayStatisticsResponse(BaseModel):
    WirelessGatewayId: Optional[WirelessGatewayId] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    ConnectionStatus: Optional[ConnectionStatus] = None


class GetWirelessGatewayTaskResponse(BaseModel):
    WirelessGatewayId: Optional[WirelessGatewayId] = None
    WirelessGatewayTaskDefinitionId: Optional[WirelessGatewayTaskDefinitionId] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    TaskCreatedAt: Optional[ISODateTimeString] = None
    Status: Optional[WirelessGatewayTaskStatus] = None


class ListDestinationsResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    DestinationList: Optional[DestinationList] = None


class ListDeviceProfilesResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    DeviceProfileList: Optional[DeviceProfileList] = None


class ListPartnerAccountsResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    Sidewalk: Optional[SidewalkAccountList] = None


class SendDataToWirelessDeviceResponse(BaseModel):
    MessageId: Optional[MessageId] = None


class LoRaWANSendDataToDevice(BaseModel):
    """
    LoRaWAN router info.
    """

    FPort: Optional[FPort] = None


class SidewalkSendDataToDevice(BaseModel):
    """
    Information about a Sidewalk router.
    """

    Seq: Optional[Seq] = None
    MessageType: Optional[MessageType] = None


class TestWirelessDeviceResponse(BaseModel):
    Result: Optional[Result] = None


class WirelessDeviceLogOption(BaseModel):
    """
    The log options for wireless devices and can be used to set log levels for a specific type of wireless device.
    """

    Type: WirelessDeviceType
    LogLevel: LogLevel
    Events: Optional[WirelessDeviceEventLogOptionList] = None


class WirelessGatewayLogOption(BaseModel):
    """
    The log options for wireless gateways and can be used to set log levels for a specific type of wireless gateway.
    """

    Type: WirelessGatewayType
    LogLevel: LogLevel
    Events: Optional[WirelessGatewayEventLogOptionList] = None


class JoinEuiRange(BaseModel):
    """
    A pair of join EUI describing a range [BegEui, EndEui], both ends are inclusive.
    """

    __root__: Annotated[
        List[JoinEui],
        Field(
            description='A pair of join EUI describing a range [BegEui, EndEui], both ends are inclusive.',
            max_items=2,
            min_items=2,
        ),
    ]


class SessionKeysAbpV10X(BaseModel):
    """
    Session keys for ABP v1.1
    """

    NwkSKey: Optional[NwkSKey] = None
    AppSKey: Optional[AppSKey] = None


class SessionKeysAbpV11(BaseModel):
    """
    Session keys for ABP v1.1
    """

    FNwkSIntKey: Optional[FNwkSIntKey] = None
    SNwkSIntKey: Optional[SNwkSIntKey] = None
    NwkSEncKey: Optional[NwkSEncKey] = None
    AppSKey: Optional[AppSKey] = None


class TagList(BaseModel):
    __root__: Annotated[List[Tag], Field(max_items=200, min_items=0)]


class AssociateAwsAccountWithPartnerAccountRequest(BaseModel):
    Sidewalk: SidewalkAccountInfo
    ClientRequestToken: Optional[ClientRequestToken] = None
    Tags: Optional[TagList] = None


class CreateDestinationRequest(BaseModel):
    Name: DestinationName
    ExpressionType: ExpressionType
    Expression: Expression
    Description: Optional[Description] = None
    RoleArn: RoleArn
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class LoRaWANDeviceProfile(BaseModel):
    """
    LoRaWANDeviceProfile object.
    """

    SupportsClassB: Optional[SupportsClassB] = None
    ClassBTimeout: Optional[ClassBTimeout] = None
    PingSlotPeriod: Optional[PingSlotPeriod] = None
    PingSlotDr: Optional[PingSlotDr] = None
    PingSlotFreq: Optional[PingSlotFreq] = None
    SupportsClassC: Optional[SupportsClassC] = None
    ClassCTimeout: Optional[ClassCTimeout] = None
    MacVersion: Optional[MacVersion] = None
    RegParamsRevision: Optional[RegParamsRevision] = None
    RxDelay1: Optional[RxDelay1] = None
    RxDrOffset1: Optional[RxDrOffset1] = None
    RxDataRate2: Optional[RxDataRate2] = None
    RxFreq2: Optional[RxFreq2] = None
    FactoryPresetFreqsList: Optional[FactoryPresetFreqsList] = None
    MaxEirp: Optional[MaxEirp] = None
    MaxDutyCycle: Optional[MaxDutyCycle] = None
    RfRegion: Optional[RfRegion] = None
    SupportsJoin: Optional[SupportsJoin] = None
    Supports32BitFCnt: Optional[Supports32BitFCnt] = None


class CreateDeviceProfileRequest(BaseModel):
    Name: Optional[DeviceProfileName] = None
    LoRaWAN: Optional[LoRaWANDeviceProfile] = None
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class CreateServiceProfileRequest(BaseModel):
    Name: Optional[ServiceProfileName] = None
    LoRaWAN: Optional[LoRaWANServiceProfile] = None
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class WirelessGatewayLogOptionList(BaseModel):
    """
    The list of wireless gateway log options.
    """

    __root__: Annotated[
        List[WirelessGatewayLogOption],
        Field(description='The list of wireless gateway log options.'),
    ]


class WirelessDeviceLogOptionList(BaseModel):
    """
    The list of wireless device log options.
    """

    __root__: Annotated[
        List[WirelessDeviceLogOption],
        Field(description='The list of wireless device log options.'),
    ]


class LoRaWANGetServiceProfileInfo(BaseModel):
    """
    LoRaWANGetServiceProfileInfo object.
    """

    UlRate: Optional[UlRate] = None
    UlBucketSize: Optional[UlBucketSize] = None
    UlRatePolicy: Optional[UlRatePolicy] = None
    DlRate: Optional[DlRate] = None
    DlBucketSize: Optional[DlBucketSize] = None
    DlRatePolicy: Optional[DlRatePolicy] = None
    AddGwMetadata: Optional[AddGwMetadata] = None
    DevStatusReqFreq: Optional[DevStatusReqFreq] = None
    ReportDevStatusBattery: Optional[ReportDevStatusBattery] = None
    ReportDevStatusMargin: Optional[ReportDevStatusMargin] = None
    DrMin: Optional[DrMin] = None
    DrMax: Optional[DrMax] = None
    ChannelMask: Optional[ChannelMask] = None
    PrAllowed: Optional[PrAllowed] = None
    HrAllowed: Optional[HrAllowed] = None
    RaAllowed: Optional[RaAllowed] = None
    NwkGeoLoc: Optional[NwkGeoLoc] = None
    TargetPer: Optional[TargetPer] = None
    MinGwDiversity: Optional[MinGwDiversity] = None


class SidewalkDevice(SidewalkListDevice):
    """
    Sidewalk device object.
    """

    pass


class SidewalkDeviceMetadata(BaseModel):
    """
    MetaData for Sidewalk device.
    """

    Rssi: Optional[Integer] = None
    BatteryLevel: Optional[BatteryLevel] = None
    Event: Optional[Event] = None
    DeviceState: Optional[DeviceState] = None


class ServiceProfileList(BaseModel):
    __root__: List[ServiceProfile]


class WirelessDeviceStatisticsList(BaseModel):
    __root__: List[WirelessDeviceStatistics]


class LoRaWANGatewayMetadataList(BaseModel):
    __root__: List[LoRaWANGatewayMetadata]


class LoRaWANGatewayVersion(BaseModel):
    """
    LoRaWANGatewayVersion object.
    """

    PackageVersion: Optional[PackageVersion] = None
    Model: Optional[Model] = None
    Station: Optional[Station] = None


class LoRaWANUpdateGatewayTaskEntry(BaseModel):
    """
    LoRaWANUpdateGatewayTaskEntry object.
    """

    CurrentVersion: Optional[LoRaWANGatewayVersion] = None
    UpdateVersion: Optional[LoRaWANGatewayVersion] = None


class WirelessMetadata(BaseModel):
    """
    WirelessMetadata object.
    """

    LoRaWAN: Optional[LoRaWANSendDataToDevice] = None
    Sidewalk: Optional[SidewalkSendDataToDevice] = None


class SendDataToWirelessDeviceRequest(BaseModel):
    TransmitMode: TransmitMode
    PayloadData: PayloadData
    WirelessMetadata: Optional[WirelessMetadata] = None


class TagResourceRequest(BaseModel):
    Tags: TagList


class UpdateLogLevelsByResourceTypesRequest(BaseModel):
    DefaultLogLevel: Optional[LogLevel] = None
    WirelessDeviceLogOptions: Optional[WirelessDeviceLogOptionList] = None
    WirelessGatewayLogOptions: Optional[WirelessGatewayLogOptionList] = None


class UpdateWirelessGatewayTaskEntry(BaseModel):
    """
    UpdateWirelessGatewayTaskEntry object.
    """

    Id: Optional[WirelessGatewayTaskDefinitionId] = None
    LoRaWAN: Optional[LoRaWANUpdateGatewayTaskEntry] = None
    Arn: Optional[WirelessGatewayTaskDefinitionArn] = None


class AbpV11(BaseModel):
    """
    ABP device object for LoRaWAN specification v1.1
    """

    DevAddr: Optional[DevAddr] = None
    SessionKeys: Optional[SessionKeysAbpV11] = None


class AbpV10X(BaseModel):
    """
    ABP device object for LoRaWAN specification v1.0.x
    """

    DevAddr: Optional[DevAddr] = None
    SessionKeys: Optional[SessionKeysAbpV10X] = None


class JoinEuiFilters(BaseModel):
    """
    A list of JoinEuiRange used by LoRa gateways to filter LoRa frames.
    """

    __root__: Annotated[
        List[JoinEuiRange],
        Field(
            description='A list of JoinEuiRange used by LoRa gateways to filter LoRa frames.',
            max_items=3,
            min_items=0,
        ),
    ]


class LoRaWANUpdateGatewayTaskCreate(BaseModel):
    """
    LoRaWANUpdateGatewayTaskCreate object.
    """

    UpdateSignature: Optional[UpdateSignature] = None
    SigKeyCrc: Optional[Crc] = None
    CurrentVersion: Optional[LoRaWANGatewayVersion] = None
    UpdateVersion: Optional[LoRaWANGatewayVersion] = None


class GetDeviceProfileResponse(BaseModel):
    Arn: Optional[DeviceProfileArn] = None
    Name: Optional[DeviceProfileName] = None
    Id: Optional[DeviceProfileId] = None
    LoRaWAN: Optional[LoRaWANDeviceProfile] = None


class GetLogLevelsByResourceTypesResponse(BaseModel):
    DefaultLogLevel: Optional[LogLevel] = None
    WirelessGatewayLogOptions: Optional[WirelessGatewayLogOptionList] = None
    WirelessDeviceLogOptions: Optional[WirelessDeviceLogOptionList] = None


class GetServiceProfileResponse(BaseModel):
    Arn: Optional[ServiceProfileArn] = None
    Name: Optional[ServiceProfileName] = None
    Id: Optional[ServiceProfileId] = None
    LoRaWAN: Optional[LoRaWANGetServiceProfileInfo] = None


class ListServiceProfilesResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    ServiceProfileList: Optional[ServiceProfileList] = None


class ListTagsForResourceResponse(BaseModel):
    Tags: Optional[TagList] = None


class ListWirelessDevicesResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    WirelessDeviceList: Optional[WirelessDeviceStatisticsList] = None


class LoRaWANDevice(BaseModel):
    """
    LoRaWAN object for create functions.
    """

    DevEui: Optional[DevEui] = None
    DeviceProfileId: Optional[DeviceProfileId] = None
    ServiceProfileId: Optional[ServiceProfileId] = None
    OtaaV1_1: Optional[OtaaV11] = None
    OtaaV1_0_x: Optional[OtaaV10X] = None
    AbpV1_1: Optional[AbpV11] = None
    AbpV1_0_x: Optional[AbpV10X] = None


class CreateWirelessDeviceRequest(BaseModel):
    Type: WirelessDeviceType
    Name: Optional[WirelessDeviceName] = None
    Description: Optional[Description] = None
    DestinationName: DestinationName
    ClientRequestToken: Optional[ClientRequestToken] = None
    LoRaWAN: Optional[LoRaWANDevice] = None
    Tags: Optional[TagList] = None


class LoRaWANGateway(BaseModel):
    """
    LoRaWANGateway object.
    """

    GatewayEui: Optional[GatewayEui] = None
    RfRegion: Optional[RfRegion] = None
    JoinEuiFilters: Optional[JoinEuiFilters] = None
    NetIdFilters: Optional[NetIdFilters] = None
    SubBands: Optional[SubBands] = None


class CreateWirelessGatewayRequest(BaseModel):
    Name: Optional[WirelessGatewayName] = None
    Description: Optional[Description] = None
    LoRaWAN: LoRaWANGateway
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class UpdateWirelessGatewayTaskCreate(BaseModel):
    """
    UpdateWirelessGatewayTaskCreate object.
    """

    UpdateDataSource: Optional[UpdateDataSource] = None
    UpdateDataRole: Optional[UpdateDataSource] = None
    LoRaWAN: Optional[LoRaWANUpdateGatewayTaskCreate] = None


class CreateWirelessGatewayTaskDefinitionRequest(BaseModel):
    AutoCreateTasks: AutoCreateTasks
    Name: Optional[WirelessGatewayTaskName] = None
    Update: Optional[UpdateWirelessGatewayTaskCreate] = None
    ClientRequestToken: Optional[ClientRequestToken] = None
    Tags: Optional[TagList] = None


class LoRaWANDeviceMetadata(BaseModel):
    """
    LoRaWAN device metatdata.
    """

    DevEui: Optional[DevEui] = None
    FPort: Optional[Integer] = None
    DataRate: Optional[Integer] = None
    Frequency: Optional[Integer] = None
    Timestamp: Optional[ISODateTimeString] = None
    Gateways: Optional[LoRaWANGatewayMetadataList] = None


class LoRaWANGatewayCurrentVersion(BaseModel):
    """
    LoRaWANGatewayCurrentVersion object.
    """

    CurrentVersion: Optional[LoRaWANGatewayVersion] = None


class WirelessGatewayTaskDefinitionList(BaseModel):
    __root__: List[UpdateWirelessGatewayTaskEntry]


class UpdateWirelessGatewayRequest(BaseModel):
    Name: Optional[WirelessGatewayName] = None
    Description: Optional[Description] = None
    JoinEuiFilters: Optional[JoinEuiFilters] = None
    NetIdFilters: Optional[NetIdFilters] = None


class WirelessGatewayStatistics(BaseModel):
    """
    Information about a wireless gateway's operation.
    """

    Arn: Optional[WirelessGatewayArn] = None
    Id: Optional[WirelessGatewayId] = None
    Name: Optional[WirelessGatewayName] = None
    Description: Optional[Description] = None
    LoRaWAN: Optional[LoRaWANGateway] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None


class GetWirelessDeviceResponse(BaseModel):
    Type: Optional[WirelessDeviceType] = None
    Name: Optional[WirelessDeviceName] = None
    Description: Optional[Description] = None
    DestinationName: Optional[DestinationName] = None
    Id: Optional[WirelessDeviceId] = None
    Arn: Optional[WirelessDeviceArn] = None
    ThingName: Optional[ThingName] = None
    ThingArn: Optional[ThingArn] = None
    LoRaWAN: Optional[LoRaWANDevice] = None
    Sidewalk: Optional[SidewalkDevice] = None


class GetWirelessDeviceStatisticsResponse(BaseModel):
    WirelessDeviceId: Optional[WirelessDeviceId] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    LoRaWAN: Optional[LoRaWANDeviceMetadata] = None
    Sidewalk: Optional[SidewalkDeviceMetadata] = None


class GetWirelessGatewayResponse(BaseModel):
    Name: Optional[WirelessGatewayName] = None
    Id: Optional[WirelessGatewayId] = None
    Description: Optional[Description] = None
    LoRaWAN: Optional[LoRaWANGateway] = None
    Arn: Optional[WirelessGatewayArn] = None
    ThingName: Optional[ThingName] = None
    ThingArn: Optional[ThingArn] = None


class GetWirelessGatewayFirmwareInformationResponse(BaseModel):
    LoRaWAN: Optional[LoRaWANGatewayCurrentVersion] = None


class GetWirelessGatewayTaskDefinitionResponse(BaseModel):
    AutoCreateTasks: Optional[AutoCreateTasks] = None
    Name: Optional[WirelessGatewayTaskName] = None
    Update: Optional[UpdateWirelessGatewayTaskCreate] = None
    Arn: Optional[WirelessGatewayTaskDefinitionArn] = None


class ListWirelessGatewayTaskDefinitionsResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    TaskDefinitions: Optional[WirelessGatewayTaskDefinitionList] = None


class WirelessGatewayStatisticsList(BaseModel):
    __root__: List[WirelessGatewayStatistics]


class ListWirelessGatewaysResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    WirelessGatewayList: Optional[WirelessGatewayStatisticsList] = None

# generated by datamodel-codegen:
#   filename:  openapi.yaml
#   timestamp: 2021-12-31T02:51:07+00:00

from __future__ import annotations

from enum import Enum
from typing import Annotated, Any, List, Optional

from pydantic import BaseModel, Field, SecretStr


class AmazonId(BaseModel):
    __root__: Annotated[
        str, Field(description='The Sidewalk Amazon ID.', max_length=2048)
    ]


class AppServerPrivateKey(BaseModel):
    __root__: Annotated[
        SecretStr, Field(max_length=4096, min_length=1, regex='[a-fA-F0-9]{64}')
    ]


class ValidationException(BaseModel):
    __root__: Any


class ResourceNotFoundException(ValidationException):
    pass


class InternalServerException(ValidationException):
    pass


class ThrottlingException(ValidationException):
    pass


class ConflictException(ValidationException):
    pass


class AccessDeniedException(ValidationException):
    pass


class AssociateWirelessDeviceWithThingResponse(BaseModel):
    pass


class AssociateWirelessGatewayWithThingResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class SupportsClassB(BaseModel):
    __root__: bool


class ClassBTimeout(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=1000.0)]


class PingSlotPeriod(BaseModel):
    __root__: Annotated[int, Field(ge=128.0, le=4096.0)]


class PingSlotDr(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=15.0)]


class PingSlotFreq(BaseModel):
    __root__: Annotated[int, Field(ge=1000000.0, le=16700000.0)]


class SupportsClassC(SupportsClassB):
    pass


class ClassCTimeout(ClassBTimeout):
    pass


class MacVersion(BaseModel):
    __root__: Annotated[str, Field(max_length=64)]


class RegParamsRevision(MacVersion):
    pass


class RxDelay1(PingSlotDr):
    pass


class RxDrOffset1(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=7.0)]


class RxDataRate2(PingSlotDr):
    pass


class RxFreq2(PingSlotFreq):
    pass


class MaxEirp(PingSlotDr):
    pass


class MaxDutyCycle(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=100.0)]


class RfRegion(MacVersion):
    pass


class SupportsJoin(SupportsClassB):
    pass


class Supports32BitFCnt(SupportsClassB):
    pass


class AddGwMetadata(SupportsClassB):
    pass


class DevEui(BaseModel):
    __root__: Annotated[str, Field(regex='[a-fA-F0-9]{16}')]


class DeviceProfileId(BaseModel):
    __root__: Annotated[str, Field(max_length=256)]


class ServiceProfileId(DeviceProfileId):
    pass


class GatewayEui(BaseModel):
    __root__: Annotated[
        str,
        Field(
            regex='^(([0-9A-Fa-f]{2}-){7}|([0-9A-Fa-f]{2}:){7}|([0-9A-Fa-f]{2}\\s){7}|([0-9A-Fa-f]{2}){7})([0-9A-Fa-f]{2})$'
        ),
    ]


class UpdateDataSource(BaseModel):
    __root__: Annotated[str, Field(max_length=4096, min_length=1)]


class DeleteDestinationResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteDeviceProfileResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteServiceProfileResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessDeviceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessGatewayResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessGatewayTaskResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class DeleteWirelessGatewayTaskDefinitionResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateAwsAccountFromPartnerAccountResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateWirelessDeviceFromThingResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateWirelessGatewayFromCertificateResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class DisassociateWirelessGatewayFromThingResponse(
    AssociateWirelessDeviceWithThingResponse
):
    pass


class PutResourceLogLevelResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class ResetAllResourceLogLevelsResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class ResetResourceLogLevelResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class TagResourceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class TooManyTagsException(ValidationException):
    pass


class UntagResourceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class TagKey(BaseModel):
    __root__: Annotated[str, Field(max_length=128, min_length=1)]


class UpdateDestinationResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdateLogLevelsByResourceTypesResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdatePartnerAccountResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdateWirelessDeviceResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class UpdateWirelessGatewayResponse(AssociateWirelessDeviceWithThingResponse):
    pass


class NetId(BaseModel):
    __root__: Annotated[
        str, Field(description='LoRaWAN network ID.', regex='[a-fA-F0-9]{6}')
    ]


class DevAddr(BaseModel):
    __root__: Annotated[str, Field(regex='[a-fA-F0-9]{8}')]


class AccountLinked(SupportsClassB):
    pass


class AmazonResourceName(BaseModel):
    __root__: Annotated[str, Field(max_length=1011, min_length=1)]


class AppEui(DevEui):
    pass


class AppKey(BaseModel):
    __root__: Annotated[str, Field(regex='[a-fA-F0-9]{32}')]


class AppSKey(AppKey):
    pass


class SidewalkAccountInfo(BaseModel):
    """
    Information about a Sidewalk account.
    """

    AmazonId: Optional[AmazonId] = None
    AppServerPrivateKey: Optional[AppServerPrivateKey] = None


class ClientRequestToken(BaseModel):
    __root__: Annotated[
        str, Field(max_length=64, min_length=1, regex='^[a-zA-Z0-9-_]+$')
    ]


class PartnerAccountArn(BaseModel):
    __root__: str


class WirelessDeviceId(DeviceProfileId):
    pass


class ThingArn(PartnerAccountArn):
    pass


class AssociateWirelessDeviceWithThingRequest(BaseModel):
    ThingArn: ThingArn


class WirelessGatewayId(DeviceProfileId):
    pass


class IotCertificateId(UpdateDataSource):
    pass


class AssociateWirelessGatewayWithCertificateRequest(BaseModel):
    IotCertificateId: IotCertificateId


class AssociateWirelessGatewayWithThingRequest(BaseModel):
    ThingArn: ThingArn


class AutoCreateTasks(SupportsClassB):
    pass


class BatteryLevel(Enum):
    """
    Sidewalk device battery level.
    """

    normal = 'normal'
    low = 'low'
    critical = 'critical'


class SigningAlg(Enum):
    """
    The certificate chain algorithm provided by sidewalk.
    """

    Ed25519 = 'Ed25519'
    P256r1 = 'P256r1'


class CertificateValue(BaseModel):
    __root__: Annotated[
        str, Field(description='Certificate value.', max_length=2048, min_length=0)
    ]


class CertificateList(BaseModel):
    """
    List of sidewalk certificates.
    """

    SigningAlg: SigningAlg
    Value: CertificateValue


class CertificatePEM(BaseModel):
    __root__: Annotated[
        str,
        Field(
            max_length=4096,
            min_length=1,
            regex='[^-A-Za-z0-9\\+/=]\\|=[^=]\\|=\\{3,\\}$\\{1,4096\\}',
        ),
    ]


class ChannelMask(BaseModel):
    __root__: Annotated[str, Field(max_length=2048)]


class ConnectionStatus(Enum):
    Connected = 'Connected'
    Disconnected = 'Disconnected'


class Crc(BaseModel):
    __root__: Annotated[int, Field(ge=1.0, le=4294967295.0)]


class DestinationName(BaseModel):
    __root__: Annotated[str, Field(max_length=128, regex='[a-zA-Z0-9-_]+')]


class ExpressionType(Enum):
    RuleName = 'RuleName'
    MqttTopic = 'MqttTopic'


class Expression(ChannelMask):
    pass


class Description(ChannelMask):
    pass


class RoleArn(BaseModel):
    __root__: Annotated[str, Field(max_length=2048, min_length=20)]


class DestinationArn(PartnerAccountArn):
    pass


class DeviceProfileName(DeviceProfileId):
    pass


class DeviceProfileArn(PartnerAccountArn):
    pass


class ServiceProfileName(DeviceProfileId):
    pass


class LoRaWANServiceProfile(BaseModel):
    """
    LoRaWANServiceProfile object.
    """

    AddGwMetadata: Optional[AddGwMetadata] = None


class ServiceProfileArn(PartnerAccountArn):
    pass


class WirelessDeviceType(Enum):
    Sidewalk = 'Sidewalk'
    LoRaWAN = 'LoRaWAN'


class WirelessDeviceName(DeviceProfileId):
    pass


class WirelessDeviceArn(PartnerAccountArn):
    pass


class WirelessGatewayName(DeviceProfileId):
    pass


class WirelessGatewayArn(PartnerAccountArn):
    pass


class WirelessGatewayTaskName(BaseModel):
    __root__: Annotated[str, Field(max_length=2048, min_length=1)]


class WirelessGatewayTaskDefinitionId(BaseModel):
    __root__: Annotated[
        str,
        Field(
            max_length=36,
            regex='[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}',
        ),
    ]


class WirelessGatewayTaskDefinitionArn(PartnerAccountArn):
    pass


class CreateWirelessGatewayTaskRequest(BaseModel):
    WirelessGatewayTaskDefinitionId: WirelessGatewayTaskDefinitionId


class WirelessGatewayTaskStatus(Enum):
    PENDING = 'PENDING'
    IN_PROGRESS = 'IN_PROGRESS'
    FIRST_RETRY = 'FIRST_RETRY'
    SECOND_RETRY = 'SECOND_RETRY'
    COMPLETED = 'COMPLETED'
    FAILED = 'FAILED'


class DeleteDestinationRequest(BaseModel):
    pass


class DeleteDeviceProfileRequest(BaseModel):
    pass


class DeleteServiceProfileRequest(BaseModel):
    pass


class DeleteWirelessDeviceRequest(BaseModel):
    pass


class DeleteWirelessGatewayRequest(BaseModel):
    pass


class DeleteWirelessGatewayTaskDefinitionRequest(BaseModel):
    pass


class DeleteWirelessGatewayTaskRequest(BaseModel):
    pass


class Destinations(BaseModel):
    """
    Describes a destination.
    """

    Arn: Optional[DestinationArn] = None
    Name: Optional[DestinationName] = None
    ExpressionType: Optional[ExpressionType] = None
    Expression: Optional[Expression] = None
    Description: Optional[Description] = None
    RoleArn: Optional[RoleArn] = None


class DestinationList(BaseModel):
    __root__: List[Destinations]


class DevStatusReqFreq(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=2147483647.0)]


class DeviceCertificateList(BaseModel):
    """
    List of device certificate chain.
    """

    __root__: Annotated[
        List[CertificateList], Field(description='List of device certificate chain.')
    ]


class DeviceProfile(BaseModel):
    """
    Describes a device profile.
    """

    Arn: Optional[DeviceProfileArn] = None
    Name: Optional[DeviceProfileName] = None
    Id: Optional[DeviceProfileId] = None


class DeviceProfileList(BaseModel):
    __root__: List[DeviceProfile]


class DeviceState(Enum):
    """
    Device state defines the device status of sidewalk device.
    """

    Provisioned = 'Provisioned'
    RegisteredNotSeen = 'RegisteredNotSeen'
    RegisteredReachable = 'RegisteredReachable'
    RegisteredUnreachable = 'RegisteredUnreachable'


class PartnerAccountId(DeviceProfileId):
    pass


class PartnerType(Enum):
    Sidewalk = 'Sidewalk'


class DisassociateAwsAccountFromPartnerAccountRequest(BaseModel):
    pass


class DisassociateWirelessDeviceFromThingRequest(BaseModel):
    pass


class DisassociateWirelessGatewayFromCertificateRequest(BaseModel):
    pass


class DisassociateWirelessGatewayFromThingRequest(BaseModel):
    pass


class DlBucketSize(DevStatusReqFreq):
    pass


class DlRate(DevStatusReqFreq):
    pass


class DlRatePolicy(DeviceProfileId):
    pass


class Double(BaseModel):
    __root__: float


class DrMax(PingSlotDr):
    pass


class DrMin(PingSlotDr):
    pass


class EndPoint(BaseModel):
    __root__: Annotated[str, Field(max_length=256, min_length=1)]


class Event(Enum):
    """
    Sidewalk device status notification.
    """

    discovered = 'discovered'
    lost = 'lost'
    ack = 'ack'
    nack = 'nack'
    passthrough = 'passthrough'


class FNwkSIntKey(AppKey):
    pass


class FPort(BaseModel):
    __root__: Annotated[int, Field(ge=1.0, le=223.0)]


class PresetFreq(PingSlotFreq):
    pass


class Fingerprint(BaseModel):
    __root__: Annotated[
        SecretStr, Field(max_length=64, min_length=64, regex='[a-fA-F0-9]{64}')
    ]


class GetDestinationRequest(BaseModel):
    pass


class GetDeviceProfileRequest(BaseModel):
    pass


class GetLogLevelsByResourceTypesRequest(BaseModel):
    pass


class LogLevel(Enum):
    """
    The log level for a log message.
    """

    INFO = 'INFO'
    ERROR = 'ERROR'
    DISABLED = 'DISABLED'


class GetPartnerAccountRequest(BaseModel):
    pass


class SidewalkAccountInfoWithFingerprint(BaseModel):
    """
    Information about a Sidewalk account.
    """

    AmazonId: Optional[AmazonId] = None
    Fingerprint: Optional[Fingerprint] = None
    Arn: Optional[PartnerAccountArn] = None


class ResourceIdentifier(BaseModel):
    __root__: Annotated[
        str,
        Field(
            description='The identifier of the resource. For a Wireless Device, it is the wireless device ID. For a wireless gateway, it is the wireless gateway ID.',
            max_length=256,
        ),
    ]


class ResourceType(PartnerAccountArn):
    pass


class GetResourceLogLevelRequest(BaseModel):
    pass


class WirelessGatewayServiceType(Enum):
    CUPS = 'CUPS'
    LNS = 'LNS'


class GetServiceEndpointRequest(BaseModel):
    pass


class GetServiceProfileRequest(BaseModel):
    pass


class Identifier(DeviceProfileId):
    pass


class WirelessDeviceIdType(Enum):
    WirelessDeviceId = 'WirelessDeviceId'
    DevEui = 'DevEui'
    ThingName = 'ThingName'
    SidewalkManufacturingSn = 'SidewalkManufacturingSn'


class GetWirelessDeviceRequest(BaseModel):
    pass


class ThingName(PartnerAccountArn):
    pass


class GetWirelessDeviceStatisticsRequest(BaseModel):
    pass


class ISODateTimeString(BaseModel):
    __root__: Annotated[
        str,
        Field(
            regex='^([\\+-]?\\d{4}(?!\\d{2}\\b))((-?)((0[1-9]|1[0-2])(\\3([12]\\d|0[1-9]|3[01]))?|W([0-4]\\d|5[0-2])(-?[1-7])?|(00[1-9]|0[1-9]\\d|[12]\\d{2}|3([0-5]\\d|6[1-6])))([T\\s]((([01]\\d|2[0-3])((:?)[0-5]\\d)?|24\\:?00)([\\.,]\\d+(?!:))?)?(\\17[0-5]\\d([\\.,]\\d+)?)?([zZ]|([\\+-])([01]\\d|2[0-3]):?([0-5]\\d)?)?)?)?$'
        ),
    ]


class GetWirelessGatewayCertificateRequest(BaseModel):
    pass


class GetWirelessGatewayFirmwareInformationRequest(BaseModel):
    pass


class WirelessGatewayIdType(Enum):
    GatewayEui = 'GatewayEui'
    WirelessGatewayId = 'WirelessGatewayId'
    ThingName = 'ThingName'


class GetWirelessGatewayRequest(BaseModel):
    pass


class GetWirelessGatewayStatisticsRequest(BaseModel):
    pass


class GetWirelessGatewayTaskDefinitionRequest(BaseModel):
    pass


class GetWirelessGatewayTaskRequest(BaseModel):
    pass


class HrAllowed(SupportsClassB):
    pass


class Integer(BaseModel):
    __root__: int


class JoinEui(DevEui):
    pass


class MaxResults(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=250.0)]


class NextToken(BaseModel):
    __root__: Annotated[str, Field(max_length=4096)]


class ListDestinationsRequest(BaseModel):
    pass


class ListDeviceProfilesRequest(BaseModel):
    pass


class ListPartnerAccountsRequest(BaseModel):
    pass


class SidewalkAccountList(BaseModel):
    __root__: List[SidewalkAccountInfoWithFingerprint]


class ListServiceProfilesRequest(BaseModel):
    pass


class ListTagsForResourceRequest(BaseModel):
    pass


class ListWirelessDevicesRequest(BaseModel):
    pass


class WirelessGatewayTaskDefinitionType(Enum):
    UPDATE = 'UPDATE'


class ListWirelessGatewayTaskDefinitionsRequest(BaseModel):
    pass


class ListWirelessGatewaysRequest(BaseModel):
    pass


class LoRaWANGatewayMetadata(BaseModel):
    """
    LoRaWAN gateway metatdata.
    """

    GatewayEui: Optional[GatewayEui] = None
    Snr: Optional[Double] = None
    Rssi: Optional[Double] = None


class PackageVersion(BaseModel):
    __root__: Annotated[str, Field(max_length=32, min_length=1)]


class Model(UpdateDataSource):
    pass


class Station(UpdateDataSource):
    pass


class UlRate(DevStatusReqFreq):
    pass


class UlBucketSize(DevStatusReqFreq):
    pass


class UlRatePolicy(DeviceProfileId):
    pass


class ReportDevStatusBattery(SupportsClassB):
    pass


class ReportDevStatusMargin(SupportsClassB):
    pass


class PrAllowed(SupportsClassB):
    pass


class RaAllowed(SupportsClassB):
    pass


class NwkGeoLoc(SupportsClassB):
    pass


class TargetPer(MaxDutyCycle):
    pass


class MinGwDiversity(BaseModel):
    __root__: Annotated[int, Field(ge=1.0, le=100.0)]


class LoRaWANListDevice(BaseModel):
    """
    LoRaWAN object for list functions.
    """

    DevEui: Optional[DevEui] = None


class LoRaWANUpdateDevice(BaseModel):
    """
    LoRaWAN object for update functions.
    """

    DeviceProfileId: Optional[DeviceProfileId] = None
    ServiceProfileId: Optional[ServiceProfileId] = None


class UpdateSignature(UpdateDataSource):
    pass


class MessageId(PartnerAccountArn):
    pass


class MessageType(Enum):
    """
    Sidewalk device message type. Default value is <code>CUSTOM_COMMAND_ID_NOTIFY</code>.
    """

    CUSTOM_COMMAND_ID_NOTIFY = 'CUSTOM_COMMAND_ID_NOTIFY'
    CUSTOM_COMMAND_ID_GET = 'CUSTOM_COMMAND_ID_GET'
    CUSTOM_COMMAND_ID_SET = 'CUSTOM_COMMAND_ID_SET'
    CUSTOM_COMMAND_ID_RESP = 'CUSTOM_COMMAND_ID_RESP'


class NwkKey(AppKey):
    pass


class NwkSEncKey(AppKey):
    pass


class NwkSKey(AppKey):
    pass


class PayloadData(BaseModel):
    __root__: Annotated[
        str,
        Field(
            max_length=2048,
            regex='^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$',
        ),
    ]


class PutResourceLogLevelRequest(BaseModel):
    LogLevel: LogLevel


class ResetAllResourceLogLevelsRequest(BaseModel):
    pass


class ResetResourceLogLevelRequest(BaseModel):
    pass


class Result(ChannelMask):
    pass


class SNwkSIntKey(AppKey):
    pass


class TransmitMode(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=1.0)]


class Seq(BaseModel):
    __root__: Annotated[int, Field(ge=0.0, le=16383.0)]


class ServiceProfile(BaseModel):
    """
    Information about a service profile.
    """

    Arn: Optional[ServiceProfileArn] = None
    Name: Optional[ServiceProfileName] = None
    Id: Optional[ServiceProfileId] = None


class SidewalkId(BaseModel):
    __root__: Annotated[
        str, Field(description='The sidewalk device identification.', max_length=256)
    ]


class SidewalkManufacturingSn(MacVersion):
    pass


class SidewalkListDevice(BaseModel):
    """
    Sidewalk object used by list functions.
    """

    AmazonId: Optional[AmazonId] = None
    SidewalkId: Optional[SidewalkId] = None
    SidewalkManufacturingSn: Optional[SidewalkManufacturingSn] = None
    DeviceCertificates: Optional[DeviceCertificateList] = None


class SidewalkUpdateAccount(BaseModel):
    """
    Sidewalk update.
    """

    AppServerPrivateKey: Optional[AppServerPrivateKey] = None


class SubBand(BaseModel):
    __root__: Annotated[
        int,
        Field(
            description='A subset of supported frequency channels in a certain RFRegion.',
            ge=1.0,
            le=8.0,
        ),
    ]


class TagValue(BaseModel):
    __root__: Annotated[str, Field(max_length=256, min_length=0)]


class TagKeyList(BaseModel):
    __root__: Annotated[List[TagKey], Field(max_items=200, min_items=0)]


class TestWirelessDeviceRequest(BaseModel):
    pass


class UntagResourceRequest(BaseModel):
    pass


class UpdateDestinationRequest(BaseModel):
    ExpressionType: Optional[ExpressionType] = None
    Expression: Optional[Expression] = None
    Description: Optional[Description] = None
    RoleArn: Optional[RoleArn] = None


class UpdatePartnerAccountRequest(BaseModel):
    Sidewalk: SidewalkUpdateAccount


class UpdateWirelessDeviceRequest(BaseModel):
    DestinationName: Optional[DestinationName] = None
    Name: Optional[WirelessDeviceName] = None
    Description: Optional[Description] = None
    LoRaWAN: Optional[LoRaWANUpdateDevice] = None


class WirelessDeviceEvent(Enum):
    """
    The event for a log message, if the log message is tied to a wireless device.
    """

    Join = 'Join'
    Rejoin = 'Rejoin'
    Uplink_Data = 'Uplink_Data'
    Downlink_Data = 'Downlink_Data'
    Registration = 'Registration'


class WirelessDeviceEventLogOption(BaseModel):
    """
    <p>The log options for a wireless device event and can be used to set log levels for a specific wireless device event.</p> <p>For a LoRaWAN device, possible events for a log messsage are: <code>Join</code>, <code>Rejoin</code>, <code>Downlink_Data</code>, and <code>Uplink_Data</code>. For a Sidewalk device, possible events for a log message are <code>Registration</code>, <code>Downlink_Data</code>, and <code>Uplink_Data</code>.</p>
    """

    Event: WirelessDeviceEvent
    LogLevel: LogLevel


class WirelessDeviceEventLogOptionList(BaseModel):
    """
    The list of wireless device event log options.
    """

    __root__: Annotated[
        List[WirelessDeviceEventLogOption],
        Field(description='The list of wireless device event log options.'),
    ]


class WirelessDeviceStatistics(BaseModel):
    """
    Information about a wireless device's operation.
    """

    Arn: Optional[WirelessDeviceArn] = None
    Id: Optional[WirelessDeviceId] = None
    Type: Optional[WirelessDeviceType] = None
    Name: Optional[WirelessDeviceName] = None
    DestinationName: Optional[DestinationName] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    LoRaWAN: Optional[LoRaWANListDevice] = None
    Sidewalk: Optional[SidewalkListDevice] = None


class WirelessGatewayEvent(Enum):
    """
    The event for a log message, if the log message is tied to a wireless gateway.
    """

    CUPS_Request = 'CUPS_Request'
    Certificate = 'Certificate'


class WirelessGatewayEventLogOption(BaseModel):
    """
    <p>The log options for a wireless gateway event and can be used to set log levels for a specific wireless gateway event.</p> <p>For a LoRaWAN gateway, possible events for a log message are <code>CUPS_Request</code> and <code>Certificate</code>.</p>
    """

    Event: WirelessGatewayEvent
    LogLevel: LogLevel


class WirelessGatewayEventLogOptionList(BaseModel):
    """
    The list of wireless gateway event log options.
    """

    __root__: Annotated[
        List[WirelessGatewayEventLogOption],
        Field(description='The list of wireless gateway event log options.'),
    ]


class WirelessGatewayType(Enum):
    """
    The wireless gateway type.
    """

    LoRaWAN = 'LoRaWAN'


class AssociateAwsAccountWithPartnerAccountResponse(BaseModel):
    Sidewalk: Optional[SidewalkAccountInfo] = None
    Arn: Optional[PartnerAccountArn] = None


class Tag(BaseModel):
    """
    A simple label consisting of a customer-defined key-value pair
    """

    Key: TagKey
    Value: TagValue


class AssociateWirelessGatewayWithCertificateResponse(BaseModel):
    IotCertificateId: Optional[IotCertificateId] = None


class CreateDestinationResponse(BaseModel):
    Arn: Optional[DestinationArn] = None
    Name: Optional[DestinationName] = None


class CreateDeviceProfileResponse(BaseModel):
    Arn: Optional[DeviceProfileArn] = None
    Id: Optional[DeviceProfileId] = None


class FactoryPresetFreqsList(BaseModel):
    __root__: Annotated[List[PresetFreq], Field(max_items=20, min_items=0)]


class CreateServiceProfileResponse(BaseModel):
    Arn: Optional[ServiceProfileArn] = None
    Id: Optional[ServiceProfileId] = None


class CreateWirelessDeviceResponse(BaseModel):
    Arn: Optional[WirelessDeviceArn] = None
    Id: Optional[WirelessDeviceId] = None


class OtaaV11(BaseModel):
    """
    OTAA device object for v1.1
    """

    AppKey: Optional[AppKey] = None
    NwkKey: Optional[NwkKey] = None
    JoinEui: Optional[JoinEui] = None


class OtaaV10X(BaseModel):
    """
    OTAA device object for v1.0.x
    """

    AppKey: Optional[AppKey] = None
    AppEui: Optional[AppEui] = None


class CreateWirelessGatewayResponse(BaseModel):
    Arn: Optional[WirelessGatewayArn] = None
    Id: Optional[WirelessDeviceId] = None


class NetIdFilters(BaseModel):
    """
    A list of NetId values that are used by LoRa gateways to filter the uplink frames.
    """

    __root__: Annotated[
        List[NetId],
        Field(
            description='A list of NetId values that are used by LoRa gateways to filter the uplink frames.',
            max_items=10,
            min_items=0,
        ),
    ]


class SubBands(BaseModel):
    """
    A list of integer indicating which sub bands are supported by LoRa gateway.
    """

    __root__: Annotated[
        List[SubBand],
        Field(
            description='A list of integer indicating which sub bands are supported by LoRa gateway.',
            max_items=8,
            min_items=0,
        ),
    ]


class CreateWirelessGatewayTaskResponse(BaseModel):
    WirelessGatewayTaskDefinitionId: Optional[WirelessGatewayTaskDefinitionId] = None
    Status: Optional[WirelessGatewayTaskStatus] = None


class CreateWirelessGatewayTaskDefinitionResponse(BaseModel):
    Id: Optional[WirelessGatewayTaskDefinitionId] = None
    Arn: Optional[WirelessGatewayTaskDefinitionArn] = None


class GetDestinationResponse(BaseModel):
    Arn: Optional[DestinationArn] = None
    Name: Optional[DestinationName] = None
    Expression: Optional[Expression] = None
    ExpressionType: Optional[ExpressionType] = None
    Description: Optional[Description] = None
    RoleArn: Optional[RoleArn] = None


class GetPartnerAccountResponse(BaseModel):
    Sidewalk: Optional[SidewalkAccountInfoWithFingerprint] = None
    AccountLinked: Optional[AccountLinked] = None


class GetResourceLogLevelResponse(BaseModel):
    LogLevel: Optional[LogLevel] = None


class GetServiceEndpointResponse(BaseModel):
    ServiceType: Optional[WirelessGatewayServiceType] = None
    ServiceEndpoint: Optional[EndPoint] = None
    ServerTrust: Optional[CertificatePEM] = None


class GetWirelessGatewayCertificateResponse(BaseModel):
    IotCertificateId: Optional[IotCertificateId] = None
    LoRaWANNetworkServerCertificateId: Optional[IotCertificateId] = None


class GetWirelessGatewayStatisticsResponse(BaseModel):
    WirelessGatewayId: Optional[WirelessGatewayId] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    ConnectionStatus: Optional[ConnectionStatus] = None


class GetWirelessGatewayTaskResponse(BaseModel):
    WirelessGatewayId: Optional[WirelessGatewayId] = None
    WirelessGatewayTaskDefinitionId: Optional[WirelessGatewayTaskDefinitionId] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    TaskCreatedAt: Optional[ISODateTimeString] = None
    Status: Optional[WirelessGatewayTaskStatus] = None


class ListDestinationsResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    DestinationList: Optional[DestinationList] = None


class ListDeviceProfilesResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    DeviceProfileList: Optional[DeviceProfileList] = None


class ListPartnerAccountsResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    Sidewalk: Optional[SidewalkAccountList] = None


class SendDataToWirelessDeviceResponse(BaseModel):
    MessageId: Optional[MessageId] = None


class LoRaWANSendDataToDevice(BaseModel):
    """
    LoRaWAN router info.
    """

    FPort: Optional[FPort] = None


class SidewalkSendDataToDevice(BaseModel):
    """
    Information about a Sidewalk router.
    """

    Seq: Optional[Seq] = None
    MessageType: Optional[MessageType] = None


class TestWirelessDeviceResponse(BaseModel):
    Result: Optional[Result] = None


class WirelessDeviceLogOption(BaseModel):
    """
    The log options for wireless devices and can be used to set log levels for a specific type of wireless device.
    """

    Type: WirelessDeviceType
    LogLevel: LogLevel
    Events: Optional[WirelessDeviceEventLogOptionList] = None


class WirelessGatewayLogOption(BaseModel):
    """
    The log options for wireless gateways and can be used to set log levels for a specific type of wireless gateway.
    """

    Type: WirelessGatewayType
    LogLevel: LogLevel
    Events: Optional[WirelessGatewayEventLogOptionList] = None


class JoinEuiRange(BaseModel):
    """
    A pair of join EUI describing a range [BegEui, EndEui], both ends are inclusive.
    """

    __root__: Annotated[
        List[JoinEui],
        Field(
            description='A pair of join EUI describing a range [BegEui, EndEui], both ends are inclusive.',
            max_items=2,
            min_items=2,
        ),
    ]


class SessionKeysAbpV10X(BaseModel):
    """
    Session keys for ABP v1.1
    """

    NwkSKey: Optional[NwkSKey] = None
    AppSKey: Optional[AppSKey] = None


class SessionKeysAbpV11(BaseModel):
    """
    Session keys for ABP v1.1
    """

    FNwkSIntKey: Optional[FNwkSIntKey] = None
    SNwkSIntKey: Optional[SNwkSIntKey] = None
    NwkSEncKey: Optional[NwkSEncKey] = None
    AppSKey: Optional[AppSKey] = None


class TagList(BaseModel):
    __root__: Annotated[List[Tag], Field(max_items=200, min_items=0)]


class AssociateAwsAccountWithPartnerAccountRequest(BaseModel):
    Sidewalk: SidewalkAccountInfo
    ClientRequestToken: Optional[ClientRequestToken] = None
    Tags: Optional[TagList] = None


class CreateDestinationRequest(BaseModel):
    Name: DestinationName
    ExpressionType: ExpressionType
    Expression: Expression
    Description: Optional[Description] = None
    RoleArn: RoleArn
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class LoRaWANDeviceProfile(BaseModel):
    """
    LoRaWANDeviceProfile object.
    """

    SupportsClassB: Optional[SupportsClassB] = None
    ClassBTimeout: Optional[ClassBTimeout] = None
    PingSlotPeriod: Optional[PingSlotPeriod] = None
    PingSlotDr: Optional[PingSlotDr] = None
    PingSlotFreq: Optional[PingSlotFreq] = None
    SupportsClassC: Optional[SupportsClassC] = None
    ClassCTimeout: Optional[ClassCTimeout] = None
    MacVersion: Optional[MacVersion] = None
    RegParamsRevision: Optional[RegParamsRevision] = None
    RxDelay1: Optional[RxDelay1] = None
    RxDrOffset1: Optional[RxDrOffset1] = None
    RxDataRate2: Optional[RxDataRate2] = None
    RxFreq2: Optional[RxFreq2] = None
    FactoryPresetFreqsList: Optional[FactoryPresetFreqsList] = None
    MaxEirp: Optional[MaxEirp] = None
    MaxDutyCycle: Optional[MaxDutyCycle] = None
    RfRegion: Optional[RfRegion] = None
    SupportsJoin: Optional[SupportsJoin] = None
    Supports32BitFCnt: Optional[Supports32BitFCnt] = None


class CreateDeviceProfileRequest(BaseModel):
    Name: Optional[DeviceProfileName] = None
    LoRaWAN: Optional[LoRaWANDeviceProfile] = None
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class CreateServiceProfileRequest(BaseModel):
    Name: Optional[ServiceProfileName] = None
    LoRaWAN: Optional[LoRaWANServiceProfile] = None
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class WirelessGatewayLogOptionList(BaseModel):
    """
    The list of wireless gateway log options.
    """

    __root__: Annotated[
        List[WirelessGatewayLogOption],
        Field(description='The list of wireless gateway log options.'),
    ]


class WirelessDeviceLogOptionList(BaseModel):
    """
    The list of wireless device log options.
    """

    __root__: Annotated[
        List[WirelessDeviceLogOption],
        Field(description='The list of wireless device log options.'),
    ]


class LoRaWANGetServiceProfileInfo(BaseModel):
    """
    LoRaWANGetServiceProfileInfo object.
    """

    UlRate: Optional[UlRate] = None
    UlBucketSize: Optional[UlBucketSize] = None
    UlRatePolicy: Optional[UlRatePolicy] = None
    DlRate: Optional[DlRate] = None
    DlBucketSize: Optional[DlBucketSize] = None
    DlRatePolicy: Optional[DlRatePolicy] = None
    AddGwMetadata: Optional[AddGwMetadata] = None
    DevStatusReqFreq: Optional[DevStatusReqFreq] = None
    ReportDevStatusBattery: Optional[ReportDevStatusBattery] = None
    ReportDevStatusMargin: Optional[ReportDevStatusMargin] = None
    DrMin: Optional[DrMin] = None
    DrMax: Optional[DrMax] = None
    ChannelMask: Optional[ChannelMask] = None
    PrAllowed: Optional[PrAllowed] = None
    HrAllowed: Optional[HrAllowed] = None
    RaAllowed: Optional[RaAllowed] = None
    NwkGeoLoc: Optional[NwkGeoLoc] = None
    TargetPer: Optional[TargetPer] = None
    MinGwDiversity: Optional[MinGwDiversity] = None


class SidewalkDevice(SidewalkListDevice):
    """
    Sidewalk device object.
    """

    pass


class SidewalkDeviceMetadata(BaseModel):
    """
    MetaData for Sidewalk device.
    """

    Rssi: Optional[Integer] = None
    BatteryLevel: Optional[BatteryLevel] = None
    Event: Optional[Event] = None
    DeviceState: Optional[DeviceState] = None


class ServiceProfileList(BaseModel):
    __root__: List[ServiceProfile]


class WirelessDeviceStatisticsList(BaseModel):
    __root__: List[WirelessDeviceStatistics]


class LoRaWANGatewayMetadataList(BaseModel):
    __root__: List[LoRaWANGatewayMetadata]


class LoRaWANGatewayVersion(BaseModel):
    """
    LoRaWANGatewayVersion object.
    """

    PackageVersion: Optional[PackageVersion] = None
    Model: Optional[Model] = None
    Station: Optional[Station] = None


class LoRaWANUpdateGatewayTaskEntry(BaseModel):
    """
    LoRaWANUpdateGatewayTaskEntry object.
    """

    CurrentVersion: Optional[LoRaWANGatewayVersion] = None
    UpdateVersion: Optional[LoRaWANGatewayVersion] = None


class WirelessMetadata(BaseModel):
    """
    WirelessMetadata object.
    """

    LoRaWAN: Optional[LoRaWANSendDataToDevice] = None
    Sidewalk: Optional[SidewalkSendDataToDevice] = None


class SendDataToWirelessDeviceRequest(BaseModel):
    TransmitMode: TransmitMode
    PayloadData: PayloadData
    WirelessMetadata: Optional[WirelessMetadata] = None


class TagResourceRequest(BaseModel):
    Tags: TagList


class UpdateLogLevelsByResourceTypesRequest(BaseModel):
    DefaultLogLevel: Optional[LogLevel] = None
    WirelessDeviceLogOptions: Optional[WirelessDeviceLogOptionList] = None
    WirelessGatewayLogOptions: Optional[WirelessGatewayLogOptionList] = None


class UpdateWirelessGatewayTaskEntry(BaseModel):
    """
    UpdateWirelessGatewayTaskEntry object.
    """

    Id: Optional[WirelessGatewayTaskDefinitionId] = None
    LoRaWAN: Optional[LoRaWANUpdateGatewayTaskEntry] = None
    Arn: Optional[WirelessGatewayTaskDefinitionArn] = None


class AbpV11(BaseModel):
    """
    ABP device object for LoRaWAN specification v1.1
    """

    DevAddr: Optional[DevAddr] = None
    SessionKeys: Optional[SessionKeysAbpV11] = None


class AbpV10X(BaseModel):
    """
    ABP device object for LoRaWAN specification v1.0.x
    """

    DevAddr: Optional[DevAddr] = None
    SessionKeys: Optional[SessionKeysAbpV10X] = None


class JoinEuiFilters(BaseModel):
    """
    A list of JoinEuiRange used by LoRa gateways to filter LoRa frames.
    """

    __root__: Annotated[
        List[JoinEuiRange],
        Field(
            description='A list of JoinEuiRange used by LoRa gateways to filter LoRa frames.',
            max_items=3,
            min_items=0,
        ),
    ]


class LoRaWANUpdateGatewayTaskCreate(BaseModel):
    """
    LoRaWANUpdateGatewayTaskCreate object.
    """

    UpdateSignature: Optional[UpdateSignature] = None
    SigKeyCrc: Optional[Crc] = None
    CurrentVersion: Optional[LoRaWANGatewayVersion] = None
    UpdateVersion: Optional[LoRaWANGatewayVersion] = None


class GetDeviceProfileResponse(BaseModel):
    Arn: Optional[DeviceProfileArn] = None
    Name: Optional[DeviceProfileName] = None
    Id: Optional[DeviceProfileId] = None
    LoRaWAN: Optional[LoRaWANDeviceProfile] = None


class GetLogLevelsByResourceTypesResponse(BaseModel):
    DefaultLogLevel: Optional[LogLevel] = None
    WirelessGatewayLogOptions: Optional[WirelessGatewayLogOptionList] = None
    WirelessDeviceLogOptions: Optional[WirelessDeviceLogOptionList] = None


class GetServiceProfileResponse(BaseModel):
    Arn: Optional[ServiceProfileArn] = None
    Name: Optional[ServiceProfileName] = None
    Id: Optional[ServiceProfileId] = None
    LoRaWAN: Optional[LoRaWANGetServiceProfileInfo] = None


class ListServiceProfilesResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    ServiceProfileList: Optional[ServiceProfileList] = None


class ListTagsForResourceResponse(BaseModel):
    Tags: Optional[TagList] = None


class ListWirelessDevicesResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    WirelessDeviceList: Optional[WirelessDeviceStatisticsList] = None


class LoRaWANDevice(BaseModel):
    """
    LoRaWAN object for create functions.
    """

    DevEui: Optional[DevEui] = None
    DeviceProfileId: Optional[DeviceProfileId] = None
    ServiceProfileId: Optional[ServiceProfileId] = None
    OtaaV1_1: Optional[OtaaV11] = None
    OtaaV1_0_x: Optional[OtaaV10X] = None
    AbpV1_1: Optional[AbpV11] = None
    AbpV1_0_x: Optional[AbpV10X] = None


class CreateWirelessDeviceRequest(BaseModel):
    Type: WirelessDeviceType
    Name: Optional[WirelessDeviceName] = None
    Description: Optional[Description] = None
    DestinationName: DestinationName
    ClientRequestToken: Optional[ClientRequestToken] = None
    LoRaWAN: Optional[LoRaWANDevice] = None
    Tags: Optional[TagList] = None


class LoRaWANGateway(BaseModel):
    """
    LoRaWANGateway object.
    """

    GatewayEui: Optional[GatewayEui] = None
    RfRegion: Optional[RfRegion] = None
    JoinEuiFilters: Optional[JoinEuiFilters] = None
    NetIdFilters: Optional[NetIdFilters] = None
    SubBands: Optional[SubBands] = None


class CreateWirelessGatewayRequest(BaseModel):
    Name: Optional[WirelessGatewayName] = None
    Description: Optional[Description] = None
    LoRaWAN: LoRaWANGateway
    Tags: Optional[TagList] = None
    ClientRequestToken: Optional[ClientRequestToken] = None


class UpdateWirelessGatewayTaskCreate(BaseModel):
    """
    UpdateWirelessGatewayTaskCreate object.
    """

    UpdateDataSource: Optional[UpdateDataSource] = None
    UpdateDataRole: Optional[UpdateDataSource] = None
    LoRaWAN: Optional[LoRaWANUpdateGatewayTaskCreate] = None


class CreateWirelessGatewayTaskDefinitionRequest(BaseModel):
    AutoCreateTasks: AutoCreateTasks
    Name: Optional[WirelessGatewayTaskName] = None
    Update: Optional[UpdateWirelessGatewayTaskCreate] = None
    ClientRequestToken: Optional[ClientRequestToken] = None
    Tags: Optional[TagList] = None


class LoRaWANDeviceMetadata(BaseModel):
    """
    LoRaWAN device metatdata.
    """

    DevEui: Optional[DevEui] = None
    FPort: Optional[Integer] = None
    DataRate: Optional[Integer] = None
    Frequency: Optional[Integer] = None
    Timestamp: Optional[ISODateTimeString] = None
    Gateways: Optional[LoRaWANGatewayMetadataList] = None


class LoRaWANGatewayCurrentVersion(BaseModel):
    """
    LoRaWANGatewayCurrentVersion object.
    """

    CurrentVersion: Optional[LoRaWANGatewayVersion] = None


class WirelessGatewayTaskDefinitionList(BaseModel):
    __root__: List[UpdateWirelessGatewayTaskEntry]


class UpdateWirelessGatewayRequest(BaseModel):
    Name: Optional[WirelessGatewayName] = None
    Description: Optional[Description] = None
    JoinEuiFilters: Optional[JoinEuiFilters] = None
    NetIdFilters: Optional[NetIdFilters] = None


class WirelessGatewayStatistics(BaseModel):
    """
    Information about a wireless gateway's operation.
    """

    Arn: Optional[WirelessGatewayArn] = None
    Id: Optional[WirelessGatewayId] = None
    Name: Optional[WirelessGatewayName] = None
    Description: Optional[Description] = None
    LoRaWAN: Optional[LoRaWANGateway] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None


class GetWirelessDeviceResponse(BaseModel):
    Type: Optional[WirelessDeviceType] = None
    Name: Optional[WirelessDeviceName] = None
    Description: Optional[Description] = None
    DestinationName: Optional[DestinationName] = None
    Id: Optional[WirelessDeviceId] = None
    Arn: Optional[WirelessDeviceArn] = None
    ThingName: Optional[ThingName] = None
    ThingArn: Optional[ThingArn] = None
    LoRaWAN: Optional[LoRaWANDevice] = None
    Sidewalk: Optional[SidewalkDevice] = None


class GetWirelessDeviceStatisticsResponse(BaseModel):
    WirelessDeviceId: Optional[WirelessDeviceId] = None
    LastUplinkReceivedAt: Optional[ISODateTimeString] = None
    LoRaWAN: Optional[LoRaWANDeviceMetadata] = None
    Sidewalk: Optional[SidewalkDeviceMetadata] = None


class GetWirelessGatewayResponse(BaseModel):
    Name: Optional[WirelessGatewayName] = None
    Id: Optional[WirelessGatewayId] = None
    Description: Optional[Description] = None
    LoRaWAN: Optional[LoRaWANGateway] = None
    Arn: Optional[WirelessGatewayArn] = None
    ThingName: Optional[ThingName] = None
    ThingArn: Optional[ThingArn] = None


class GetWirelessGatewayFirmwareInformationResponse(BaseModel):
    LoRaWAN: Optional[LoRaWANGatewayCurrentVersion] = None


class GetWirelessGatewayTaskDefinitionResponse(BaseModel):
    AutoCreateTasks: Optional[AutoCreateTasks] = None
    Name: Optional[WirelessGatewayTaskName] = None
    Update: Optional[UpdateWirelessGatewayTaskCreate] = None
    Arn: Optional[WirelessGatewayTaskDefinitionArn] = None


class ListWirelessGatewayTaskDefinitionsResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    TaskDefinitions: Optional[WirelessGatewayTaskDefinitionList] = None


class WirelessGatewayStatisticsList(BaseModel):
    __root__: List[WirelessGatewayStatistics]


class ListWirelessGatewaysResponse(BaseModel):
    NextToken: Optional[NextToken] = None
    WirelessGatewayList: Optional[WirelessGatewayStatisticsList] = None
# generated by datamodel-codegen: #   filename:  openapi.yaml #   timestamp: 2021-12-31T02:51:07+00:00 Information about a Sidewalk account. Sidewalk device battery level. The certificate chain algorithm provided by sidewalk. List of sidewalk certificates. LoRaWANServiceProfile object. Describes a destination. List of device certificate chain. Describes a device profile. Device state defines the device status of sidewalk device. Sidewalk device status notification. The log level for a log message. Information about a Sidewalk account. LoRaWAN gateway metatdata. LoRaWAN object for list functions. LoRaWAN object for update functions. Sidewalk device message type. Default value is <code>CUSTOM_COMMAND_ID_NOTIFY</code>. Information about a service profile. Sidewalk object used by list functions. Sidewalk update. The event for a log message, if the log message is tied to a wireless device. <p>The log options for a wireless device event and can be used to set log levels for a specific wireless device event.</p> <p>For a LoRaWAN device, possible events for a log messsage are: <code>Join</code>, <code>Rejoin</code>, <code>Downlink_Data</code>, and <code>Uplink_Data</code>. For a Sidewalk device, possible events for a log message are <code>Registration</code>, <code>Downlink_Data</code>, and <code>Uplink_Data</code>.</p> The list of wireless device event log options. Information about a wireless device's operation. The event for a log message, if the log message is tied to a wireless gateway. <p>The log options for a wireless gateway event and can be used to set log levels for a specific wireless gateway event.</p> <p>For a LoRaWAN gateway, possible events for a log message are <code>CUPS_Request</code> and <code>Certificate</code>.</p> The list of wireless gateway event log options. The wireless gateway type. A simple label consisting of a customer-defined key-value pair OTAA device object for v1.1 OTAA device object for v1.0.x A list of NetId values that are used by LoRa gateways to filter the uplink frames. A list of integer indicating which sub bands are supported by LoRa gateway. LoRaWAN router info. Information about a Sidewalk router. The log options for wireless devices and can be used to set log levels for a specific type of wireless device. The log options for wireless gateways and can be used to set log levels for a specific type of wireless gateway. A pair of join EUI describing a range [BegEui, EndEui], both ends are inclusive. Session keys for ABP v1.1 Session keys for ABP v1.1 LoRaWANDeviceProfile object. The list of wireless gateway log options. The list of wireless device log options. LoRaWANGetServiceProfileInfo object. Sidewalk device object. MetaData for Sidewalk device. LoRaWANGatewayVersion object. LoRaWANUpdateGatewayTaskEntry object. WirelessMetadata object. UpdateWirelessGatewayTaskEntry object. ABP device object for LoRaWAN specification v1.1 ABP device object for LoRaWAN specification v1.0.x A list of JoinEuiRange used by LoRa gateways to filter LoRa frames. LoRaWANUpdateGatewayTaskCreate object. LoRaWAN object for create functions. LoRaWANGateway object. UpdateWirelessGatewayTaskCreate object. LoRaWAN device metatdata. LoRaWANGatewayCurrentVersion object. Information about a wireless gateway's operation.