Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

可以实现主动获取好友申请列表并且同意好友申请吗? #2615

Open
fkxxyz opened this issue Apr 9, 2023 · 2 comments · May be fixed by #2786
Open

可以实现主动获取好友申请列表并且同意好友申请吗? #2615

fkxxyz opened this issue Apr 9, 2023 · 2 comments · May be fixed by #2786
Labels
N 优先级: 一般 s:core 子系统: mirai-core t:feature 类型: 新特性 x:protocol 属性: 协议相关
Milestone

Comments

@fkxxyz
Copy link

fkxxyz commented Apr 9, 2023

收到好友申请事件时,如果当时选择不处理,后续再也无法通过api来同意这个申请了。

我不想做成自动同意申请,是因为短时间内加好友太多容易被风控,所以想自己设计算法来控制添加频率。

oicq 是有这个功能的,希望移植过来。

@fkxxyz fkxxyz added the t:feature 类型: 新特性 label Apr 9, 2023
@fkxxyz fkxxyz changed the title 可以实现主动获取好友申请列表并且同意还有申请吗? 可以实现主动获取好友申请列表并且同意好友申请吗? Apr 9, 2023
@Him188 Him188 added N 优先级: 一般 s:core 子系统: mirai-core t:problem 类型: 不容易归类为特性或 bug 的综合问题 x:protocol 属性: 协议相关 and removed t:problem 类型: 不容易归类为特性或 bug 的综合问题 labels Apr 15, 2023
@Him188 Him188 added this to the Backlog milestone Apr 15, 2023
@For-Lin0601
Copy link

def allow(
self,
event: RequestEvent,
message: str = ''
):
"""允许申请。

    Args:
        event: 申请事件。
        message: 回复的信息。
    """
    asyncio.run(self.bot.allow(event, message))
    
    
    event事件类型为好友申请请求即可(NewFriendRequestEvent)。至于好友申请列表,找个变量记录呗,反正这玩意又不关机。监听器监听到的时候存进去,allow响应的时候删除。同样还有拒绝和拉黑,去找对应的就好

@StageGuard
Copy link
Member

找个时间做一下这个

@StageGuard StageGuard modified the milestones: Backlog, 2.16.0-RC Aug 29, 2023
@StageGuard StageGuard linked a pull request Aug 29, 2023 that will close this issue
@Him188 Him188 modified the milestones: 2.16.0-RC, 2.17.0-RC Sep 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
N 优先级: 一般 s:core 子系统: mirai-core t:feature 类型: 新特性 x:protocol 属性: 协议相关
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants