Instead of importing swagger file through SmartDocs in dev portal, then publishing and rendering, is there any other better way for publishing APIs ?
Can we define some API proxy, where we can post all swagger contents, then publish and render automatically?
I do not mean:
I mean, once swagger docs are uploaded to DEV PORTAL, there is process of rendering and publishing them. Can we do that "Rendering and Publishing" part through an API call?
Thanks,
@NiteshShrestha Is this a Duplicate? Please see this question.
(Edit: no, not a duplicate. I see this is a distinct question.)
For uploading APIs into Drupal, This link contains a tutorial along with a Postman collection. https://community.apigee.com/questions/4449/are-there-any-management-apis-for-smartdocs-can-i.html
Regarding rendering and publishing SmartDocs nodes:
Only out of the box core features are accessible via APIs. SmartDocs is a custom feature on top of core Drupal in the Apigee Edge devportal distribution, and is not (yet?) available via APIs. It could theoretically be APIfied with a custom module, yet to be written.
Thanks @Srinandan Sridhar and @Diego Zuluaga for guidence. I am able to upload apis in dev portal. Can we also render and publish through api ?
Yes. You can generate HTML from the Mgmt. API. Try it here. https://github.com/dzuluaga/apigee-tutorials/tree/master/apiproxies/sample-api-smartdocs#show-gener...
@Diego Zuluaga, I do not mean to generate HTML. I mean, once swagger docs are uploaded to DEV PORTAL, there is process of rendering and publishing them. Can we do that "Rendering and Publishing" part through API as well?
I see what you mean. It may be possible. My assumption is that all actions in Drupal are accessible through Drupal RESTful API. I was checking some resources online and that seems to be the case. Check this out https://www.drupal.org/project/restful.
@Anil Sagar any ideas here?
@Diego Zuluaga , Only out of the box core features are accessible via APIs. Smartdocs is a custom feature on top of core drupal in Apigee Distro. It can be APIfied with a custom module. I am sure, many will love it. Just need to find out time to write that module. @Dino , @Chris Novak , @Daniel Johnson What do you think about same ?
Yes - the Drupal Services module can allow this function to be API-fied!
I searched and found this video that describes how it would be possible. We can define our own functions that can respond to inbound API requests. That interesting bit starts around 37:00 .
It is not possible to do this out of the box, but it should be possible for Apigee to add this function to the Drupal devportal.
@Anil Sagar FYI
@Anil Sagar , @Dino, @Chris Novak, @Daniel Johnson This thread is about a year old, do you know if any progress has been made? We too are looking for this functionality in order to automate the process of publishing API documentation to the developer portal.
Thanks!
User | Count |
---|---|
1 | |
1 | |
1 | |
1 | |
1 |