iTunes connect: confused on Bundle ID

20,999

Solution 1

Before answering your questions some definitions:

Bundle ID: A reverse DNS string that precisely identifies a single app.

Bundle ID search string: it is used to match a set of bundle IDs, where each bundle ID identifies a single app. For example, if the bundle ID search string is com.mycompany.MyApp or a wildcard such as com.mycompany.*, then it will match the bundle ID com.mycompany.MyApp.

App ID: A string that identifies one or more apps from a single team. An App ID consists of a bundle ID search string preceded by the Team ID, a 10-character string generated by Apple to uniquely identify a team. In the technical note that you link it is ABCDE12345 and called the Bundle Seed ID.

(Development) Provisioning Profile: you use it to authorize your app to launch on devices and use certain store technologies when you are in development. It is comprised of: a single App ID, a set of devices, and a set of development certificates. The provisioning profiles are created in Member Center and you need them on your device to run your app. XCode can download provisioning profiles and install them onto devices.

Now I will answer to your bullets:

  • To use Game-Center (GameKit) and IAP you need an explicit App ID, that is and App ID with a bundle ID search string that has no *. A wild-card App ID is one in which the bundle ID search string that has a *, and is the one you have now.
  • What you create initially is an App ID with an associated Bundle ID. If it is explicit you can add Game-Center and IAP, if it is a wildcard App ID not... that's it.
  • You can not have two apps with different names but the same explicit App ID or Bundle ID. But you can have two apps with different names that do not use Game-Center or IAP with a unique App ID using a wildcard App ID.
  • You ask why the wildcard is useful... Well, I said that if you do not use Game-Center or IAP you can have two or more apps associated to an wildcard App ID. Then you can create a provisioning profile with this App ID and you only need to install this provisioning profile on your devices for all your apps. There is a default provisioning profile of this type called the Team Provisioning Profile which is valid for all your apps, but you could create more specific ones that are valid for a subset of all you apps.

This process is really useful for big teams. If you have a small team and few apps it is really confusing, but it helps to understand the reasoning behind it.

But there is more to say about all this. I recommend that you read the "App Distribution Guide" as I did recently. It is an extensive guide, but for the moment you only need to read sections of topic "Maintaining Your Signing Identities and Certificates" and "Maintaining Identifiers, Devices, and Profiles". The guide is very clear, full of screenshots and it will answer all your questions. Also you can go back to the guide down the road to quickly solve some issue (and you will have issues).

The first time that I created an App with Game-Center and IAP more than a year ago I looked up stackoverflow to answer all my questions. But I've been having issues when certificates expired, when I added new devices, etc, and every time I found and Ad-hoc solution after a lot of fiddling around and going back to stackoverflow. Don't get me wrong, there are great answers in stackoverflow but it is a much better strategy in my experience to read something longer that explains the big picture. App ID, Bundle ID's, Certificates, private keys, etc, is a messy subject, specially if you do not understand why it is built this way.

Solution 2

The bundle id is just an identifier for your app. It's mainly used to provide you with the certificates you need to use to sign your app before submitting to the App Store or to use it on development devices (e.g. for testing). The bundle id can be whatever you want. Apple recommends using the syntax com.yourcompany.yourapp to keep it consistent among apps you develop and avoid conflicts with other app's identifiers.

A wildcard can be used on all your apps, while a specific id can be used with one app only. I advice you to have an id for each of your app and only a wildcard for development (so you can run on your devices as many apps as you want without having to bother about the certificates until you decide to ship the app). You don't need to have access to all services (like Game Center or iCloud) on all your apps and therefore you better sign the single certificates just with the services your app needs.

Solution 3

What I think Apple wants is:

  1. Create a different bundle ID for each app that uses in-App purchase/GameKit or both.

  2. You can have same App-ID, and bundle ID for apps that do not use these.

  3. If the bundleID you have for your app is not used for any other of your apps, you can use it.

Somebody more knowledgable, Please correct me if I am wrong.

Share:
20,999
mm24
Author by

mm24

switch(job): case MORNING: print."write code, research new technology, collaborate"; case NOON: print."write code, research new technology, collaborate"; case AFTERNOON: print."write code, research new technology, collaborate"; case EVENING: print.evaluate(time); case OTHER: print.evaluate(time); switch(contact-me): case STACKOVERFLOW: print."comment @mm24";

Updated on August 23, 2020

Comments

  • mm24
    mm24 over 3 years

    I have been excited to try to add for the FIRST time a new App on iTunes Connect to TEST my GAMEKIT features.

    I have read this technical note and I am getting confused because I had already a boundle id for my App that I created when I started developing it (that's my current bundle id with which I created the current provisioning and testing profiles: hello-*).

    enter image description here

    In order to use GameKit and InApp Purchase should I create a new Bundle Id?

    I am confused because:

    • I don't know if the current Bundle Id is valid (in respect to the technical note linked above)
    • I don't know if hte Bundle Id influences the things that I can ADD in the App later (E.g. in App Purchase, GameKit, ...)
    • If I create a new App with a name (say: HelloApple) but with a bundle Id with wildcard (Say: hello-*) will I be able to add a new App with the same name but a different bundle Id in a later stage? This indeed before publishing ANY of the two Apps.
    • I don't fully understand why there is a choice between using or not using a wildcard; in other words, if a non wildcard bundle id is needed to use in App purchase and GameKit why should a developer want to use a wildcard App Id?

    Any help will be appreciated, in particular I need to solve my first issue: which bundle Id should I use in ordert to use GameKit and InAppPurchase?

  • mm24
    mm24 almost 11 years
    Hi Gianluca, thank you for your answer. I have already a wildcard id that I used so far to test "TestApps". However now I am in the stage where I need to test also GameKit features for a specific App. In this case then will I need to rebuild all my provisioning profiles for that app (development profile and distribution)?
  • Gianluca Tranchedone
    Gianluca Tranchedone almost 11 years
    Yes, when you add a feature that requires your certificates data like Game Center and iCloud, you need to remake the provisioning profile for that app. Luckily, if you have Xcode 5 (in Developer Preview at the moment), Xcode does it for you.
  • mm24
    mm24 almost 11 years
    Hi Gianluca, I would like to accept the answer but I have one last doubt. I have created my boundle id and then went to create my new App on iTunes connect. It already asks me to provide screenshots and choose the price tier. All I want to do is to test the App for GameCenter. How should I do that? I mean, should I already provide all those information to Apple in order to solely test the app for GameCenter?
  • Gianluca Tranchedone
    Gianluca Tranchedone almost 11 years
    Unfortunately, yes, you have to do it. But you can edit most of this infos later on, before submitting your app. The only things that you cannot change, if I remember correctly, are the SKU (useless, so don't worry about it), the bundle id and the app name (but I'm not 100% sure about this one).
  • mm24
    mm24 almost 11 years
    Cool.. the thing that I don't fully understand is how Apple can ask to submit already an App Icon to developers even if the game is not finished yet. I would have expected them to ask this only once the binary where uploaded. I suppose is possible to change also those in a second instance..
  • Gianluca Tranchedone
    Gianluca Tranchedone almost 11 years
    Yes, you can change the icon and the screenshots later.
  • mm24
    mm24 almost 11 years
    Thanks Robotillo, I accepted your answer as it was more complete.
  • Abhinav Singh
    Abhinav Singh about 8 years
    "why it is built this way", answer changes your perception