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

Re: Default version

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



Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️

View solution in original post

Highlighted
Moderator

Re: Default version

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 Technical Writer
________________________

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️

View solution in original post

4 REPLIES 4
Highlighted
Occasional Visitor

Re: Default version

+1

Highlighted
Moderator

Re: Default version

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



Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️

View solution in original post

Highlighted
Moderator

Re: Default version

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 Technical Writer
________________________

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️

View solution in original post

Highlighted
New Contributor

Re: Default version

Great to hear.

Thank you.

New Here?
Join us and watch the welcome video: