Back up your Postman Collections to GitLab, an open-source Git repository manager, with the Postman to GitLab integration.
Setting up a GitLab integration requires you to get a GitLab personal access token and configure how you would like to back up your collections.
For information about Postman's GitLab CI/CD integration, see Integrate Postman with GitLab CI/CD.
Before using Postman's GitLab integrations, you'll need to create a GitLab personal access token:
You can connect a GitLab repository to an API in the API Builder. Once connected, you can sync your API definition and associated collections between Postman and GitLab. You can switch branches, pull changes from the repository, and push changes to the repository, all from within Postman. To learn more about syncing your API with GitLab, see API version control overview.
Select Integrations on the Home page. Select Browse All Integrations, then select GitLab.
Select Add Integration for Backup a collection.
Enter your GitLab personal access token and select Authenticate and Proceed.
In the Configure interface, enter a nickname for the integration and select the workspace in which the collection you want to back up exists.
Select a Postman Collection, your GitLab project, and enter a filename for your backup.
In Enter Directory (optional), enter a custom directory name or leave "Postman Collections" as the default.
In Enter Branch (optional), specify a branch for commit. If you don't, the default branch of the repository will be used.
Select Add Integration to save your integration configuration.
Your collection is pushed to your GitLab project under the filename that you specified and saved as a single JSON file.
Postman often checks your collection for changes. If Postman identifies changes when it checks your collection, the changes automatically commit to your repository in JSON format. Your collections and code can exist in the same repository.
You can view your configured integrations on the Browse Integrations page. You can also view integrations that have been configured for a collection by opening the collection and selecting the
Info in the right sidebar. Learn more about viewing or editing integrations.
If your network is behind a firewall that requires allowlisting IP addresses, you'll need to use a static IP address to enable collection backups to GitLab on custom domains. Contact your IT team to allowlist the following static IP in your firewall to enable collection backups to GitLab:
* US East - `3.212.102.200`
After you allowlist this IP address, calls for this integration can connect to your network and enable the integration to work as expected.
To set up the integration, do the following:
Select Integrations on the Home page. Select Browse All Integrations, then select GitLab.
Select Add Integration for Backup a collection (custom domain).
Enter your GitLab personal access token, specify your GitLab custom/self-hosted domain, then select Authenticate and Proceed.
In the Configure interface, select an existing Postman Collection and your GitLab Project, then enter a filename for your backup.
In Enter Directory (optional), enter a custom directory name or leave "Postman Collections" as the default.
In Enter Branch (optional), specify a branch for commit. If you don't, the default branch of the repository will be used.
The branch you want to back up your collection to must already exist.
Select Add Integration.
Your collection is pushed to your GitLab project under the directory that you specified and saved as a single JSON file.
Postman often checks your collection for changes. If Postman identifies changes to your collection, the changes automatically commit to your repository in JSON format. Your collections and code can exist in the same repository.
You can go to your GitLab domain and inspect your backed-up collections.
Last modified: 2025/02/07