Windward DocumentationWindward Core.NET RESTful Engine User Manual ReferenceRESTful Engine API Tutorial: Getting Started With SwaggerHub

RESTful Engine API Tutorial: Getting Started With SwaggerHub

This tutorial outlines how to use our SwaggerHub API to test out our RESTful engine without the need to download or setup any software. In this tutorial we will step through the process to generate a document using the predefined request body on SwaggerHub, and then download the generated document. We provide a template and data file in the predefined request body on SwaggerHub so you will not need to do anything extra.

What You Need

All you need to complete this tutorial is a trial license key which you can get from our website.

Testing Out the RESTful Engine

1. Navigate to our SwaggerHub API

2. You will need to enter your trial license key. To do so, click on the "Authorize" button at the top of the API documentation

3. Enter your trial key, then click Authorize

Prior to November 2021 you will need to reformat the trial license key to be on one line in order to use with swagger hub.

4.  Now we POST the template we want to process. Navigate to the "Documents" section in the API documentation, then expand the "POST /v2/document" endpoint, this is what you will see

5. Click on the "Try it out" button:

The text encompassed in the RED rectangle is your Request Body. In the request body we specify everything from the template we want to process, to the data sources we are using to the output format we want. We provided you with a complete request body for testing. As you can see, this template is making use of a JSON data source.

6. After you've taken a look at the request body, click the "Execute" button to send the POST request. After sending the request, scroll down a bit and you will see the response from the engine:

Make sure to copy the "Guid" from the response. The GUID is a unique identifier we use for the documents so you will need it to download the document.


7. Now we can download the generated document by making use of the GET /v2/document/{GUID}/file endpoint. You can hit this endpoint via your browser using the following address:

http://ec2-3-88-142-249.compute-1.amazonaws.com/v2/document/{YOUR_GUID_HERE}/file

This will download the generated document.

If the document does not download/open after your first attempt, give it a few seconds and try hitting that address again as the document might not yet be ready to retrieve. We will go over this and a more advance way to retrieve the document in the next tutorial.

RESTful Engine Tutorial: Next Steps

After completing this tutorial, we recommend stepping through the next tutorial that will step you through the full document generation process and all the endpoints relevant for you to interact with the RESTful Engine. 


If you are ready to setup your own RESTful engine, follow the instructions in this article.

0 Comments

Add your comment

E-Mail me when someone replies to this comment

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.