-
-
Save swannodette/50784 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
read | |
---- | |
{ | |
"action": "read", | |
"table": "user/shift/trail/comment", | |
"constraints": { | |
"user_id": 67 | |
}, | |
"properties": "*" || ["username", "summary", "modified"], | |
"orderby": ["<" || ">", "modified"], | |
"startIndex": 2, | |
"range": { | |
"startIndex": 2, // array base is 0 | |
"count": 20 | |
} | |
} | |
- returns array of results | |
delete | |
------ | |
{ | |
"action": "delete", | |
"table": "user/shift/trail/comment", | |
"constraints": { | |
"user_id": 67 | |
}, | |
} | |
- returns number of rows deleted | |
update | |
------ | |
{ | |
"action": "update", | |
"table": "user/shift/trail/comment", | |
"constraints": { | |
"user_id": 67 | |
}, | |
"values": { | |
"user_id": 68, | |
"name": "Avital" | |
} | |
} | |
- returns number of rows updated | |
create | |
------ | |
{ | |
"action": "create", | |
"table": "user/shift/trail/comment", | |
"values": { | |
"name": "Avital" | |
} | |
} | |
- returns new id | |
table mapping | |
++++++++++++++ | |
{ | |
"virtual": "worksinset.read", | |
"properties": ["tag", "position", "note"], | |
"map": { | |
{from:"artworkid", to:"artwork.id", properties:["title", "image", "artist", "date"]} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment