For an overview of resource sharing and user roles, click here.
Resources within SwaggerHub can be shared with other people.
-
If a resource is private, it is accessible only to the organization owner(s) and members of the organization.
-
If a resource is public, anyone can view it, but only the organization owner and designers can change it.
The number of members that can be added to SwaggerHub depends on the SwaggerHub plan. Click here to explore adding users.
Roles
A user (organization member) can be assigned the following roles:
- Designer
- Consumer
- Owner - a designer with system administration privileges
These roles provide the following privileges:
Privilege | Consumer1 | Designer |
---|---|---|
Resources | ||
View APIs and domains | ✓ | ✓ |
Create and edit APIs and domains, add and delete versions, publish/unpublish, rename, compare and merge | ✓ | |
Create, edit and manage API custom templates | organization owners | |
Transfer resources to another owner, delete resources | organization owners | |
Code generation | ||
Generate client and server code 2 | ✓ 2 | |
Configure codegen options | ✓ | |
Integrations | ||
Add, manage and trigger integrations | ✓ | |
Working with Others | ||
Manage sharing | ✓ | |
Comments (OpenAPI only) | ||
View, add, reply, edit, resolve, delete, reopen comments | ✓ 3 | ✓ |
1 Organization members get commenting permissions automatically if the Allow Consumers to Comment on all the APIs & Domains they can access option is enabled for the organization. This option is available in SwaggerHub SaaS, SwaggerHub On-Premise 1.24 and later.
2 API owners and designers can limit the client and server generators available to individual APIs.
3 Consumers can resolve, edit, delete, and reopen only their own comments.
Manage resource sharing
Designers can manage the members that are allowed to share resources.
-
Open your API or domain page.
-
In the top right corner, click
:
-
To add members, enter a user name or team name you want to add, and select a role for each.
To remove a user, click Remove next to their name.
Newly invited users will get an email notification.
Email notifications
All people sharing a resource receive an email notification when:
-
They have been invited to share a resource.
-
Comments are added, replied to, resolved or reopened.
-
A version of a resource is published, unpublished or deleted.
Note: | Saving the API in the editor and adding a new API version do not trigger notifications. Also, notifications are not sent to the user who triggered notifications. |
Concurrent editing
Multiple users can edit the same API definition simultaneously. However, when somebody saves their changes, they can overwrite the changes made by others. To prevent data loss, during editing, SwaggerHub displays a warning every time someone saves their changes to the definition:

Also, if someone changed the API definition while you were editing it, SwaggerHub will warn you before saving your changes:

To avoid data loss in this case, we recommend that you save your API to a file and then merge it with the API stored in SwaggerHub. You can merge specifications by using the SwaggerHub Compare and Merge feature, or by using some external merge tool.
Also, we recommend that you use comments to coordinate your work with other users.