public static async Task <UserHash[]> AllBlockList(string uid) { int page = 1; string s = await BcyJson.BlockList(uid, page ++); var r = BlockListJson.FromJson(s); s = await BcyJson.BlockList(uid, page ++); while (s.Length > BcyJson.MinValidJsonLen) { r.Data.UserHash = r.Data.UserHash.Union(BlockListJson.FromJson(s).Data.UserHash).ToArray(); s = await BcyJson.BlockList(uid, page ++); } return(r.Data.UserHash); }
public static async Task <Item[]> Post_Video(string mid, int page, string uid) => PostJson.FromJson(await BcyJson.Post_Article(mid, page, uid)).Data.Items;
/// <summary> /// 黑名单列表 /// </summary> /// <param name="uid">self_uid</param> public static async Task <UserHash[]> BlockList(string uid, int page) => BlockListJson.FromJson(await BcyJson.BlockList(uid, page)).Data.UserHash;
public static async Task <CollectionElement[]> GetSubscribeCollectionList() => GetMyCollectionListJson.FromJson(await BcyJson.GetSubscribeCollectionList()).Data.Collections;
public static async Task <PcAnnounceJson[]> PcAnnounce() => PcAnnounceJson.FromJson(await BcyJson.PcAnnounce());
public static async Task <NotifiesItem[]> Message_ItemSetUpdate(int page) => MessageJson.FromJson(await BcyJson.Message_ItemSetUpdate(page)).Data.Notifies;
/// <summary> /// 取消收藏 /// </summary> public static async Task <bool> UnCollect(string item_id) => (await BcyJson.Collect(item_id)).Length > BcyJson.MinValidJsonLen;
/// <summary> /// 发布评论 /// </summary> public static async Task <bool> ReplyPublish(string content, string item_id) => (await BcyJson.ReplyPublish(content, item_id)).Length > BcyJson.MinValidJsonLen;
/// <summary> /// 获取推荐(ok)或特定频道内容(error:20200611) /// </summary> /// <param name="cid">channel_id</param> /// <param name="refer">feed,channel/channel_video(Just use channel is OK!)</param> /// <param name="direction"></param> public static async Task <Item[]> GetFeeds(string cid, string refer = "channel", string direction = "loadmore") => GetFeedsJson.FromJson(await BcyJson.GetFeeds(cid, refer, direction)).Data.ItemInfo;
public static async Task <Item[]> FriendsFeed() => FriendsFeedJson.FromJson(await BcyJson.FriendsFeed()).Data.ItemInfo;
public static async Task <bool> SendMessage_FeedBackToMaid(string content) => (await BcyJson.SendMessage_FeedBackToMaid(content)).Length > BcyJson.MinValidJsonLen;
/// <summary> /// 发送私信 /// </summary> public static async Task <bool> SendMessage(string content, string to_uid) => (await BcyJson.SendMessage(content, to_uid)).Length > BcyJson.MinValidJsonLen;
public static async Task <bool> Follow_UnFollow(string fid) => (await BcyJson.Follow_UnFollow(fid)).Length > BcyJson.MinValidJsonLen;
/// <summary> /// 查询用户信息 /// </summary> public static async Task <UserInfoData> Info(string uid) => InfoJson.FromJson(await BcyJson.Info(uid)).Data;
public static async Task <Item[]> Favor_Collect(string uid, string mid, string since, int size = 35) => PostJson.FromJson(await BcyJson.Favor_Collect(uid, mid, since, size)).Data.Items;
public static async Task <TopListItemInfoItem[]> RankItemInfo_Novel_NewPeople_Week(int p, string date) => RankItemInfoJson.FromJson(await BcyJson.RankItemInfo_Novel_NewPeople_Week(p, date)).Data.TopListItemInfo;
public static async Task <ReplyData[]> ReplyList_Time(int page, string item_id) => ReplyListJson.FromJson(await BcyJson.ReplyList(page, item_id, "time")).Data.Data;
public static async Task <Item[]> GetFeeds() => GetFeedsJson.FromJson(await BcyJson.GetFeeds()).Data.ItemInfo;
public static async Task <NotifiesItem[]> Message_Remind(int page) => MessageJson.FromJson(await BcyJson.Message_Remind(page)).Data.Notifies;
public static async Task <Item[]> GetFeeds_Dance(string direction = "loadmore") => GetFeedsJson.FromJson(await BcyJson.GetFeeds_Dance(direction)).Data.ItemInfo;
public static async Task <Item[]> CircleFeed(string circle_id, int sort_type = 2, int grid_type = 10) => CircleFeedJson.FromJson(await BcyJson.CircleFeed(circle_id, sort_type, grid_type)).Data.Items;
public static async Task <InfosItem[]> HotCircleList() => HotCircleListJson.FromJson(await BcyJson.HotCircleList()).Data.Infos;
/// <summary> /// 公告 /// </summary> public static async Task <PcAnnounceJson[]> PcAnnounce(string since, int limit) => PcAnnounceJson.FromJson(await BcyJson.PcAnnounce(since, limit));
/// <summary> /// 我的消息 /// </summary> /// <param name="isPre">"n"</param> /// <param name="page">1</param> /// <param name="pageType">"notify" or "remind" or "itemsetupdate"</param> /// <returns></returns> private static async Task <NotifiesItem[]> Message(string isPre, int page, string pageType) => MessageJson.FromJson(await BcyJson.Message(isPre, page, pageType)).Data.Notifies;
/// <summary> /// 我关注的合集 /// </summary> public static async Task <CollectionElement[]> GetSubscribeCollectionList(string since, int sort = 0) => GetMyCollectionListJson.FromJson(await BcyJson.GetSubscribeCollectionList(since, sort)).Data.Collections;
public static async Task <TopListItemInfoItem[]> RankItemInfo_Cos_LastDay(int p, string date) => RankItemInfoJson.FromJson(await BcyJson.RankItemInfo_Cos_LastDay(p, date)).Data.TopListItemInfo;
/// <summary> /// 关注、粉丝、关注的圈子 /// </summary> /// <param name="uid">self_uid</param> /// <param name="page">1</param> /// <param name="follow_type">0-3</param> /// <returns></returns> //我的关注 follow_type=0 //我的粉丝 follow_type=1 //互相关注 follow_type=2 //我关注的圈子 follow_type=3 public static async Task <UserFollowInfo[]> FollowList(string uid, int page, int follow_type) => FollowListJson.FromJson(await BcyJson.FollowList(uid, page, follow_type)).Data.UserFollowInfo;
public static async Task <TopListItemInfoItem[]> RankItemInfo_Video_SiteTop_3Day(int p) => RankItemInfoJson.FromJson(await BcyJson.RankItemInfo_Video_SiteTop_3Day(p)).Data.TopListItemInfo;
public static async Task <TopListItemInfoItem[]> RankItemInfo_Novel_SiteTop_Week(int p) => RankItemInfoJson.FromJson(await BcyJson.RankItemInfo_Novel_SiteTop_Week(p)).Data.TopListItemInfo;
public static async Task <Item[]> SelfPosts(string uid) => SelfPostJson.FromJson(await BcyJson.SelfPosts(uid)).Data.Items;