8 lines
333 B
Python
8 lines
333 B
Python
# utils/jwt/chongming_jwt.pyi
|
|||
|
|
from typing import Optional
|
||
|
|
|
||
|
|
class JWT:
|
||
|
|
def __init__(self, secret: str, algorithm: Optional[str] = None) -> None: ...
|
||
|
|
def encode(self, payload: str, expires_in_seconds: Optional[int] = None) -> str: ...
|
||
|
|
def decode(self, token: str) -> str: ...
|
||
|
|
def validate(self, token: str) -> bool: ...
|