[GH-ISSUE #85] 能不能把参数改成,比如http://ip/token/参数/标题/内容 #60

Closed
opened 2026-03-03 11:55:45 +03:00 by kerem · 11 comments
Owner

Originally created by @jjss520 on GitHub (Sep 27, 2021).
Original GitHub issue: https://github.com/Finb/bark-server/issues/85

现在把参数放到最后面,很多推送的设置是直接这样http://ip/token/
想加参数的话http://ip/token/参数这样又和内容冲突

Originally created by @jjss520 on GitHub (Sep 27, 2021). Original GitHub issue: https://github.com/Finb/bark-server/issues/85 现在把参数放到最后面,很多推送的设置是直接这样http://ip/token/ 想加参数的话http://ip/token/参数这样又和内容冲突
kerem closed this issue 2026-03-03 11:55:45 +03:00
Author
Owner

@Finb commented on GitHub (Sep 27, 2021):

参数怎么会和内容冲突呀?
使用标准URL格式传递参数即可

<!-- gh-comment-id:927475876 --> @Finb commented on GitHub (Sep 27, 2021): 参数怎么会和内容冲突呀? 使用标准URL格式传递参数即可
Author
Owner
<!-- gh-comment-id:927482914 --> @jjss520 commented on GitHub (Sep 27, 2021): 大佬,比如V2P的推送,他只需要一个http://ip/token/,如果我要加个分组http://ip/token/?group=groupName,这样,他的推送内容就是http://ip/token/?group=groupNam内容
Author
Owner

@Finb commented on GitHub (Sep 27, 2021):

只需将 “?group=groupNam内容” URL编码一下即可
最后是 http://ip/token/%3Fgroup%3DgroupNam%E5%86%85%E5%AE%B9

<!-- gh-comment-id:927483467 --> @Finb commented on GitHub (Sep 27, 2021): 只需将 “?group=groupNam内容” URL编码一下即可 最后是 http://ip/token/%3Fgroup%3DgroupNam%E5%86%85%E5%AE%B9
Author
Owner

@jjss520 commented on GitHub (Sep 27, 2021):

只需将 “?group=groupNam内容” URL编码一下即可
最后是 http://ip/token/%3Fgroup%3DgroupNam%E5%86%85%E5%AE%B9

哦哦,原来要URL编码呀,好的,我马上试试

<!-- gh-comment-id:927483789 --> @jjss520 commented on GitHub (Sep 27, 2021): > 只需将 “?group=groupNam内容” URL编码一下即可 > 最后是 http://ip/token/%3Fgroup%3DgroupNam%E5%86%85%E5%AE%B9 哦哦,原来要URL编码呀,好的,我马上试试
Author
Owner

@jjss520 commented on GitHub (Sep 28, 2021):

大佬,再问一下,post下,比如分组声音这样应该怎么弄
{"title": 【$title$】,"body": $body$,"group":"elecV2P"}
我这样不行,标题和内容都可以

<!-- gh-comment-id:928750751 --> @jjss520 commented on GitHub (Sep 28, 2021): 大佬,再问一下,post下,比如分组声音这样应该怎么弄 {"title": `【$title$】`,"body": `$body$`,"group":"elecV2P"} 我这样不行,标题和内容都可以
Author
Owner

@Finb commented on GitHub (Sep 28, 2021):

@jjss520
参数应该放到

{"title": 【$title$】,"body": $body$, "ext_params": {"group":"elecV2P"}}
<!-- gh-comment-id:928753309 --> @Finb commented on GitHub (Sep 28, 2021): @jjss520 参数应该放到 ``` {"title": 【$title$】,"body": $body$, "ext_params": {"group":"elecV2P"}} ```
Author
Owner

@jjss520 commented on GitHub (Sep 28, 2021):

@jjss520
参数应该放到

{"title": 【$title$】,"body": $body$, "ext_params": {"group":"elecV2P"}}

谢谢,可以了

<!-- gh-comment-id:928895236 --> @jjss520 commented on GitHub (Sep 28, 2021): > @jjss520 > 参数应该放到 > > ``` > {"title": 【$title$】,"body": $body$, "ext_params": {"group":"elecV2P"}} > ``` 谢谢,可以了
Author
Owner

@jjss520 commented on GitHub (Sep 28, 2021):

推送自定义图标怎么没成功呢,服务端和客户端今天才更新的
https://11111/0000000000/自定义推送图标?icon=https://day.app/assets/images/avatar.jpg
直接这样测试的

<!-- gh-comment-id:928943312 --> @jjss520 commented on GitHub (Sep 28, 2021): 推送自定义图标怎么没成功呢,服务端和客户端今天才更新的 https://11111/0000000000/自定义推送图标?icon=https://day.app/assets/images/avatar.jpg 直接这样测试的
Author
Owner

@Finb commented on GitHub (Sep 29, 2021):

软件里忘了写,这个特性需要iOS15

<!-- gh-comment-id:929777261 --> @Finb commented on GitHub (Sep 29, 2021): 软件里忘了写,这个特性需要iOS15
Author
Owner

@jjss520 commented on GitHub (Sep 29, 2021):

软件里忘了写,这个特性需要iOS15

难怪搞了半天不行

<!-- gh-comment-id:929777588 --> @jjss520 commented on GitHub (Sep 29, 2021): > 软件里忘了写,这个特性需要iOS15 难怪搞了半天不行
Author
Owner

@jjss520 commented on GitHub (Sep 30, 2021):

大佬,分段发送刻不容缓呀
HTTPError: Response code 431 (Request Header Fields Too Large)
好多推送都因为太长了失败

<!-- gh-comment-id:930706505 --> @jjss520 commented on GitHub (Sep 30, 2021): 大佬,分段发送刻不容缓呀 HTTPError: Response code 431 (Request Header Fields Too Large) 好多推送都因为太长了失败
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/bark-server#60
No description provided.