Generating documentation for a Datasnap RESTful API - api

I've been looking for a way to include an auto-generated documentation endpoint to an existing Delphi Datasnap RESTful API.
Can it be done? Are there annotations or external tools I can use?
Where would I begin, how would I proceed? If not from within Delphi itself, can I integrate with e.g. Swagger?
It seems somewhat anachronistic to build a RESTful API without offering a documentation endpoint these days...
Any and all information that could help me in the right direction would be greatly appreciated.

Using Swagger, via YAML has just been added to Delphi through EMS, the latest RESTful API development option in Delphi.
https://delphiaball.co.uk/2016/04/22/swagger-yaml-delphi/
Its based on Attributes that are added to the API end points as they are defined and that in turn creates the YAML to import into Swagger.

Related

Does exist a universal tool to describe different APIs (REST, WebSocket, gRPC, custom framework)?

My project uses different protocols to communicate with other services:
REST API
WebSocket (STOMP)
gRPC
own framework build over gRPC.
I need a tool, or a bunch of tools, which allow me to generate documentation for the APIs. In the best scenario, it's a maven plugin that generates a report with all APIs.
We use Swagger to describe the REST API. It has poor export options and needs a lot of annotations in the code, but describes the API well and offer the test machine.
Alternatively, Spring RestDocs (AsciiDoctor) could be used for the REST API describing. It offers a better format for reporting, but we prefer Swagger.
That's all I found for the REST API. But I didn't find anything for describing WebSocket API, gRPC and the custom framework.
I will be very grateful for any help and ideas to solve the problem.

Is there any solution for generating the restfual api code both for client and server

The functions for operating the restful api is quite same. Is there any project that can generate the source code for different platform such android,ios and backend stuff.
I suggest you to use API description languages such Swagger ou RAML.
After having described your RESTful application with a language like this, you will be able to generate things like server skelekons and client sdks with different technologies and languages. You can even generate documentations.
With Swagger, swagger-codegen will do that. swagger-ui may also interest you for the documentation part.
To finish, I would like to mention the Restlet studio that allows to define graphically and quickly the structure of RESTful applications and generate then the corresponding Swagger and RAML contents. The APISpark plaform provides a mecanism to introspect Restlet applications and generate the corresponding contents with these languages. It also allow you to generate a set of server skelekons and client sdks.
Hope it helps you.
I will suggest you to use Spring RESTful webservices starter kit. Which will manage your back-end with centralized database. Also Spring has its own android libs to communicate with REST Apis.

Generating REST API Documentation from Restlet annotations

The RESTful Web service APIs are implemented using Restlet. I need to generate the API documentation for these. Rather than starting with a separate document, I am evaluating if this can be generated from the source code annotations itself.
I looked at Swagger and enunciate. Swagger seems to be based on the JAX-RS specification. Enunciate looked a little more promising as there is an FAQ that mentions how to generate for non JAX-RS implementations but there is no help.
Are there any tools (or if the community has used any) for generating API documentation from Restlet annotations?
Has anyone integrated Restlet with enunciate for generating documentation?
Restlet now supports the ability to generate either corresponding Swagger and RAML contents based your application at runtime.
Following docs could help you:
For Swagger (extension org.restlet.ext.swagger): see http://restlet.com/technical-resources/restlet-framework/guide/2.3/extensions/swagger
for RAML (extension org.restlet.ext.raml): see http://restlet.com/technical-resources/restlet-framework/guide/2.3/extensions/raml
You can then leverage tools from the tool community to generate your API documentation. You could consider Swagger UI that is a great tool to display online what an API provides and interact with it.
Hope it helps you,
Thierry

What online REST API workbenches are available?

When creating a site/script to be on the client end of a RESTful API, what tools are available to create a "workbench" to explore the API, examining headers and responses while working through the design? Preferably one(s) that allow you to enter a custom endpoint, and create sample requests to see the responses. I recall seeing one nice workbench before, but its name has escaped me.
Re-found the one I remembered: The Apigee Console is a great interface for playing around with an existing API or building your own.
Mashery's I/O Docs is an open source workbench that you can deploy yourself on a Node.js server with Redis for storage.
If you have the wadl file of the ReST Services, you can load it in SOAP UI and use it.
EditedAnother much simpler tool Rest Client

Can you use JIRA's SOAP API in a VB.NET desktop application?

I tried using JIRA's REST API but the function that I needed wasn't there and found it at JIRA's SOAP API. A newbie like me wants to know if you can use JIRA's SOAP API in a VB.NET desktop application? Thanks!
Absolutely. The point of a SOAP service is to allow access to the data and functionality of application from another application regardless of the language it is written in. All you need is something in your program that understands how to talk to and work with a SOAP service.
I have no doubt that a VB.NET application can talk to a SOAP service without issue, but I am not a .NET programmer so I can not provide any specific guidance on how to do it.
What you will want to search for is "Consuming SOAP services with VB.NET". I did that myself and came up with some god looking tutorials.
http://www.codeproject.com/KB/vb/vbwebservice.aspx
http://www.vbdotnetheaven.com/Uploadfile/SrinivasSampath/WebServiceusingSOAPToolkit11242005002126AM/WebServiceusingSOAPToolkit.aspx
http://visualbasic.about.com/od/learnvbnet/a/LVBE_L6_3.htm
Like I said, I think everything you need will be built into the .NET framework. I don't think you will need to download anything additional or include extra libraries.