API tab
The API tab provides a sample CURL command allowing you to test the API experience within Graft ahead of linking to your production environment. You are able to customize the API command and see initial results and copy both sample results and the API command
Graft API Key Required
To test the API you need to have created an API key
Click on "DEFINE AN API KEY TO USE THIS APP" link which will open the Security settings in the side drawer. Once at least one key is created it will appear in a API key drop down allowing key switching as need it.
TEST API REQUEST
Once you have created one or more keys you will be able to try your app within Graft ahead of using this code in your own application.
- From the API Key down Select the required Key
- From the Output format drop down you can select CSV (default), TSV of JSONL (JSON lines))
- Click on TEST REQUEST to run the Curl request with the specified key in the API key drop down list
API Key truncated
For the security of your API key we do not display the entire KEY, it is ESSENTIAL when you create a key that you securely store it as you will need to add it to the Curl command when copied for production use
Copying your CURL command
You can copy the CURL command by Clicking on the icon.
Viewing Results
The Curl command will complete and provide formatted response below the query
Copying your results
You can copy the CURL command or response output by Clicking on the icon.
Remember to add in your full API key when testing in your app
Customizing your API Request
You can tweak the configuration of your request from the right panel, unchecking or rechecking items will automatically update the Request. |
For the search app you are able to enter your query text |