{"ok":true,"site":{"host":"pubkey.github.io","url":"https://pubkey.github.io/rxdb-quickstart/#room-yvkyxmampy","type":"live","desc":"RxDB Quickstart • TodoMVC","tools":[{"name":"rxdb_query_tpdp-17-2-0-853d7864c7_todos_0","kind":"answer","impl":"imperative","description":"Query the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7'. Allows filtering, sorting, and pagination. Returns an array of matched document objects. The collection has the following JSON schema: {\"additionalProperties\":false,\"encrypted\":[],\"indexes\":[[\"state\",\"id\"],[\"state\",\"lastChange\",\"id\"],[\"id\"]],\"keyCompression\":false,\"primaryKey\":\"id\",\"properties\":{\"id\":{\"maxLength\":20,\"type\":\"string\"},\"lastChange\":{\"maximum\":2701307494132,\"minimum\":0,\"multipleOf\":1,\"type\":\"number\"},\"name\":{\"type\":\"string\"},\"state\":{\"enum\":[\"open\",\"done\"],\"maxLength\":10,\"type\":\"string\"}},\"required\":[\"id\",\"name\",\"state\",\"lastChange\"],\"type\":\"object\",\"version\":0}. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","annotations":{"readOnlyHint":true},"inputSchema":{"type":"object","$defs":{"sort":{"description":"Sort document (e.g. [{ createdAt: 'desc' }, { name: 'asc' }]).","type":"array","items":{"type":"object","minProperties":1,"additionalProperties":false,"patternProperties":{"^(?!\\$).+$":{"type":"string","enum":["asc","desc"]}}},"examples":[[{"createdAt":"desc"}],[{"lastName":"asc"},{"createdAt":"desc"}]]},"expression":{"anyOf":[{"$ref":"#/$defs/logicalExpression"},{"$ref":"#/$defs/fieldExpression"}]},"logicalExpression":{"type":"object","additionalProperties":false,"properties":{"$and":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/expression"},"examples":[[{"status":"active"},{"age":{"$gte":21}}]]},"$or":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/expression"},"examples":[[{"role":"admin"},{"role":"moderator"}]]},"$nor":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/expression"},"examples":[[{"archived":true},{"deleted":true}]]},"$not":{"$ref":"#/$defs/expression","examples":[{"age":{"$lt":18}},{"name":{"$regex":"^test"}}]}},"anyOf":[{"required":["$and"]},{"required":["$or"]},{"required":["$nor"]},{"required":["$not"]}],"examples":[{"$and":[{"status":"active"},{"age":{"$gte":21}}]},{"$or":[{"tier":"pro"},{"trial":true}]},{"$nor":[{"deleted":true},{"blocked":true}]},{"$not":{"age":{"$gte":65}}}]},"fieldExpression":{"type":"object","minProperties":1,"additionalProperties":false,"patternProperties":{"^(?!\\$).+$":{"anyOf":[{"$ref":"#/$defs/literal"},{"$ref":"#/$defs/fieldOperatorExpression"}]}},"examples":[{"status":"active"},{"age":{"$gte":18}},{"tags":{"$in":["nosql","database"]}}]},"fieldOperatorExpression":{"type":"object","minProperties":1,"additionalProperties":false,"properties":{"$eq":{"$ref":"#/$defs/literal","examples":["active",42,null]},"$ne":{"$ref":"#/$defs/literal","examples":["deleted",0]},"$gt":{"$ref":"#/$defs/literal","examples":[10,100]},"$gte":{"$ref":"#/$defs/literal","examples":[18,0]},"$lt":{"$ref":"#/$defs/literal","examples":[100,5]},"$lte":{"$ref":"#/$defs/literal","examples":[5,99]},"$in":{"type":"array","items":{"$ref":"#/$defs/literal"},"examples":[["red","green"],[1,2,3]]},"$nin":{"type":"array","items":{"$ref":"#/$defs/literal"},"examples":[["test","dummy"],[0,-1]]},"$exists":{"type":"boolean","examples":[true,false]},"$regex":{"type":"string","examples":["^A",".*example.*","^[0-9]{4}$"]},"$options":{"type":"string","examples":["i","g","m"]},"$type":{"oneOf":[{"type":"string"},{"type":"integer"},{"type":"array","items":{"oneOf":[{"type":"string"},{"type":"integer"}]}}],"examples":["string","number",2,["string","null"]]},"$size":{"type":"integer","minimum":0,"examples":[0,3]},"$mod":{"type":"array","minItems":2,"maxItems":2,"items":{"type":"integer"},"examples":[[4,0],[10,5]]},"$elemMatch":{"$ref":"#/$defs/expression","examples":[{"qty":{"$gte":10}},{"type":"book"}]}},"examples":[{"$eq":"active"},{"$ne":"deleted"},{"$gt":10},{"$gte":18},{"$lt":100},{"$lte":5},{"$in":["red","green"]},{"$nin":["test"]},{"$exists":true},{"$regex":"^A"},{"$type":"string"},{"$size":3},{"$mod":[4,0]},{"$elemMatch":{"qty":{"$gte":10}}}]},"literal":{"oneOf":[{"type":"null"},{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"array"},{"type":"object"}]}},"properties":{"query":{"$schema":"https://json-schema.org/draft/2020-12/schema","title":"NoSQL Query","description":"Query selector with sort and limit options. See https://rxdb.info/rx-query.html","type":"object","additionalProperties":true,"required":["selector"],"properties":{"selector":{"$ref":"#/$defs/expression"},"sort":{"$ref":"#/$defs/sort"},"limit":{"type":"integer","minimum":1,"examples":[10,50,100]},"skip":{"type":"integer","minimum":0,"examples":[10,50]}},"examples":[{"selector":{"age":{"$gt":18},"status":"active"},"sort":[{"createdAt":"desc"}],"limit":10},{"selector":{"$or":[{"company.name":{"$regex":"Inc","$options":"i"}},{"tags":{"$in":["premium","vip"]}}],"address.country":"USA"},"limit":50}],"default":{"sort":[{"id":"asc"}]}}},"required":["query"]},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"},{"name":"rxdb_count_tpdp-17-2-0-853d7864c7_todos_0","kind":"answer","impl":"imperative","description":"Counts the documents in the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7' matching a given query. The collection has the following JSON schema: {\"additionalProperties\":false,\"encrypted\":[],\"indexes\":[[\"state\",\"id\"],[\"state\",\"lastChange\",\"id\"],[\"id\"]],\"keyCompression\":false,\"primaryKey\":\"id\",\"properties\":{\"id\":{\"maxLength\":20,\"type\":\"string\"},\"lastChange\":{\"maximum\":2701307494132,\"minimum\":0,\"multipleOf\":1,\"type\":\"number\"},\"name\":{\"type\":\"string\"},\"state\":{\"enum\":[\"open\",\"done\"],\"maxLength\":10,\"type\":\"string\"}},\"required\":[\"id\",\"name\",\"state\",\"lastChange\"],\"type\":\"object\",\"version\":0}. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","annotations":{"readOnlyHint":true},"inputSchema":{"type":"object","$defs":{"sort":{"description":"Sort document (e.g. [{ createdAt: 'desc' }, { name: 'asc' }]).","type":"array","items":{"type":"object","minProperties":1,"additionalProperties":false,"patternProperties":{"^(?!\\$).+$":{"type":"string","enum":["asc","desc"]}}},"examples":[[{"createdAt":"desc"}],[{"lastName":"asc"},{"createdAt":"desc"}]]},"expression":{"anyOf":[{"$ref":"#/$defs/logicalExpression"},{"$ref":"#/$defs/fieldExpression"}]},"logicalExpression":{"type":"object","additionalProperties":false,"properties":{"$and":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/expression"},"examples":[[{"status":"active"},{"age":{"$gte":21}}]]},"$or":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/expression"},"examples":[[{"role":"admin"},{"role":"moderator"}]]},"$nor":{"type":"array","minItems":1,"items":{"$ref":"#/$defs/expression"},"examples":[[{"archived":true},{"deleted":true}]]},"$not":{"$ref":"#/$defs/expression","examples":[{"age":{"$lt":18}},{"name":{"$regex":"^test"}}]}},"anyOf":[{"required":["$and"]},{"required":["$or"]},{"required":["$nor"]},{"required":["$not"]}],"examples":[{"$and":[{"status":"active"},{"age":{"$gte":21}}]},{"$or":[{"tier":"pro"},{"trial":true}]},{"$nor":[{"deleted":true},{"blocked":true}]},{"$not":{"age":{"$gte":65}}}]},"fieldExpression":{"type":"object","minProperties":1,"additionalProperties":false,"patternProperties":{"^(?!\\$).+$":{"anyOf":[{"$ref":"#/$defs/literal"},{"$ref":"#/$defs/fieldOperatorExpression"}]}},"examples":[{"status":"active"},{"age":{"$gte":18}},{"tags":{"$in":["nosql","database"]}}]},"fieldOperatorExpression":{"type":"object","minProperties":1,"additionalProperties":false,"properties":{"$eq":{"$ref":"#/$defs/literal","examples":["active",42,null]},"$ne":{"$ref":"#/$defs/literal","examples":["deleted",0]},"$gt":{"$ref":"#/$defs/literal","examples":[10,100]},"$gte":{"$ref":"#/$defs/literal","examples":[18,0]},"$lt":{"$ref":"#/$defs/literal","examples":[100,5]},"$lte":{"$ref":"#/$defs/literal","examples":[5,99]},"$in":{"type":"array","items":{"$ref":"#/$defs/literal"},"examples":[["red","green"],[1,2,3]]},"$nin":{"type":"array","items":{"$ref":"#/$defs/literal"},"examples":[["test","dummy"],[0,-1]]},"$exists":{"type":"boolean","examples":[true,false]},"$regex":{"type":"string","examples":["^A",".*example.*","^[0-9]{4}$"]},"$options":{"type":"string","examples":["i","g","m"]},"$type":{"oneOf":[{"type":"string"},{"type":"integer"},{"type":"array","items":{"oneOf":[{"type":"string"},{"type":"integer"}]}}],"examples":["string","number",2,["string","null"]]},"$size":{"type":"integer","minimum":0,"examples":[0,3]},"$mod":{"type":"array","minItems":2,"maxItems":2,"items":{"type":"integer"},"examples":[[4,0],[10,5]]},"$elemMatch":{"$ref":"#/$defs/expression","examples":[{"qty":{"$gte":10}},{"type":"book"}]}},"examples":[{"$eq":"active"},{"$ne":"deleted"},{"$gt":10},{"$gte":18},{"$lt":100},{"$lte":5},{"$in":["red","green"]},{"$nin":["test"]},{"$exists":true},{"$regex":"^A"},{"$type":"string"},{"$size":3},{"$mod":[4,0]},{"$elemMatch":{"qty":{"$gte":10}}}]},"literal":{"oneOf":[{"type":"null"},{"type":"boolean"},{"type":"number"},{"type":"string"},{"type":"array"},{"type":"object"}]}},"properties":{"query":{"$schema":"https://json-schema.org/draft/2020-12/schema","title":"NoSQL Query","description":"Query selector with sort and limit options. See https://rxdb.info/rx-query.html","type":"object","additionalProperties":true,"required":["selector"],"properties":{"selector":{"$ref":"#/$defs/expression"},"sort":{"$ref":"#/$defs/sort"},"limit":{"type":"integer","minimum":1,"examples":[10,50,100]},"skip":{"type":"integer","minimum":0,"examples":[10,50]}},"examples":[{"selector":{"age":{"$gt":18},"status":"active"},"sort":[{"createdAt":"desc"}],"limit":10},{"selector":{"$or":[{"company.name":{"$regex":"Inc","$options":"i"}},{"tags":{"$in":["premium","vip"]}}],"address.country":"USA"},"limit":50}],"default":{"sort":[{"id":"asc"}]}}},"required":["query"]},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"},{"name":"rxdb_changes_tpdp-17-2-0-853d7864c7_todos_0","kind":"answer","impl":"imperative","description":"Returns all changes of the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7' since a given checkpoint. If no checkpoint is provided, starts from the oldest change. The collection has the following JSON schema: {\"additionalProperties\":false,\"encrypted\":[],\"indexes\":[[\"state\",\"id\"],[\"state\",\"lastChange\",\"id\"],[\"id\"]],\"keyCompression\":false,\"primaryKey\":\"id\",\"properties\":{\"id\":{\"maxLength\":20,\"type\":\"string\"},\"lastChange\":{\"maximum\":2701307494132,\"minimum\":0,\"multipleOf\":1,\"type\":\"number\"},\"name\":{\"type\":\"string\"},\"state\":{\"enum\":[\"open\",\"done\"],\"maxLength\":10,\"type\":\"string\"}},\"required\":[\"id\",\"name\",\"state\",\"lastChange\"],\"type\":\"object\",\"version\":0}. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","annotations":{"readOnlyHint":true},"inputSchema":{"type":"object","properties":{"checkpoint":{"type":"object","description":"The cursor/checkpoint to start fetching changes from. Leave empty to start from the beginning."},"limit":{"type":"number","description":"Maximum number of changes to return.","default":50}}},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"},{"name":"rxdb_wait_changes_tpdp-17-2-0-853d7864c7_todos_0","kind":"act","impl":"imperative","description":"Waits until a new write event happens to the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7'. Returns a promise that resolves when a change occurs. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","annotations":{"readOnlyHint":true},"inputSchema":{"type":"object","properties":{}},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"},{"name":"rxdb_insert_tpdp-17-2-0-853d7864c7_todos_0","kind":"act","impl":"imperative","description":"Insert a document into the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7'. The collection has the following JSON schema: {\"additionalProperties\":false,\"encrypted\":[],\"indexes\":[[\"state\",\"id\"],[\"state\",\"lastChange\",\"id\"],[\"id\"]],\"keyCompression\":false,\"primaryKey\":\"id\",\"properties\":{\"id\":{\"maxLength\":20,\"type\":\"string\"},\"lastChange\":{\"maximum\":2701307494132,\"minimum\":0,\"multipleOf\":1,\"type\":\"number\"},\"name\":{\"type\":\"string\"},\"state\":{\"enum\":[\"open\",\"done\"],\"maxLength\":10,\"type\":\"string\"}},\"required\":[\"id\",\"name\",\"state\",\"lastChange\"],\"type\":\"object\",\"version\":0}. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","inputSchema":{"type":"object","properties":{"document":{"additionalProperties":false,"encrypted":[],"indexes":[["state","id"],["state","lastChange","id"],["id"]],"keyCompression":false,"primaryKey":"id","properties":{"id":{"maxLength":20,"type":"string"},"lastChange":{"maximum":2701307494132,"minimum":0,"multipleOf":1,"type":"number"},"name":{"type":"string"},"state":{"enum":["open","done"],"maxLength":10,"type":"string"}},"required":["id","name","state","lastChange"],"type":"object","version":0,"description":"The document to insert."}},"required":["document"]},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"},{"name":"rxdb_upsert_tpdp-17-2-0-853d7864c7_todos_0","kind":"act","impl":"imperative","description":"Upsert a document into the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7'. If a document with the same primary key exists, it will be overwritten. The collection has the following JSON schema: {\"additionalProperties\":false,\"encrypted\":[],\"indexes\":[[\"state\",\"id\"],[\"state\",\"lastChange\",\"id\"],[\"id\"]],\"keyCompression\":false,\"primaryKey\":\"id\",\"properties\":{\"id\":{\"maxLength\":20,\"type\":\"string\"},\"lastChange\":{\"maximum\":2701307494132,\"minimum\":0,\"multipleOf\":1,\"type\":\"number\"},\"name\":{\"type\":\"string\"},\"state\":{\"enum\":[\"open\",\"done\"],\"maxLength\":10,\"type\":\"string\"}},\"required\":[\"id\",\"name\",\"state\",\"lastChange\"],\"type\":\"object\",\"version\":0}. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","inputSchema":{"type":"object","properties":{"document":{"additionalProperties":false,"encrypted":[],"indexes":[["state","id"],["state","lastChange","id"],["id"]],"keyCompression":false,"primaryKey":"id","properties":{"id":{"maxLength":20,"type":"string"},"lastChange":{"maximum":2701307494132,"minimum":0,"multipleOf":1,"type":"number"},"name":{"type":"string"},"state":{"enum":["open","done"],"maxLength":10,"type":"string"}},"required":["id","name","state","lastChange"],"type":"object","version":0,"description":"The document to upsert."}},"required":["document"]},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"},{"name":"rxdb_delete_tpdp-17-2-0-853d7864c7_todos_0","kind":"transact","impl":"imperative","description":"Deletes a document by id from the RxDB collection 'todos' of database 'tpdp-17-2-0-853d7864c7'. The collection has the following JSON schema: {\"additionalProperties\":false,\"encrypted\":[],\"indexes\":[[\"state\",\"id\"],[\"state\",\"lastChange\",\"id\"],[\"id\"]],\"keyCompression\":false,\"primaryKey\":\"id\",\"properties\":{\"id\":{\"maxLength\":20,\"type\":\"string\"},\"lastChange\":{\"maximum\":2701307494132,\"minimum\":0,\"multipleOf\":1,\"type\":\"number\"},\"name\":{\"type\":\"string\"},\"state\":{\"enum\":[\"open\",\"done\"],\"maxLength\":10,\"type\":\"string\"}},\"required\":[\"id\",\"name\",\"state\",\"lastChange\"],\"type\":\"object\",\"version\":0}. Note: If this tool returns an error code, you can find the decoded error message at https://rxdb.info/errors.html","inputSchema":{"type":"object","properties":{"id":{"type":"string","description":"The primary key of the document to delete."}},"required":["id"]},"hasHandler":true,"hasExecute":true,"__source":"spec","executable":true,"handlerField":"execute","page":"/rxdb-quickstart/"}],"category":"Developer Tools","apiSurface":"spec","toolCount":7}}