Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Removed extra returns

...

Name

Description

ModelUpdate

A Model specific node. Invokes the Update API on a specified model and returns the response.

 

Instance configuration

 

Property

Description

Required

Type

model

The name of the model of which to invoke the Update API.

yes

string

Instance parameters

 

Property

Description

Type

Required

id

The id of the record to update.

string

true

Example

 

Code Block
linenumberstrue
languagejs
collapsetrue
"model.update": {
 "type": "ModelUpdate",
 "config": {
   "model": "appc.arrowdb/acl"
 },
 "parameters": [
   {
     "name": "id",
     "value": "$.params.id|0"
   },
   {
     "name": "name",
     "value": "$.params[\"appc.arrowdb/acl\"].name|0"
   },
   {
     "name": "readers",
     "value": "$.params[\"appc.arrowdb/acl\"].readers|0"
   },
   {
     "name": "writers",
     "value": "$.params[\"appc.arrowdb/acl\"].writers|0"
   },
   {
     "name": "public_read",
     "value": "$.params[\"appc.arrowdb/acl\"].public_read|0"
   },
   {
     "name": "public_write",
     "value": "$.params[\"appc.arrowdb/acl\"].public_write|0"
   },
   {
     "name": "user",
     "value": "$.params[\"appc.arrowdb/acl\"].user|0"
   },
   {
     "name": "created_at",
     "value": "$.params[\"appc.arrowdb/acl\"].created_at|0"
   },
   {
     "name": "updated_at",
     "value": "$.params[\"appc.arrowdb/acl\"].updated_at|0"
   },
   {
     "name": "pretty_json",
     "value": "$.params[\"appc.arrowdb/acl\"].pretty_json|0"
   },
   {
     "name": "custom_fields",
     "value": "$.params[\"appc.arrowdb/acl\"].custom_fields|0"
   },
   {
     "name": "user_id",
     "value": "$.params[\"appc.arrowdb/acl\"].user_id|0"
   }
 ],
 "response": {
   "context": {},
   "routes": [
     {
       "conditions": [
         {
           "key": "$|0",
           "exists": false
         }
       ],
       "next": "response.error.notfound"
     },
     {
       "next": "response.success"
     }
   ]
 }
}