How to get Documentation shown in other Marketplace Apps?

29 views
Skip to first unread message

bi...@abinfo.de

unread,
Mar 5, 2021, 1:24:25 AM3/5/21
to Fusio
Currently I have the sample "todo" API and a self-created API for tests in Fusio (only using the backend app).
Want to have a useful documentation (openapi standard if possible).

When using the marketplace app "swagger-ui (1.0.0)" the documentation is fragmented: All routes are shown - but schemas are only shown for the "todo" routes (which are part of the folderstructure). My routes that I have created with the GUI are missing! How can this be solved?

When using the marketplace app "documentation (1.0.5)" nothing is shown at all. Is there a documentation available how to use this app to get the content from Fusio backend?
When using the marketplace app "developer (1.0.0)" all links are showing errors due to they are pointing to "/var/www/demo.fusio-project.org/..." but not to my own project! What's wrong?

In general: What is the best approach to get, ideally automated, an openapi standard based documentation of my endpoints?

Greetings
Andreas

Christoph Kappestein

unread,
Mar 5, 2021, 5:52:36 PM3/5/21
to Fusio
Hi Andreas,

so in general the routes which you have created through the GUI should be also available at the swagger-ui app. Do you have created a fitting request/response schema for your routes, theses schemas are required to build an OpenAPI spec.
Regarding the errors at the other apps, could you take a look at the errors logs to see whether there is an error, also you can delete the cache folder but it sounds like there is some problem with the installation.

best regards
Christoph

bi...@abinfo.de

unread,
Mar 8, 2021, 7:44:23 AM3/8/21
to Fusio
Hi Chirstoph,

here is an intermediate state after checking more details:

[Solved] Showing schemas in swagger-ui:
Problem was sitting once again in front of the screen ;-) The name of the schema in the UI has differ from name in the json schema. After correcting the schemas are all shown as expected.

[Issue] Subsequent slash in index.html of app "documentation":
The url to the PSX documentation endpoint has a subsequent slash:
evidProvider.setUrl('http...../index.php/');
This lead to 2 slashes // in the url:
http...../index.php//system/doc
After removing the subsequent slash from the index.html the app shows all routes as expected.
Could you check setup routine of the app to fix that issue?

Best regards
Andreas


bi...@abinfo.de

unread,
Mar 9, 2021, 3:59:18 AM3/9/21
to Fusio
Hi Christoph (sorry for typo in your name at my last post),

here is an update:

[Issue] Links are not updated in the app "developer":
Seems that all dynamic links in the app are working fine except of the 2 static links in the file "api.htm":
The links "https://demo.fusio-project.org/documentation" and "https://demo.fusio-project.org/swagger-ui" are not updated, whent installing the app by marketplace via the Fusio backend app.
 Could you check setup routine of the app?

Best regards
Andreas

Christoph Kappestein

unread,
Mar 9, 2021, 5:03:12 PM3/9/21
to Fusio
Hi Andreas  ,

no problem, both of these links are currently static at those documentation files so theses urls are not updated automatically they simply point to the demo url.
But in general it would be a great idea to points theses links automatically to the correct Fusio instance, through the links we have added in the latest release this would
be also easy possible. I have just created an issue regarding this s. https://github.com/apioo/fusio-apps-developer/issues/16

best regards
Christoph

Reply all
Reply to author
Forward
0 new messages