Ship to the App Store

Give an Agent a CSV file of testers, and it adds them all to your TestFlight groups in one run, invites them if you ask, and can write your current testers into a file.

Invite Tester… in a TestFlight group adds one person at a time (see Invite testers in Share a beta with TestFlight). For a list of people, give an Agent a CSV file instead: it adds every row in one run and tells you what it did. It can also write the testers you have into a CSV file.

Before you start

  • The groups exist. To make one, tap Invite Testers on the TestFlight tab: see Invite testers in Share a beta with TestFlight.
  • Use external groups. Internal testers are App Store Connect team members, added in App Store Connect: see Internal and external testing in Share a beta with TestFlight.

Make the file

A CSV file with one tester per row, under a header row:

testers.csv
email,first_name,last_name,groups
tester1@example.com,Alex,Example,Friends
tester2@example.com,,,Friends;Early Access
Column Required What it holds
email Yes The tester’s email address. Each address only once in the file.
first_name No The tester’s first name.
last_name No The tester’s last name.
groups No The groups to add the tester to, by name or group ID. Separate several with semicolons.
  • The columns can be in any order, in upper or lower case, and first and last work too. Other columns are refused.
  • A file made for fastlane works as it is: with the header First,Last,Email,Groups, or with no header and the columns in that order.
  • Instead of a groups column, you can name one group for the whole file in your message. If the file has groups too, each tester gets both.
  • From a spreadsheet, save or export the sheet as CSV.

Attach the file to your message (see Send photos, files and sketches to an Agent).

Check the file first

Ask in the Project’s chat, for example:

Add the testers in the attached testers.csv to the Friends group. Do a dry run first, and don't send invitations yet.
  1. The Agent runs asc testflight testers import --dry-run. It reads the file and your app’s groups and testers in App Store Connect, and changes nothing.
  2. It tells you what would happen: how many rows there are, how many testers would be created, how many already exist, how many existing testers would be added to groups, and how many rows fail. Each failure comes with its row number, email and error.
  3. Fix the file if you need to, and send it again.
  4. Say yes. The import runs only with --confirm, so the Agent asks you first.

What the import does

A row whose email What happens
Isn’t a tester of your app yet The tester is created with the name and groups from the row (counted as created).
Is already a tester of your app The tester isn’t created again: they’re added to the row’s groups (counted as updated). Their name isn’t changed. A row without groups leaves them as they are. To leave every existing tester alone, ask the Agent to skip them (--skip-existing).
Is empty The row fails: “email is required”.
Isn’t an email address The row fails: “invalid email format”.
Is in the file twice The later row fails: “duplicate email in input (already seen at row” and the first row’s number.

Emails match whatever their upper or lower case. A failed row doesn’t stop the others. At the end the result counts the rows, the testers created, those that already existed, existing testers added to groups, those invited and the rows that failed, and lists each failure. Fix those rows and import the file again: testers already created count as existing, not twice.

Invitations

The import invites no one unless you ask. Say so in your message, for example “…and send them invitations.” The Agent then adds --invite, and each tester it creates gets an invitation. Testers who already existed aren’t invited again. If a row failed while sending its invitation, the tester was still created. Importing the file again won’t invite them, so use Resend Invitation or ask the Agent.

The asc help doesn’t say whether Apple emails a tester who is added to a group without --invite. To see where each tester stands, open the group from Testers on the TestFlight tab: each row shows a state such as Not Invited, Invited or Accepted. To invite one later, use Resend Invitation in the row’s ⋯ (see Manage a group in Share a beta with TestFlight), or ask the Agent.

An invitation that has gone out can’t be called back. A tester you added by mistake can be taken out of the group with Remove from Group.

Export your testers to a file

Ask, for example:

Export all the testers of the app, with their groups, to a CSV file and send it to me.

The Agent runs asc testflight testers export and writes the file into the project. Ask it to send the file in the chat (see Find the files and documents Agents made). The file has every tester’s email address, so share it with care.

  • The columns are email, first_name and last_name, sorted by email. With groups (--include-groups), a groups column lists each tester’s groups, separated by semicolons: by name, or by group ID when two groups share a name.
  • You can ask for one group, one build, or a tester’s email, first name or last name (an exact match). One group and one build can’t be asked for together: “–group cannot be combined with –build-id”.
  • asc doesn’t write over a file: it stops with “output file already exists”. Ask for another file name.
  • A cell that starts with =, +, - or @ gets a single quote in front, so a spreadsheet app reads it as text, and the file gets an _asc_formula_escaping column. Keep that column if you’ll import the file again: the import takes off only the quotes the export added.

The export is in the import’s format, so you can change it and import it again, for example into another group.

If something goes wrong

The Agent says a group was not found.
The message is “beta group … not found”. Use the group’s name as it’s listed under Testers on the TestFlight tab. Upper and lower case don’t matter.
Two groups have the same name.
asc can’t tell which one you mean, and says “Use one of these group IDs in the CSV groups column instead of the name.” Ask the Agent to put the right group’s ID in the file, or rename one of the groups.
The Agent says the file has an unknown column.
The message is “unknown CSV column” and the column’s name. The header can only have email, first_name, last_name and groups (and the export’s _asc_formula_escaping). Remove or rename the other columns.
The header has no email column.
The message is “CSV header must include required column “email”“. Add an email column.
The rows must have 3 or 4 columns.
The message starts “legacy CSV rows must have 3 or 4 columns”. The file has no header, so asc reads it as first name, last name, email and groups. Add a header row, such as email,first_name,last_name,groups.
CSV file is empty.
The file has nothing in it. Check that you attached the right file.
Testers joined but can't install anything.
The group needs a build, and the first build of a version in an external group usually needs Apple’s beta review first. See Send a build to external testers in Share a beta with TestFlight.