Resource Roles

This page of the documentation describes roles and permissions for resource access in SaaS. For working with others in On-Premise installations, click here.Share APIs 

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

For product management in Portal, go to the User Management section on the Portal documentation.

These roles provide the following privileges:

Privilege

Consumer1

Designer

Resources 

View APIs and domains

Create and edit APIs,  and domains; add an delete versions, publish/unpublish, rename, compare and merge

Create and manage Portal products

✓ 

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 they Allow Consumers to Comment on all the APIs & Domains, they can access option is enabled for the organization. They can also view the Portal Products. 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.

  1. Open your API or domain page.

  2. In the top right corner, click share.png:

    Collaboration
  3. 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.

    Sharing and roles

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:

Editing Swagger definitions in SwaggerHub: Warning on concurrent editing

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

Editing Swagger definitions in SwaggerHub: Message on overwriting 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.

See Also

Publication date: