# generated by fastapi-codegen:
# filename: openapi.yaml
# timestamp: 2025-06-29T03:05:27+00:00
from __future__ import annotations
from enum import Enum
from typing import Optional
from pydantic import BaseModel, Field
class Challenge(BaseModel):
alternativeChallenge: Optional[str] = Field(
None,
description='Challenge generated with the old signing key, the bytes representation of SignedData (this will only be present during key rotation).',
)
challenge: Optional[str] = Field(
None, description='Generated challenge, the bytes representation of SignedData.'
)
class Empty(BaseModel):
pass
class VerifyChallengeResponseRequest(BaseModel):
challengeResponse: Optional[str] = Field(
None,
description='Required. The generated response to the challenge, the bytes representation of SignedData.',
)
expectedIdentity: Optional[str] = Field(
None,
description="Optional. Service can optionally provide identity information about the device or user associated with the key. For an EMK, this value is the enrolled domain. For an EUK, this value is the user's email address. If present, this value will be checked against contents of the response, and verification will fail if there is no match.",
)
class KeyTrustLevel(Enum):
KEY_TRUST_LEVEL_UNSPECIFIED = 'KEY_TRUST_LEVEL_UNSPECIFIED'
CHROME_OS_VERIFIED_MODE = 'CHROME_OS_VERIFIED_MODE'
CHROME_OS_DEVELOPER_MODE = 'CHROME_OS_DEVELOPER_MODE'
CHROME_BROWSER_HW_KEY = 'CHROME_BROWSER_HW_KEY'
CHROME_BROWSER_OS_KEY = 'CHROME_BROWSER_OS_KEY'
class VerifyChallengeResponseResult(BaseModel):
customerId: Optional[str] = Field(
None,
description='Unique customer id that this device belongs to, as defined by the Google Admin SDK at https://developers.google.com/admin-sdk/directory/v1/guides/manage-customers',
)
devicePermanentId: Optional[str] = Field(
None,
description='Device permanent id is returned in this field (for the machine response only).',
)
deviceSignal: Optional[str] = Field(
None, description='Device signal in json string representation.'
)
keyTrustLevel: Optional[KeyTrustLevel] = Field(
None, description='Device attested key trust level.'
)
signedPublicKeyAndChallenge: Optional[str] = Field(
None,
description='Certificate Signing Request (in the SPKAC format, base64 encoded) is returned in this field. This field will be set only if device has included CSR in its challenge response. (the option to include CSR is now available for both user and machine responses)',
)
virtualDeviceId: Optional[str] = Field(
None,
description='Virtual device id of the device. The definition of virtual device id is platform-specific.',
)
class FieldXgafv(Enum):
field_1 = '1'
field_2 = '2'
class Alt(Enum):
json = 'json'
media = 'media'
proto = 'proto'