获取UID
- //获取自己的UID
- %hook TBSDKConnection
- - (void)addRequestHeader:(id)arg1 value:(id)arg2{
- %log;//addRequestHeader:x-uid value:2795xxxxxx]
- if([arg1 isEqualToString:@"x-uid"]){
- [xddCode sharedInstance].myUserID = arg2;
- }
- %orig;//call
- }
- %end
复制代码 创建群Call
- +(void)addQun{
-
- NSString *groupDTO = [NSString stringWithFormat:@"{"namespace":0,"entityId":"","name":"qun","notice":"notice","summary":"summary","type":"G","accountIds":["%@#3"],"headPic":"","createTime":6256017216,"modifyTime":7521904624,"bizType":"0","linkGroups":[],"attributes":"","isDeleted":false,"bizExt":{},"ampExt":{}}",[xddCode sharedInstance].myUserID];
- NSDictionary *params = [NSDictionary dictionaryWithObjectsAndKeys:
- @"{}", @"bizCtx",
- @"taobao-ios", @"accessKey",
- @"taobao-ios-secret", @"accessSecret",
- groupDTO, @"groupDTO",
- nil];
-
-
- MPMAPIRequest*req = [[NSClassFromString(@"MPMAPIRequest") alloc] init];
- req.bPost = true;
- req.needAccount = false;
- req.onMainThreadCallback = false;
- req.version = @"1.0";
- req.userId = [xddCode sharedInstance].myUserID;
- req.param = params;
- req.retryCount = 1;
- req.timeOut = 30;
-
- req.api = @"mtop.taobao.wireless.amp2.im.group.createGroup";
-
- [NSClassFromString(@"MPMRequestHelper") asyncRequest:req successCallback:^(NSDictionary* dic) {
- NSDictionary*data = dic[@"data"];
- // [0] @"actionCode" : @"DIS_ERR_ADD_USER"
- // [1] @"success" : @"false" [0] @"success" : @"true"
- // [2] @"actionInfo" : @"入群失败,请重新尝试"
- NSString*success = data[@"success"];
- NSString*actionInfo = data[@"actionInfo"];
- NSDictionary*value = data[@"value"];
- if([@"true" isEqualToString:success]){
- // [1] @"value" : 13 key/value pairs
- // [1] @"entityId" : @"0_G_2xxxx31#3_15xxxx093_0"
- actionInfo = value[@"entityId"];
- ### 最后
- **其实要轻松掌握很简单,要点就两个:**
- 1. 找到一套好的视频资料,紧跟大牛梳理好的知识框架进行学习。
- 2. 多练。 (视频优势是互动感强,容易集中注意力)
- **你不需要是天才,也不需要具备强悍的天赋,只要做到这两点,短期内成功的概率是非常高的。**
- 对于很多初中级Android工程师而言,想要提升技能,往往是自己摸索成长,不成体系的学习效果低效漫长且无助。
- ##### 阿里P7Android高级教程
- **下面资料部分截图,诚意满满:特别适合有3-5年开发经验的Android程序员们学习。**
- ![](https://img-blog.csdnimg.cn/img_convert/abceac4938f7b4639fab1877154fedfb.webp?x-oss-process=image/format,png)
- 附送高清脑图,高清知识点讲解教程,以及一些面试真题及答案解析。送给需要的提升技术、近期面试跳槽、自身职业规划迷茫的朋友们。
- **Android核心高级技术PDF资料,BAT大厂面试真题解析;**
- ![](https://img-blog.csdnimg.cn/img_convert/cddab1d654d435f8abd0e50b4619f74d.webp?x-oss-process=image/format,png)
- 加入社区》https://bbs.csdn.net/forums/4304bb5a486d4c3ab8389e65ecb71ac0
- roid核心高级技术PDF资料,BAT大厂面试真题解析;**
- [外链图片转存中...(img-1Wv2kZzd-1725781282243)]
- 加入社区》https://bbs.csdn.net/forums/4304bb5a486d4c3ab8389e65ecb71ac0
复制代码 免责声明:如果侵犯了您的权益,请联系站长,我们会及时删除侵权内容,谢谢合作!更多信息从访问主页:qidao123.com:ToB企服之家,中国第一个企服评测及商务社交产业平台。 |