iOS应用内购买:沙盒无效的产品ID [英] iOS In-App Purchases: Sandbox Invalid Product ID

查看:1774
本文介绍了iOS应用内购买:沙盒无效的产品ID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我遇到问题之前稍微奇怪的设置的背景:为客户端开发应用程序,我们使用的是另一个iTunes开发者帐户,而不是最终发布的用于开发和Ad-Hoc构建的帐户一个具有Game Center和IAP集成的应用程序。显然,我们最终必须在最终版本帐户上复制我们的设置,但问题似乎是无关的。

Background on the slightly odd setup before I get to the problem: Working on an app for a client and we're using an different iTunes developer account than the one this will eventually be published on for development and Ad-Hoc builds of an app that has Game Center and IAP integration. Obviously, we'll eventually have to duplicate our setup on the final release account, but the issue seems to be unrelated.

问题是尝试测试应用内购买在沙箱里。我们在临时账户中没有任何税/银行信息,它没有以我的名义设置,所以我不能只添加我的。现在,每次我们发送SKProductsRequest以及我在临时应用程序帐户的iTunes Connect部分中添加的产品的产品标识符时,它都会在响应中作为无效的产品标识符返回。

The issue is trying to test In-App Purchases in the sandbox. We do not have any Tax/Banking info in the interim account, it was not set up in my name so I can't just add mine. Right now, every time we send an SKProductsRequest with the Product Identifier for the product I've added in the iTunes Connect portion of the account for the interim app, it is returned in the response as an invalid product identifier.

此请求中标识符是一个包含我想要获取的字符串产品标识符的数组:

This request where identifiers is an array with the string product identifier I'm trying to get:

_productsRequest = [[SKProductsRequest alloc] initWithProductIdentifiers:[NSSet setWithArray:identifiers]];
_productsRequest.delegate = self;

这个委托方法:

- (void)productsRequest:(SKProductsRequest *)request didReceiveResponse:(SKProductsResponse *)response
{
   /*Other code for handling valid responses*/ 

    for (NSString *invalidProductId in response.invalidProductIdentifiers) {
        DLog(@"Invalid product id: %@" , invalidProductId);
    }
}

返回标识符的此日志:

 -[InAppPurchaseManager productsRequest:didReceiveResponse:] Invalid product id: [Product ID That matches the one in ITC exactly]

我知道ITC正在临时帐户中工作,因为我们所有的GameCenter沙箱集成都可以正常运行。

I know ITC is working in the interim account because all our GameCenter sandbox integration is working fine through that.

其他注意事项:


  • 模拟器和多个设备上的结果相同。

  • 在sim和所有设备上退出普通的iTunes / App商店帐户。

  • 尝试等待24小时再试一次。

  • 尝试添加不同的产品并尝试使用其标识符(尽管我没有等待24小时一)。

  • 看看这个:通过应用内购买解决无效的产品ID问题?并且遗憾的是没有看到任何非常有用的内容。

  • Same results on Simulator and multiple devices.
  • Logged out of normal iTunes/App store accounts on sim and all devices.
  • Tried waiting 24 hours and trying again.
  • Tried adding a different Product and trying its identifier (though I didn't wait 24 hours on this one).
  • Took a look at this: Resolving invalid product id issue with in-app purchases? and didn't see anything terribly helpful, unfortunately.

此时,我很难过。除了让设置此临时帐户的人员添加他们的税/银行信息之外,我还能做些什么才能从SKProductsRequest获得有效的产品?

At this point, I'm stumped. Other than getting the person who set up this interim account to add their tax/banking info, is there anything I can do to actually get a valid product back from the SKProductsRequest?

非常感谢任何帮助。谢谢!

Any help would be greatly appreciated. Thank you!

推荐答案

不得不把所有东西都搬到最终账户,这个账户确实有银行和税务信息。一旦我在其他帐户的应用程序中使用相同的名称设置IAP,完全相同的代码返回无效的产品ID就完全没了问题。

Wound up having to get everything moved over to the final account, which did have banking and tax info. Exact same code that returned invalid product IDs was totally fine once I set the IAP up with the same name in the other account's app.

所以,是的,您需要银行和税务信息甚至在沙箱中进行测试。嘘 - 瓮。

So yeah, you need the banking and tax info to even test in the sandbox. Boo-urns.

这篇关于iOS应用内购买:沙盒无效的产品ID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