(size, uid_format=False)
return token
Create a random sring.
Create a random sring.
Create a random sring .
def gen_uid(size, uid_format=False):
    """Create a random sring."""
    if uid_format:
        token = f"BlinkCamera_{secrets.token_hex(4)}-{secrets.token_hex(2)}-{secrets.token_hex(2)}-{secrets.token_hex(2)}-{secrets.token_hex(6)}"
    else:
        token = secrets.token_hex(size)
    return token
def gen_uid ( size , uid_format = False ) : if uid_format : token = f"BlinkCamera_{secrets.token_hex(4)}-{secrets.token_hex(2)}-{secrets.token_hex(2)}-{secrets.token_hex(2)}-{secrets.token_hex(6)}" else : token = secrets . token_hex ( size ) return token