Part 3 - Test the API with Browser and Swagger

1. In your browser, browse to the AWS Serverless URL and add /api/values to the end of the URL, to call the default Get() method on the ValesController. Your browser should display the JSON for “value1” and “value2” (some browsers may prompt you to download the file first).

2. Next, you can test your API with Swagger. To test your api add /swagger/v1/swagger.json to the publish URL, it should look like: 07sdkeif.execute-api.us-east-1.amazonaws.com/Prod/swagger/index.html

3. To test your Values controller, click GET, click Try it out, then Execute and you will see the response from GET request.

4. Verify that for the GET request, the response includes the same json as when you tested with your browser.

5. You can also test the POST method in a similar manner, click Try it out, modify the request body to be a number, then click Execute and verify the successful response code of 200