cancel
Showing results for 
Search instead for 
Did you mean: 

Default version

SOLVED
Highlighted
New Contributor

Default version

Hi,

Is there some possibility to mark particular version of my API as a default one through registry-api or another API?

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Moderator

Hi,

 

Curently you can not do this with the RegistryAPI, however, we have an existing enhancement request to implement this feature.

 

Regards,

Marcus James

SmartBear Support



Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today

View solution in original post

Highlighted
Moderator

This is now possible - you can set the default version by using "PUT​ /apis​/{owner}​/{api}​/settings​/default":

curl -X PUT "https://api.swaggerhub.com/apis/OWNER/API_NAME/settings/default"
     -H "Authorization: SWAGGERHUB_API_KEY"
     -H "Content-Type: application/json"
     -d "{\"version\": \"1.0.0\"}"

API docs


Helen Kosova
SmartBear Documentation Team Lead
________________________
Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today

View solution in original post

4 REPLIES 4
Highlighted
Occasional Visitor

+1

Highlighted
Moderator

Hi,

 

Curently you can not do this with the RegistryAPI, however, we have an existing enhancement request to implement this feature.

 

Regards,

Marcus James

SmartBear Support



Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today

View solution in original post

Highlighted
Moderator

This is now possible - you can set the default version by using "PUT​ /apis​/{owner}​/{api}​/settings​/default":

curl -X PUT "https://api.swaggerhub.com/apis/OWNER/API_NAME/settings/default"
     -H "Authorization: SWAGGERHUB_API_KEY"
     -H "Content-Type: application/json"
     -d "{\"version\": \"1.0.0\"}"

API docs


Helen Kosova
SmartBear Documentation Team Lead
________________________
Learn SmartBear products in a fun and easy way and prove your knowledge!
>>Participate in the TechCorner Challenge today

View solution in original post

Highlighted
New Contributor

Great to hear.

Thank you.

New Here?
Join us and watch the welcome video:
Announcements