OperatorAPI insert
newadmapi (Operator API) function. Available to: Operator, SuperRoot.
Description
Creates a row in a section. The record fields travel as a JSON body and must be exactly the declared writable set - an unknown or duplicated field is refused BY NAME. The tenant is stamped from your credential and may not be supplied. Requires the group the section declares.
section parameter. Discover sections with OperatorAPI sections and a section's fields/capabilities with OperatorAPI options.Call
GET|POST https://YOUR_HOST:9089/newadm?func=insert
Send your API key with every request (header X-API-Key: YOUR_KEY, or Authorization: Bearer YOUR_KEY, or the ukey query parameter).
Parameters
| Parameter | Type | Required | Default | Meaning |
|---|---|---|---|---|
section |
string | Yes | — | The section key. |
Example
POST https://host:port/newadm?func=insert§ion=bonos body {"name":"Bono 60","price":1.5,"seconds":3600}
Response
Success is {"ok":true,"data":{...}}; on refusal {"ok":false,"code":"...","message":"..."}. This function's data shape (n = number, s = string, ? = present only when set):
{
"ok":true,
"data":{
"section":s,
"id":n,
"created":true
}
}
Errors
Refusals carry a machine-readable code (branch on the code, never the message). See OperatorAPI#Error codes.
Back to OperatorAPI