Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8344305
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T06:19:33+00:00 2026-06-09T06:19:33+00:00

I am building an iOS app and trying to implement an in app purchase

  • 0

I am building an iOS app and trying to implement an in app purchase (non-consumable).

All the bundle IDs etc. are set up and working, and I can see my product as valid when I fetch the Apple Store servers. However, while testing, I am getting failed transactions at the paymentQueue callback.

Here is what happens in the iOS simulator step by step:

  1. A message box asks “would you like to buy .. for $0.99?” which is correct
  2. I click Yes.
  3. After about a second it says that I’ve already bought it (correct, I test-bought it initially while debugging). I click OK.
  4. It complains about a login requirement (it says something like MZFinance_LoginRequired, I think its a missing string identifier.) I click OK.
  5. App Store login box pops up and I enter my test account credentials.
  6. My breakpoint in Xcode is hit, with the transaction state SKPaymentTransactionStateFailed.

Here is the relevant part of my code:

-(void)productsRequest:(SKProductsRequest *)request didReceiveResponse:(SKProductsResponse *)response{
NSArray* arr = response.products;
for (int i = 0; i < arr.count; i++) {
    SKProduct* product = [arr objectAtIndex:i];
    if([product.productIdentifier isEqualToString:@"<<my in app purchase id which is correct and working>>"]){
        SKPayment *payment = [SKPayment paymentWithProduct:product];
        [[SKPaymentQueue defaultQueue] addTransactionObserver:self];
        [[SKPaymentQueue defaultQueue] addPayment:payment];
    }
}

-(void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray *)transactions{
for (SKPaymentTransaction* ta in transactions) {
    switch (ta.transactionState) {
        case SKPaymentTransactionStatePurchased:
        case SKPaymentTransactionStateRestored:
            receipt = [ta transactionReceipt];
            [self performSelectorInBackground:@selector(validateFromServer) withObject:nil];
            break;
        case SKPaymentTransactionStateFailed:
            [self purchaseFailed];
            break;
    }

    if(!ta.transactionState == SKPaymentTransactionStatePurchasing){
        [[SKPaymentQueue defaultQueue] finishTransaction:ta];

    }
}

}
}

[self purchaseFailed] always gets hit, which just notifies the user. What can be wrong here? (I am new to iOS and -obviously- iOS in app purchases).
Thanks.

UPDATE: My test account credentials are correct, as I am getting a different (invalid login) message if I type it wrong.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T06:19:34+00:00Added an answer on June 9, 2026 at 6:19 am

    After some time struggling with it, I’ve noticed that I’m not encountering any problems in production. It was probably a problem with the sandbox servers.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm building an iOS app and I have all the functionality going already so
Can anyone help me? I can't fix this error when building an ios app
I have an iOS app working and am trying to clean up some of
I am building a ios app for ipad, in which the user will be
Hey so I'm building an iOS app. The fist window is a login screen
When we are building html5 web app or ios hybrid app,we need to make
I am building a photo sharing app for iOS 5 and I'd like to
I am building an assistive iOS app for a kid that uses a switch
We are building a PhoneGap app (both for iOS and Android) that has a
I'm currently building a web app, which is built with Xcode 3.2.5 and iOS

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.