# 推送通知是否使用第三方中介？

**URL:** <https://meta.discourse.org/t/do-push-notifications-use-3rd-party-brokers/178004>\
**Category:** Product Support\
**Created:** [2021 年2 月 1 日 17:00 UTC](https://meta.discourse.org/t/do-push-notifications-use-3rd-party-brokers/178004 "2021-02-01T17:00:53Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

作者： ![mentalstring](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mentalstring/32/168934_2.png) [@mentalstring](https://meta.discourse.org/u/mentalstring)\
发布日期： [2021 年3 月 25 日 12:14 UTC](https://meta.discourse.org/t/do-push-notifications-use-3rd-party-brokers/178004/3 "2021-03-25T12:14:37Z")

</div>

抱歉再次提起这个话题，但我的搜索将我引到了这里，我不确定这是否相关。

我们的 `/logs` 中充满了以下信息：

`Failed to send push notification : host: fcm.googleapis.com, #<Net::HTTPForbidden 403 Forbidden readbody=true> body: the key in the authorization header does not correspond to the sender ID used to subscribe this user. Please ensure you are using the correct sender ID and server Key from the Firebase console.`

> **Backtrace**
>
> ```plaintext
> webpush-1.1.0/lib/webpush/request.rb:175:in `verify_response'
> 
> webpush-1.1.0/lib/webpush/request.rb:34:in `perform'
> 
> webpush-1.1.0/lib/webpush.rb:44:in `payload_send'
> 
> /var/www/discourse/app/services/push_notification_pusher.rb:79:in `send_notification'
> 
> /var/www/discourse/app/services/push_notification_pusher.rb:25:in `block in push'
> 
> activerecord-6.0.3.3/lib/active_record/relation/delegation.rb:87:in `each'
> 
> activerecord-6.0.3.3/lib/active_record/relation/delegation.rb:87:in `each'
> 
> /var/www/discourse/app/services/push_notification_pusher.rb:23:in `push'
> 
> /var/www/discourse/app/jobs/regular/send_push_notification.rb:7:in `execute'
> 
> /var/www/discourse/app/jobs/base.rb:232:in `block (2 levels) in perform'
> 
> rails_multisite-2.5.0/lib/rails_multisite/connection_management.rb:76:in `with_connection'
> 
> /var/www/discourse/app/jobs/base.rb:221:in `block in perform'
> 
> /var/www/discourse/app/jobs/base.rb:217:in `each'
> 
> /var/www/discourse/app/jobs/base.rb:217:in `perform'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:196:in `execute_job'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:164:in `block (2 levels) in process'
> 
> sidekiq-6.1.2/lib/sidekiq/middleware/chain.rb:138:in `block in invoke'
> 
> /var/www/discourse/lib/sidekiq/pausable.rb:138:in `call'
> 
> sidekiq-6.1.2/lib/sidekiq/middleware/chain.rb:140:in `block in invoke'
> 
> sidekiq-6.1.2/lib/sidekiq/middleware/chain.rb:143:in `invoke'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:163:in `block in process'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:136:in `block (6 levels) in dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq/job_retry.rb:111:in `local'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:135:in `block (5 levels) in dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq.rb:38:in `block in <module:Sidekiq>'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:131:in `block (4 levels) in dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:257:in `stats'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:126:in `block (3 levels) in dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq/job_logger.rb:13:in `call'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:125:in `block (2 levels) in dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq/job_retry.rb:78:in `global'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:124:in `block in dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq/logger.rb:10:in `with'
> 
> sidekiq-6.1.2/lib/sidekiq/job_logger.rb:33:in `prepare'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:123:in `dispatch'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:162:in `process'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:78:in `process_one'
> 
> sidekiq-6.1.2/lib/sidekiq/processor.rb:68:in `run'
> 
> sidekiq-6.1.2/lib/sidekiq/util.rb:15:in `watchdog'
> 
> sidekiq-6.1.2/lib/sidekiq/util.rb:24:in `block in safe_thread'
> 
> ```

我们看到了成千上万条这样的错误。这……正常吗？

---

_[View the full topic](https://meta.discourse.org/t/do-push-notifications-use-3rd-party-brokers/178004)._
