# generated by datamodel-codegen:
#   filename:  vault-management-api.json

from typing import Literal, NotRequired, TypedDict


class ItemSecureNote(TypedDict):
    type: NotRequired[Literal[0]]


class ItemCard(TypedDict):
    cardholderName: NotRequired[str]
    brand: NotRequired[Literal["visa"]]
    number: NotRequired[str]
    expMonth: NotRequired[str]
    expYear: NotRequired[str]
    code: NotRequired[str]


class ItemIdentity(TypedDict):
    title: NotRequired[str]
    firstName: NotRequired[str]
    middleName: NotRequired[str]
    lastName: NotRequired[str]
    address1: NotRequired[str]
    address2: NotRequired[str]
    address3: NotRequired[str]
    city: NotRequired[str]
    state: NotRequired[str]
    postalCode: NotRequired[str]
    country: NotRequired[str]
    company: NotRequired[str]
    email: NotRequired[str]
    phone: NotRequired[str]
    ssn: NotRequired[str]
    username: NotRequired[str]
    passportNumber: NotRequired[str]
    licenseNumber: NotRequired[str]


class Uris(TypedDict):
    match: NotRequired[Literal[0, 1, 2, 3, 4, 5]]
    uri: NotRequired[str]


class Field(TypedDict):
    name: NotRequired[str]
    value: NotRequired[str]
    type: NotRequired[Literal[0, 1, 2, 3]]


class Folder(TypedDict):
    name: NotRequired[str]


class SendText(TypedDict):
    text: NotRequired[str]
    hidden: NotRequired[bool]


class Group(TypedDict):
    id: NotRequired[str]
    readOnly: NotRequired[bool]
    hidePasswords: NotRequired[bool]


class Template(TypedDict):
    serverUrl: NotRequired[str]
    lastSync: NotRequired[str]
    userEmail: NotRequired[str]
    userID: NotRequired[str]
    status: NotRequired[Literal["locked", "unlocked", "unauthenticated"]]


class Data(TypedDict):
    object: NotRequired[Literal["template"]]
    template: NotRequired[Template]


class Status(TypedDict):
    success: NotRequired[bool]
    data: NotRequired[Data]


class Data1(TypedDict):
    noColor: NotRequired[bool]
    object: NotRequired[str]
    title: NotRequired[str]
    message: NotRequired[str]


class LockunlockSuccess(TypedDict):
    success: NotRequired[bool]
    data: NotRequired[Data1]


class Deviceapprovalproperties(TypedDict):
    id: NotRequired[str]
    userId: NotRequired[str]
    email: NotRequired[str]
    requestDeviceIdentifier: NotRequired[str]
    requestDeviceType: NotRequired[str]
    requestIpAddress: NotRequired[str]
    creationDate: NotRequired[str]


class ItemLogin(TypedDict):
    uris: NotRequired[Uris]
    username: NotRequired[str]
    password: NotRequired[str]
    totp: NotRequired[str]


class SendTemplate(TypedDict):
    name: NotRequired[str]
    notes: NotRequired[str]
    type: NotRequired[Literal[0, 1]]
    text: NotRequired[SendText]
    file: NotRequired[str]
    maxAccessCount: NotRequired[int]
    deletionDate: NotRequired[str]
    expirationDate: NotRequired[str]
    password: NotRequired[str]
    disabled: NotRequired[bool]
    hideEmail: NotRequired[bool]


class Collection(TypedDict):
    organizationId: NotRequired[str]
    name: NotRequired[str]
    externalId: NotRequired[str]
    groups: NotRequired[list[Group]]


type Deviceapprovallist = list[Deviceapprovalproperties]


class ItemTemplate(TypedDict):
    organizationId: NotRequired[str]
    collectionIds: NotRequired[list[str]]
    folderId: NotRequired[str]
    type: NotRequired[Literal[1, 2, 3, 4]]
    name: NotRequired[str]
    notes: NotRequired[str]
    favorite: NotRequired[bool]
    fields: NotRequired[list[Field]]
    login: NotRequired[ItemLogin]
    secureNote: NotRequired[ItemSecureNote]
    card: NotRequired[ItemCard]
    identity: NotRequired[ItemIdentity]
    reprompt: NotRequired[Literal[0, 1]]
