The short answer
In App Store Connect, open Users and Access › Integrations › App Store Connect API, choose Team Keys and click Generate API Key. Give it a name, pick a role (Sales or Finance to read sales reports, Admin to change settings too), and download the .p8 file straight away, because Apple only lets you download it once. You’ll also need the Issuer ID above the list of keys and the Key ID next to your key.
An App Store Connect API key is a private key that lets an app or script read and change your App Store Connect account without your password. Apple calls the kind shared by your whole team a Team Key. You need one to download sales reports automatically, to use tools like fastlane, or to connect a revenue app like Tivro.
It takes about two minutes. Here’s how.
Before you start
The first time anyone on your team uses the API, the Account Holder has to request access. In App Store Connect, they open Users and Access › Integrations, click Request Access, agree to the terms and submit. After that, anyone with the Admin role can create Team Keys.
If you can already see a Team Keys tab under Integrations, you can skip this.
Generate the Team Key
- Sign in to App Store Connect and open Users and Access.
- Click the Integrations tab. App Store Connect API is selected on the left.
- Click Team Keys.
- Click Generate API Key, or the + button if you already have one.
- Enter a name you’ll recognise later, like the app or tool it’s for. The name is only for you.
- Under Access, choose a role (more on that below).
- Click Generate.
The key appears in the list, with a Download API Key link next to it.
Download the .p8 file, once
Click Download API Key. Your browser saves a file called something like AuthKey_ABC123DEFG.p8. That file is the private half of the key.
Treat it like a password: don’t email it, don’t commit it to a code repository, and only paste it into tools you trust.
Find your Issuer ID, Key ID and vendor number
Most tools ask for three or four values alongside the file:
| Value | Where to find it | Looks like |
|---|---|---|
| Issuer ID | Above the list of Team Keys | A long ID with dashes |
| Key ID | Next to your key in the list, and in the file name | 10 letters and numbers |
| Private key | The .p8 file you downloaded | A short text file |
| Vendor number | Reports (Payments and Financial Reports), top left under your legal entity name | 8 digits |
The vendor number is only needed for sales and financial reports, which is exactly what a revenue app reads.
Which role to choose
A Team Key can see every app in your account, whatever its role; the role decides what it can do. Apple’s roles for keys are the same ones your team members have. For revenue, three matter:
- Sales can read sales, downloads and analytics. The safest choice for a tool that only reads sales reports.
- Finance can read Sales and Trends, Payments and Financial Reports, and App Analytics.
- Admin can do nearly everything, including changing an app’s settings. Choose it only for tools that need to change something, and that you trust.
Using the key with Tivro
Tivro reads your apps and their sales with a Team Key, and turns every sale into a notification on your iPhone and Apple Watch:
- In Tivro, tap Add a business › App Store.
- Add the Issuer ID, the Key ID, the .p8 file and the vendor number.
- Pick your apps. Each one becomes a business, with its own icon.
With an Admin key, Tivro can also turn on instant sales by pointing your apps’ App Store Server Notifications at itself, and only when nothing else receives them. With Sales or Finance, Tivro shows you a link to paste into each app’s App Information instead. Either way, sales arrive within seconds. More on the App Store page.
Team Key or individual key?
Every App Store Connect user can also make one individual API key, from their profile. It has the same access as that user, but Apple’s documentation says individual keys can’t access Sales and Finance, provisioning or notaryTool. For anything that reads sales, use a Team Key.
Revoking a key
If a key leaks, or you stop using a tool, revoke it: Users and Access › Integrations › App Store Connect API › Team Keys, then Revoke next to the key. Anything using it stops working immediately, and a revoked key can’t be brought back. Generate a new one for the tools you still use.