Created API Functions (markdown)
parent
c171de25ec
commit
a5c429ba4a
34
API-Functions.md
Normal file
34
API-Functions.md
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
# General
|
||||||
|
* all Read functions are executed with HTTP GET requests
|
||||||
|
* all Create functions are executed with HTTP POST requests
|
||||||
|
* all Update functions are executed with HTTP PUT requests
|
||||||
|
* all Delete functions are executed as HTTP DELETE requests
|
||||||
|
* Search functions are executed as a GET request with URL parameters.
|
||||||
|
* API functions that return data do so via json objects.
|
||||||
|
* API fucntions that accept data do so via json objects in the request body.
|
||||||
|
* API functions do not return a Success or error state, this information is passed by the HTTP Status Code.
|
||||||
|
|
||||||
|
# Syntax of this document
|
||||||
|
[(Implementation) Status] function(parameter, [optional parameter]) -> return values
|
||||||
|
|
||||||
|
# API Functions
|
||||||
|
## Domains
|
||||||
|
### Create
|
||||||
|
* [TODO] create(name, type) -> id
|
||||||
|
### Read
|
||||||
|
* [TODO] get(id) -> id, name, type
|
||||||
|
* [TO BE DISCUSSED] get_num_records(id) -> number of records in zone
|
||||||
|
### Update
|
||||||
|
* [TODO] set type(id, type)
|
||||||
|
### Delete
|
||||||
|
* [TODO] delete(id)
|
||||||
|
|
||||||
|
## Records
|
||||||
|
### Create
|
||||||
|
* [TODO] create(name, type, content, ttl, [priority])
|
||||||
|
### Read
|
||||||
|
* [TODO] get(id) -> type, content, ttl, [priority])
|
||||||
|
### Update
|
||||||
|
* [TODO] set(id, [content, ttl, priority])
|
||||||
|
### Delete
|
||||||
|
* [TODO] delete(id)
|
Loading…
Reference in a new issue