H5 API definations

class aioqzone.model.api.QzoneApi(**data)

The base class for all Qzone APIs below.

host: ClassVar[str] = 'https://h5.qzone.qq.com'
http_method: ClassVar[Literal['GET', 'POST']]
path: ClassVar[str]
keep_alive: ClassVar[bool] = True
is_json: ClassVar[bool] = False
referer: str
attach_token: ClassVar[bool] = True
login_required: ClassVar[bool] = True
params: TyRequest
response: ClassVar[Type[TyResponse]]
property url: URL
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.IndexPageApi(**data)
response

IndexPageResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
path: ClassVar[str] = '/mqzone/index'
keep_alive: ClassVar[bool] = False
attach_token: ClassVar[bool] = False
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.UserProfileApi(**data)
response

ProfilePagePesp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
path: ClassVar[str] = '/mqzone/profile'
keep_alive: ClassVar[bool] = False
attach_token: ClassVar[bool] = False
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.FeedPageApi(**data)
response

FeedPageResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
path: ClassVar[str] = '/webapp/json/mqzone_feeds/getActiveFeeds'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.ShuoshuoApi(**data)
response

DetailResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
path: ClassVar[str] = '/webapp/json/mqzone_detail/shuoshuo'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.GetFeedsApi(**data)
response

ProfileResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = '/get_feeds'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.GetCountApi(**data)
response

FeedCount 的别名

params: GetCountParams
http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = '/feeds/mfeeds_get_count'
is_json: ClassVar[bool] = True
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.LikeApi(**data)
response

SingleReturnResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'POST'
path: ClassVar[str] = '/proxy/domain/w.qzone.qq.com/cgi-bin/likes/internal_dolike_app'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.UnlikeApi(**data)
path: ClassVar[str] = '/proxy/domain/w.qzone.qq.com/cgi-bin/likes/internal_unlike_app'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.AddCommentApi(**data)
response

AddCommentResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'POST'
path: ClassVar[str] = '/webapp/json/qzoneOperation/addComment'
is_json: ClassVar[bool] = True
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.ListFriendApi(**data)
http_method: ClassVar[Literal['GET', 'POST']] = 'GET'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = '/friend/mfriend_list'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.PublishMoodApi(**data)
response

PublishMoodResp 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'POST'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = '/mood/publish_mood'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.AddOperationApi(**data)
response: Type[QzoneResponse]
http_method: ClassVar[Literal['GET', 'POST']] = 'POST'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = 'operation/operation_add'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.UploadPicApi(**data)
response

UploadPicResponse 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'POST'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = '/up/cgi-bin/upload/cgi_upload_pic_v2'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.PhotosPreuploadApi(**data)
response

PhotosPreuploadResponse 的别名

http_method: ClassVar[Literal['GET', 'POST']] = 'POST'
host: ClassVar[str] = 'https://mobile.qzone.qq.com'
path: ClassVar[str] = '/up/cgi-bin/upload/cgi_upload_pic_v2'
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

Parameters

