Consuming a BookStore REST Endpoint
Importing the REST API document
Swagger 2.0-compliant REST API documents must be imported into the TIBCO Business Studio™ for BusinessWorks™ Service Descriptors folder of the project. This gives you the ability to expand and collapse endpoints, operations, parameters and response codes in the Project Explorer view.
Accessing the BookStore Swagger
For the BookStore sample running in the Cloud Foundry environment, the swagger URL should be accessible using the routable URL in the format
http://routable URL/swagger
.
For example,
bookstoreapp.test.com:80/swagger/
Retrieving the Swagger Document
You can now retrieve the swagger document by accessed using the URL
http://routable URL/swagger/swagger.json
or using the following curl command:
curl http://bookstoreapp.test.com:80/swagger/swagger.json -o bookstore.json
Importing the Swagger Document in Service Descriptors Folder
For configuring the design time, import the bookstore.json file in your workspace project under the Service Descriptors folder.