iMessages App Capability Issue with In-App Purchase

**The issue - **

I can't add "In-App Purchase" as a capability in xCode to my iMessage extension target.

**What I have tried - **

I have a valid provisioning profile with In-App Purchases enabled.

I have agreed to all agreements in the apple developer console.

I have an apple developer membership.

I have added an active bank account to my apple developer account.

**How the issue came to be - **

I am trying to develop a "stand-alone" iMessage app (no underlying app) which as I understand it is different from a "iMessage extension app"(this has an underlying app that it syncs/interacts with). To do this, I updated my mac to latest OS (Tahoe 26.2) and xCode as well. I then began by using the "iMessage App" template in xCode. And BAM right off the bat, I could not get the "In-App Purchases" capability to show up when I select my iMessage extension target. To be clear, when you make the template, you get 2 targets, one is just a regular "app" target and the other is the iMessage extension target. Now I am not sure if I even need the "app" target if I'm trying for a standalone iMessage app, but I figured it wouldn't be causing this issue as I have tried deleting that target and nothing changed.

**Replicating the issue - **

I have tried creating other "iMessage App"'s off of the template to see if maybe I just got it wrong or misconfigured something in my development, but it seems like when you start one of those templates, you immediately are not able to see the "In-App Purchase" capability.

**Help! - **

I know this to be possible as there is another (very popular) iMessage extension out on the app store right now called "Game Pigeon" which is also provided by an individual just like I am trying to do, and he uses In App Purchases in his iMessage app.

Any help on this would be GREATLY appreciated.

Please reach out to me if you need/want additional info or could/want to schedule a meeting.

Accepted Answer

Fixed this.

In my main "App" target from the template, it defaults to -

productType = "com.apple.producttype.application.messages";

in the project.pbxproj file.

It needed to be -

productType = "com.apple.product-type.application";

@AET720

I then began by using the "iMessage App" template in xCode. And BAM right off the bat, I could not get the "In-App Purchases" capability to show up when I select my iMessage extension target.

When you add the In-App Purchase capability to a target in Xcode, it adds the com.apple.developer.storekit entitlement string. This entitlement isn't a supported entitlement as explained in Determining if an entitlement is real. For a list of entitlements Apple supports, see Capabilities overview > Supported capabilities.

if you added the In-App Purchase capability to your app target in Xcode, remove it. It is unnecessary. This capability is already enabled when you use an explicit App ID. If your iMessage extension uses an App ID, In-App Purchase is already enabled.

Ok thank you. So do I need to embed my iMessage extension inside the imessage app container? And I don't have to have the in app purchase capability to make in app purchases work?

Ok thank you. And I don't have to have the in app purchase capability to make in app purchases work?

If you use the iMessage App template to create the app and extension, there is nothing to do. The template doesn't allow you to add the In-App Purchase capability to both the app and capability.

If you use another Xcode template that allows you to create your app and add the In-App Purchase capability, remove the capability if you added it.

So do I need to embed my iMessage extension inside the imessage app container?

If you use the iMessage App template, the extension is automatically embedded into the containing app.

If you use the iMessage extension template to create the extension, Xcode automatically adds it to the app selected in the Embed in Application field.

iMessages App Capability Issue with In-App Purchase
 
 
Q