功能:把Android接收的验证码自动转发到Bark,并在iOS端自动复制。如果发送失败会以短信作为备选方式重试
本系列帖子导航
- 快捷指令复刻版Pushbullet
- 基于AutoHotkey的Bark推送端
- 基于Tasker的Bark推送端
- Tasker转发验证码到Bark 本帖
1. 获取Push URL
iOS或者Android安装Bark,在App的主界面,可以看到形如 https://api.day.app/xxxxxxxxxx/
的Push URL,记录下来
2. 配置Tasker Profile
点我导入或者按下面的描述手动创建profile
Profile: 验证码转发
Restore: no
Event: Received Text [ Type:SMS Sender:* Content:* SIM Card:* ]
Enter: Anon
A1: If [ %SMSRB ~R (验证|校验|安全|authentication|security)(码|code) | %SMSRB ~R (密码|password) ]
A2: Variable Search Replace [ Variable:%SMSRB Search:\d{4,8} Ignore Case:Off Multi-Line:Off One Match Only:On Store Matches In Array:%CODE Replace Matches:Off Replace With: ]
<https://api.day.app/xxxxxxxxxxxxxxxx/改成你自己的Push URL>
A3: HTTP Request [ Method:HEAD URL:https://api.day.app/xxxxxxxxxxxxxxxx/%SMSRB?copy=%CODE1&automaticallycopy=1&isArchive=1 Headers: Query Parameters: Body: File To Send: File/Directory To Save With Output: Timeout (Seconds):10 Trust Any Certificate:Off Automatically Follow Redirects:Off Use Cookies:Off Continue Task After Error:On ]
<宕机时以短信转发作为备选>
A4: [X] Send SMS [ Number:xxxxxxxxxxx Message:%SMSRB Store In Messaging App:Off SIM Card: Wait For Result:Off ] If [ %http_response_code !~ 200 ]
A5: End If
导入完成后记得配置Bark的Push URL和接收转发的手机号码