Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Swagger support #5222

Merged
merged 1 commit into from
Mar 23, 2020
Merged

Add Swagger support #5222

merged 1 commit into from
Mar 23, 2020

Conversation

egbertbouman
Copy link
Member

@egbertbouman egbertbouman commented Mar 18, 2020

This PR adds /docs to our REST API server that will serve the Swagger UI. From there, you will find a list of all API endpoints available in both Tribler and IPv8.

I've converted all the old doc strings to aiohttp_apispec decorators. I've also added some new documentation to a number of undocumented channels/metadata endpoints. However, since I'm not sure exactly what these functions do and what their input/output is, I've kept the documentation to a minimum. Despit this, I've probably made some mistakes here.

Swagger also supports API keys (you just need to click 'Authorize' and copy-paste the API key). The Swagger UI itself can be visited without the API key.

image

@ghost
Copy link

ghost commented Mar 18, 2020

Congratulations 🍻. DeepCode analyzed your code in 0.381 seconds and we found no issues. Enjoy a moment of no bugs ☀️.

💬 This comment has been generated by the DeepCode bot, installed by the owner of the repository. The DeepCode bot protects your repository by detecting and commenting on security vulnerabilities or other critical issues.


☺️ If you want to provide feedback on our bot, here is how to contact us.

@egbertbouman egbertbouman force-pushed the swagger branch 3 times, most recently from 0f6e25b to d463f89 Compare March 22, 2020 12:37
@egbertbouman egbertbouman marked this pull request as ready for review March 22, 2020 17:00
@egbertbouman egbertbouman force-pushed the swagger branch 4 times, most recently from 2718d1c to 8c91178 Compare March 22, 2020 20:06
@sonarcloud
Copy link

sonarcloud bot commented Mar 22, 2020

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 2 Security Hotspots to review)
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.4% 0.4% Duplication

@qstokkink
Copy link
Contributor

Is this ready for review?

@egbertbouman
Copy link
Member Author

@qstokkink Yep, ready.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants