Using Morph as a backend to your application
An API can be created for Morph's Tables that can be accessed by external programs and servers.
This allows you to connect Morph data to external tools, or use it as a no-code back-end for your front-end application.
Each of these APIs is issued with a unique API Key, which is used to restrict access. Please handle with care.
Create an API for a table
To create an API for a Table, click the +Create
button in the top right of the Table screen, then select which type of Data API you wish to create from the drop-down menu.
Types of APIs
Morph supports the following types of Table APIs:
- Query: retrieve a list of records
- Create: create a new record
- Update: update an existing record
- Delete: delete an existing record
- Upload: upload an image or file
- Download: download a list of records in CSV format
- Aggregate: perform aggregation or grouping on a table and retrieve the results
Configuring API types
Query API, Download API
The following rules can be set for the Query API and Download API:
- Select: select which Fields to expose to the API.
- Mask: select the fields for which the acquisition result will be masked. The field specified here must also be specified in Select.
- Filter: allows you to specify the filtering conditions. The filtering conditions set here are always applied; additional filtering conditions can also be given when executing the API.
- Sort: allows you to specify sorting conditions. The sort condition set here is always applied; additional sort conditions can also be given when executing the API.
Create API, Update API
The Create API and Update API allow you to set the following rules:
- Fixed values: set default values you want to insert, regardless of the content of the API request.
Aggregate API
The Aggregate API allows you to set the following rules:
- Aggregation: select the fields for aggregation. Aggregation functions include sum, count, mean, and median.
- Group keys: if you want to group the aggregation results by the value of a specific field, you can specify the field here.
- Filter: specify filtering conditions. The filtering conditions set here are always applied; additional filtering conditions can also be given when executing the API.
- Sort: specify sorting conditions. The sort condition set here is always applied; additional sort conditions can also be given when executing the API.
Delete API, Upload API
There are no additional configuration rules for the Delete or Upload APIs. Required parameters are specified at runtime.
API documentation.
For a detailed specification of the API, see the API documentation.