# CSV team import

You can create and update Swarmia teams and memberships in bulk using a CSV file. This is especially useful if you're new to Swarmia and haven't configured your teams yet, or if you already maintain team memberships in a spreadsheet.

### Who is this for?

CSV import is a good fit for organizations that:

* Don't yet have Swarmia teams configured
* Don't have up-to-date GitHub teams or another data source that can be synced via the team API
* Already maintain team memberships in a spreadsheet or can easily export teams as a CSV

### How to get started

Navigate to [Settings → Teams & members](https://app.swarmia.com/settings/teams), click **Create teams**, and select **Create or edit teams with CSV**.

***

### Initial import

Use this flow when setting up teams in Swarmia for the first time.

1. Download the CSV template from Swarmia
2. Fill in your team details
   * teamKey
   * teamName
   * parentTeamKey (optional)
   * memberEmail
   * memberName
3. Upload the CSV to Swarmia
4. Review the proposed changes and confirm

You can create empty teams, for example, parents, by leaving the memberEmail and memberName columns empty. The UI highlights any errors with instructions on how to fix.

<figure><img src="/files/xkSiBh97sePv1zjtE1wE" alt=""><figcaption><p>Example of the initial import file.</p></figcaption></figure>

***

### Updating existing teams

Use this flow to add members, rename teams, or adjust the hierarchy for teams already in Swarmia.

1. Export your current teams and memberships as a CSV from Swarmia
2. Edit the file — add or update teams and remove memberships as needed
3. Upload the updated CSV to Swarmia
4. Review the proposed changes and confirm

You can remove members from teams by typing `TRUE` in the remove column. Teams cannot be removed via the import, but you can do it in the UI.

If you export teams that were created with another method, the teamKey and parentTeamKey columns show the existing Swarmia team ID.

The updates apply only to teams included in the file. Any other existing teams won't be affected by the import.

<figure><img src="/files/3pCuyo5ILm78wMlM9LyP" alt=""><figcaption><p>Example of updating existing teams. Type <code>TRUE</code> in the remove column to remove members from a team.</p></figcaption></figure>

***

### GitHub teams

The CSV import supports two additional columns — githubTeamId and githubTeamName — for assigning/removing GitHub teams as team members. The export automatically includes these columns when any team currently has a GitHub team member.

***

After a CSV import, you can continue making changes to your teams directly in the Swarmia UI.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.swarmia.com/settings/organization/managing-teams/csv-team-import.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
