mirror of
https://github.com/revanced/revanced-api.git
synced 2025-04-29 14:14:29 +02:00
40 lines
699 B
Python
40 lines
699 B
Python
from pydantic import BaseModel
|
|
|
|
|
|
class WalletFields(BaseModel):
|
|
"""
|
|
Implements the fields for a crypto wallet.
|
|
"""
|
|
|
|
network: str
|
|
currency_code: str
|
|
address: str
|
|
preferred: bool
|
|
|
|
|
|
class LinkFields(BaseModel):
|
|
"""
|
|
Implements the fields for a donation link.
|
|
"""
|
|
|
|
name: str
|
|
url: str
|
|
preferred: bool
|
|
|
|
|
|
class DonationFields(BaseModel):
|
|
"""
|
|
A Pydantic BaseModel that represents all the donation links and wallets.
|
|
"""
|
|
|
|
wallets: list[WalletFields]
|
|
links: list[LinkFields]
|
|
|
|
|
|
class DonationsResponseModel(BaseModel):
|
|
"""
|
|
A Pydantic BaseModel that represents a dictionary of donation links.
|
|
"""
|
|
|
|
donations: DonationFields
|