API Reference - VisionSystemsInc/voxel_globe GitHub Wiki
Complete API reference materials for the VoxelGlobe platform
API Endpoints
Click the name to see full reference material for the API endpoint.
API Endpoint | Description |
---|---|
/user/ | User Information API |
/meta/rest/auto/ | RESTful API for database |
API Reference
meta/rest/auto/
Type | URL | Description | Content Type | Response |
---|---|---|---|---|
GET | /meta/rest/auto/ | API Root | Lists other endpoints | |
HEAD | /meta/rest/auto/ | ? | ? | |
GET | /meta/rest/auto/{type}/ | Get list of all entries | JSON of all objects | |
POST | /meta/rest/auto/{type}/ | Create a new entry | application/jsonmultipart/form-dataapplication/X-www-form-urlencoded | |
GET | /meta/rest/auto/{type}/{id}/ | Gets a single entry | JSON of object | |
PATCH | /meta/rest/auto/{type}/{id}/ | Update a single entry | application/jsonmultipart/form-dataapplication/X-www-form-urlencoded | |
PUT | /meta/rest/auto/{type}/{id}/ | Sets a single entry (all fields must be set, or else defaults are used) | application/jsonmultipart/form-dataapplication/X-www-form-urlencoded | |
DELETE | /meta/rest/auto/{type}/{id}/ | Delete a single entry | ||
GET | /meta/rest/auto/{type}/{id}/{many_to_many_field}/ | List all m2m objects | JSON objects | |
POST | /meta/rest/auto/{type}/{id}/{many_to_many_field}/ | Add an entry to the m2m list | ||
GET | /meta/rest/auto/{type}/{id}/{many_to_many_field}/{m2m_id}/ | Gets the specific entry | JSON objects | |
DELETE | /meta/rest/auto/{type}/{id}/{many_to_many_field}/{m2m_id}/ | Removes an entry from the m2m list | JSON objects | |
OPTIONS | /meta/rest/auto/*** | All endpoints take an Options request | see here for more info |
Specifying DRF Content Type
Just add the GET/POST parameter format
Format key | Format | Content Type |
---|---|---|
json |
JSON object | application/json |
api |
Pretty HTML output | test/html |
See here for default render explanation
Filtering
The django-filter and OrderingFilter are installed and configured
Pagination
Pagination is turned on (without limits currently) and uses the param page_size
user/
Type | URL | Description | Content-Type | Response |
---|---|---|---|---|
GET | /user/ | Gets the entire user configuration | 1 | |
POST | /user/ | Sets (and overrides) the entire user information | application/jsonmultipart/form-dataapplication/X-www-form-urlencoded | 2 |
GET | /user/{key} | Gets the value of a single piece of user information | 1 | |
POST | /user/{key} | Sets the value of a single piece of user information | application/json | 2 |
Response
1
Content: JSON string representing value. null if not found.
2
Empty json object