class aioqzone.model.api.request.QzoneRequestParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ()
ts_fields: ClassVar[Tuple[str, ...]] = ()
build_params(uin, timestamp=None)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.ActiveFeedsParams(**data)
attach_info: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.AvatarParams(**data)
hostuin: int
size: Literal[100, 640]
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.GetFeedsParams(**data)
hostuin: int
attach_info: str
res_type: int
refresh_type: int
format: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.ProfileParams(**data)
hostuin: int
start_time: float
ts_fields: ClassVar[Tuple[str, ...]] = ('starttime',)
ms(start_time)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.ShuoshuoParams(**data)
fid: str
uin: int
appid: int
busi_param: str
format: str
count: int
refresh_type: int
subid: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.GetCountParams(**data)
format: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.DolikeParam(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('opuin',)
unikey: str
curkey: str
appid: int
opr_type: str
format: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.AddCommentParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('uin',)
hostuin: int
fid: str
private: int
content: str
appid: int
bypass_param: dict
busi_param: dict
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.AddCommentParamsLegacy(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('uin',)
hostuin: int
topicId: str
feedsType: int
content: str
photos: List[HttpUrl]
private: int
inCharset: str
outCharset: str
plat: str
source: str
isSignIn: str
format: str
ref: str
richtype: str
paramstr: str
richval(photos)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.DeleteCommentParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('uin',)
hostUin: int
topicId: str
feedsType: int
commentId: int
commentUin: int
inCharset: str
outCharset: str
plat: str
source: str
format: str
ref: str
paramstr: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.PublishMoodParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('res_uin',)
content: str
photos: List[PhotoData]
sync_weibo: int
ugc_right: UgcRight
opr_type: str
format: str
richval(photos)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.DeleteUgcParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('res_uin',)
appid: int
fid: str
opr_type: str
real_del: int
format: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.UploadPicParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('uin',)
picture: bytes
hd_height: int
hd_width: int
hd_quality: int
base64: int
output_type: str
preupload: int
charset: str
output_charset: str
logintype: str
Exif_CameraMaker: str
Exif_CameraModel: str
Exif_Time: str
b64_picture(picture)
返回类型:

str

classmethod from_image(image_file, quality=70)
classmethod from_bytes(image_bytes, quality=70)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.PhotosPreuploadParams(**data)
uin_fields: ClassVar[Tuple[str, ...]] = ('uin',)
upload_pics: List[UploadPicResponse]
cur_num: int
upload_hd: int
preupload: int
output_type: str
uploadtype: int
albumtype: int
big_style: int
op_src: int
charset: str
output_charset: str
refer: str
property uploadNum
build_params(uin, timestamp=None)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.UgcRight(*values)
unknown = 0
all = 1
qq = 4
part = 16
self = 64
blacklist = 128
class aioqzone.model.api.request.PhotoData(**data)
albumid: str
lloc: str
sloc: str
type: str
height: int
width: int
origin_uuid: str
origin_height: int
origin_width: int
to_richval()
classmethod from_PicInfo(o)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.request.SetTopParams(**data)
fid: str
set_top: bool
need_change: int
serialize_set_top(set_top)
返回类型:

str

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

Responses

class aioqzone.model.api.response.QzoneResponse(**data)
classmethod from_response_object(obj)

Parses the response text or object recieved from Qzone API.

参数:

obj (Dict[str, Any]) -- the parsed response object. see .response_to_object

抛出:

aioqzone.exception.QzoneError -- if returned result code != 0

返回类型:

Self

返回:

Self

async classmethod response_to_object(response)
返回类型:

Dict[str, Any]

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.FeedPageResp(**data)

Represents RESPonse from get feed page operation. Used to validate response data in aioqzone.api.h5.QzoneH5API.index() and aioqzone.api.h5.QzoneH5API.getActivateFeeds()

hasmore: bool
attachinfo: str
newcnt: int
undeal_info: FeedCount
vFeeds: List[FeedData]
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.ProfileResp(**data)
vFeeds: List[ProfileFeedData]
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.IndexPageResp(**data)
qzonetoken: str
async classmethod response_to_object(response)
返回类型:

Dict[str, Any]

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.ProfilePagePesp(**data)
info: QzoneInfo
feedpage: ProfileResp
qzonetoken: str
async classmethod response_to_object(response)
返回类型:

Dict[str, Any]

classmethod from_response_object(obj)

Parses the response text or object recieved from Qzone API.

参数:

obj (Dict[str, Any]) -- the parsed response object. see .response_to_object

抛出:

aioqzone.exception.QzoneError -- if returned result code != 0

返回类型:

Self

返回:

Self

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.DetailResp(**data)
hasmore: bool
attach_info: str
classmethod remove_prefix(v)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.FeedCount(**data)
active_cnt: int
passive_cnt: int
gamebar_cnt: int
gift_cnt: int
visitor_cnt: int
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.SingleReturnResp(**data)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_post_init(context, /)

This function is meant to behave like a BaseModel method to initialize private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

返回类型:

None

Args:

self: The BaseModel instance. context: The context.

class aioqzone.model.api.response.AddCommentResp(**data)
ret: int
msg: str
verifyurl: str
commentid: int
commentLikekey: HttpUrl
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.AddCommentLegacyResp(**data)
smooth_policy: dict
feeds: str
async classmethod response_to_object(response)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_post_init(context, /)

This function is meant to behave like a BaseModel method to initialize private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

返回类型:

None

Args:

self: The BaseModel instance. context: The context.

class aioqzone.model.api.response.DeleteCommentResp(**data)
feeds: str
async classmethod response_to_object(response)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.PublishMoodResp(**data)
ret: int
msg: str
fid: str
undeal_info: FeedCount
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.DeleteUgcResp(**data)
ret: int
msg: str
undeal_info: FeedCount
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.UploadPicResponse(**data)
filelen: int
filemd5: str
async classmethod response_to_object(response)
返回类型:

Dict[str, Any]

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_post_init(context, /)

This function is meant to behave like a BaseModel method to initialize private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

返回类型:

None

Args:

self: The BaseModel instance. context: The context.

class aioqzone.model.api.response.PhotosPreuploadResponse(**data)
photos: List[PicInfo]
async classmethod response_to_object(response)
返回类型:

Dict[str, Any]

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_post_init(context, /)

This function is meant to behave like a BaseModel method to initialize private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

返回类型:

None

Args:

self: The BaseModel instance. context: The context.

class aioqzone.model.api.response.FeedData(**data)
like: LikeInfo
comment: FeedComment
original: FeedOriginal | Share | None
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

operation: FeedOperation
visitor: Visitor
class aioqzone.model.api.response.PicInfo(**data)
pre: HttpUrl
url: HttpUrl
sloc: str

id of small picture

lloc: str

id of large picture

width: int
height: int
albumid: str
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_post_init(context, /)

This function is meant to behave like a BaseModel method to initialize private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

返回类型:

None

Args:

self: The BaseModel instance. context: The context.

class aioqzone.model.api.response.ProfileFeedData(**data)
like: ProfileLikeInfo
comment: ProfileComment
original: ProfileFeedOriginal | Share | None
operation: FeedOperation
visitor: Visitor
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class aioqzone.model.api.response.AvatarResponse(**data)
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_post_init(context, /)

This function is meant to behave like a BaseModel method to initialize private attributes.

It takes context as an argument since that's what pydantic-core passes when calling it.

返回类型:

None

Args:

self: The BaseModel instance. context: The context.

avatar: bytes
async classmethod response_to_object(response)
返回类型:

Dict[str, Any]