Files
annotations/Azaion.Inference/credentials.pyx
T
2025-02-13 18:13:15 +02:00

18 lines
451 B
Cython

from msgpack import unpackb
cdef class Credentials:
def __init__(self, str email, str password, str folder):
self.email = email
self.password = password
self.folder = folder
@staticmethod
cdef from_msgpack(bytes data):
unpacked = unpackb(data, strict_map_key=False)
return Credentials(
unpacked.get("Email"),
unpacked.get("Password"),
unpacked.get("Folder"))