S3DB - Simple and Sloppy Semantic Database
Inserting rules/resources/statements through the API works in a very similar way to querying them, except that XML tab "select" is replaced by "insert".
What you will need in order to use the API to insert rules/resources/statement is:
the URL where your S3DB is installed (if in you local computer, this would be something like http://localhost/s3db)
the key created through the interface
query file/string built in XML.
1. Build a query using the XML template:
<?xml version="1.0"?>
<S3QL>
<key>...</key>
<insert> ... </insert>
<where>
<project_id>...</project_id>
</where>
</S3QL>
2. Call the query using the URL + S3QL.php
Ex: http://localhost/s3db1.0/S3QL.php?query=<S3QL><key>sCIUdwfWY3ihujX</key></S3QL>
OR
Call the query from a remote location:
http://localhost/s3db1.0/S3QL.php?query=http://myserver/query.xml
3. Possible insert queries:
Insert |
Where (Required) |
Where (Optional) |
Syntax |
project |
project_name |
project_description |
|
collection |
project_id, name |
notes |
|
item |
class_id |
notes |
|
rule |
project_id, subject, verb, object |
notes |
|
statement |
resource_id, rule_id, value |
notes |
|
file |
resource_id, rule_id, filekey |
notes |
|
key |
key_id, expires |
notes |
|
Previous/Next/Table of Contents
Email: helenadeus@gmail.com, almeida.jonas@gmail.com
|