Playground

API playground has some sections that we should first know about them. As you can see in the below picture, We have set token access in the top and the list of whole generated endpoints API for each model. :

We will talk about access token and how you should work with that at the next steps. Let's focus on endpoints and as you can see we first generating whole CRUD endpoints and some extra endpoints for another purposes. You can reach whole generating endpoints and their duties, request and response status by overview of each endpoint in our playground.

For each endpoint you have some information as below image shown you can reach to request model data object and types and ability to send query and test your endpoint. We have filter option for your queries to reach to your specific data's in your database. We will explain more about how filters works in next step

Try request your API's to figure out that you can reach to specific data's and make sure to everything with your endpoint responses and health before deploy on production.

POST or PUT have to send data to them and in our playground you can just create your own object manually and try your test easily.

Let's try out random default endpoints and see what gonna be our result. Also you can set your desired parameter content type.

Curl

curl -X PUT --header 'Content-Type: application/json' --header 'Accept: application/json' -d '{ \ 
   "city": "London", \ 
   "email": "test%40gmail.com", \ 
   "name": "VT", \ 
   "id": 1 \ 
 }' 'http://127.0.0.1:8080/api/CoffeeShops'

Request URL

http://127.0.0.1:8080/api/CoffeeShops

Response Body

{  
    "city": "London",  
    "email": "test@gmail.com", 
    "name": "VT",
    "id": 1
}

Response Code

200

Response Headers

{
  "date": "Tue, 04 Sep 2018 10:09:51 GMT",
  "x-content-type-options": "nosniff",
  "etag": "W/\"3d-sUksLqWJj9l6vsFAgSc58jMxC18\"",
  "x-download-options": "noopen",
  "x-frame-options": "SAMEORIGIN",
  "content-type": "application/json; charset=utf-8",
  "access-control-allow-origin": "http://127.0.0.1:8080",
  "access-control-allow-credentials": "true",
  "strict-transport-security": "max-age=0; includeSubDomains",
  "vary": "Origin, Accept-Encoding",
  "content-length": "61",
  "x-xss-protection": "1; mode=block",
  "keep-alive": "timeout=38"
}

We send our requests by CURL and first of all you will see curl url in responses section. Request Url contains your endpoint address and you can try this url in other platforms too. Your response body contains response from server and you can see your responses body and response code right after send request. We also collect all your response headers at the end.

pageFilters

Last updated