菜鸟教程小白 发表于 2022-12-12 14:58:45

ios - 提供的注册 token 未注册


                                            <p><p>我正在尝试通过 Google 云功能发送 iOS 推送通知,但它返回错误 <code>提供的注册 token 未注册</code>。但是我已经通过调试我的应用程序进行了检查,并且 FCM 注册 token 是正确的。之后,我尝试通过提供 FCMtoken 通过 Firebase 控制台向单个设备发送推送通知,但由于 <code>未注册的注册 token </code> 而失败。由于设备 FCMtoken 没有问题,这是怎么发生的?</p></p>
                                    <br><hr><h1><strong>Best Answer-推荐答案</ strong></h1><br>
                                            <p><p>我认为这应该是一些粗心的错误,你应该确保以下几点:</p>

<ol>
<li><p> token 与<code>-相同</code></p></li>
<li><p><code>GoogleService-Info.plist</code> 是 <a href="https://support.google.com/firebase/answer/7015592" rel="noreferrer noopener nofollow">downloaded</a>来自与您的 Firebase 推送控制台相同的帐户。</p></li>
<li><p>更新到最新的 Firebase SDK。</p></li>
</ol>

<p>来自 Google Firebase <a href="https://firebase.google.com/docs/cloud-messaging/admin/errors" rel="noreferrer noopener nofollow">document</a>是对您的错误的一些描述 <code>The provided registration token is not registered</code>。</p>

<blockquote>
<p>The provided registration token is not registered. A previously valid
registration token can be unregistered for a variety of reasons,
including:</p>

<ul>
<li>The client app unregistered itself from FCM.</li>
<li>The client app was automatically unregistered. This can happen if the user uninstalls the application or, on iOS, if the APNS Feedback
Service reported the APNS token as invalid.</li>
<li>The registration token expired. For example, Google might decide to refresh registration tokens or the APNS token may have expired for iOS
devices.</li>
<li>The client app was updated, but the new version is not configured to receive messages. For all these cases, remove this registration token
and stop using it to send messages.</li>
</ul>
</blockquote></p>
                                   
                                                <p style="font-size: 20px;">关于ios - 提供的注册 token 未注册,我们在Stack Overflow上找到一个类似的问题:
                                                        <a href="https://stackoverflow.com/questions/53009207/" rel="noreferrer noopener nofollow" style="color: red;">
                                                                https://stackoverflow.com/questions/53009207/
                                                        </a>
                                                </p>
                                       
页: [1]
查看完整版本: ios - 提供的注册 token 未注册