使用未发布的应用程序测试 Android 应用内购买

发布于 2025-01-07 05:06:46 字数 724 浏览 0 评论 0原文

我正在使用 AndroidBillingLibrary 为我的游戏实现应用内购买。

我已完成以下操作:

  • 将我的公钥从 Market 添加到我的应用程序
  • 将我签名且支持应用内购买的 apk 上传到市场(未发布)
  • 在市场控制台中创建应用内项目(未发布)
  • 添加测试用户帐户到我的个人资料

现在,我使用测试帐户开始游戏并尝试进行应用内购买。我进入市场屏幕,可以看到物品详细信息(因此市场确实可以识别物品 ID,因为这些详细信息仅在市场中,而不在我的游戏中),但随后我会收到一个弹出窗口,显示“您试图购买的物品”找不到购买。”我又回到了游戏中。

现在此页面告诉我“此外,测试帐户可以购买仅当该项目已发布时,才将其添加到您的产品列表中。”

但市场控制台告诉我:

“应用内产品将显示为未发布,直到所属应用程序发布为止,此时应用内产品的发布状态适用。”

因此,我无法在发布游戏之前将应用内项目更改为已发布(我还不想这样做)。

如何在不发布游戏的情况下测试购买应用内商品?

I'm using AndroidBillingLibrary to implement in-app purchases for my game.

I've done the following:

  • Added my public key from Market to my application
  • Uploaded my signed and in-app-purchasing-enabled apk to market (unpublished)
  • Created an in-app item in the market console (unpublished)
  • Added a test user account to my profile

Now with the test account I start my game and try to make a in-app purchase. I get the market screen and I can see the item details (so market does recognize the item id because those details are only in the market, not in my game) but then I get a pop up that says "The item you were attempting to purchase could not be found." and I'm returned to my game.

Now this page tells me that "Also, a test account can purchase an item in your product list only if the item is published. The application does not need to be published, but the item does need to be published."

but Market console tells me:

"An in-app product will appear UNPUBLISHED until the owning application is PUBLISHED, at which point the in-app product's publishing state applies."

So I can't change in-app items to published before publishing my game (which I don't want to do yet).

How can I test buying in-app items without publishing my game?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

世界如花海般美丽 2025-01-14 05:06:46

您需要在您的安全类中提供公钥(base64EncodedPublicKey),该密钥必须与您在开发者帐户中提供的相同。此外,即使应用程序尚未发布(保存为草稿应用程序),您也必须发布您的产品。 。

You need to give public key (base64EncodedPublicKey) in Your security class which must be same as you given in your developer account..Also you have to publish your product even if the app is not yet published(that is saved as draft application)..

何时共饮酒 2025-01-14 05:06:46

您需要使用签名的 apk。

  1. 使用您自己的生产密钥构建签名的 apk
  2. 将签名的 apk 上传到 Android Market 开发者控制台
  3. 将签名的 apk 上传到设备

然后从非开发人员帐户进行测试。

You need to use signed apk.

  1. Build signed apk with your own production keys
  2. Upload signed apk to Android Market Developer Console
  3. Upload signed apk to device

Then make your test from a non developer account.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文