Rest API methods

The following methods are implemented.

test

Returns you a test success message

Variables you need to supply

Variable nameValue
--

testException

Returns you a test exception.

Variables you need to supply

Variable nameValue
--

getServices

Returns a list of service

Datanodes returned

NameTypeSubtypeValue
site_{number}dataset Contains a dataset node that contains the properties for each site
site_{number}→hostname StringContains the hostname
site_{number}→enabled StringIf the site is online this is “yes”
site_{number}→apienabled Stringif the api is enabled this is “yes”
site_{number}→restricted Stringif the site is restricted to only certain apikeys this is “yes”

signIn

This method is used to create a session.

Variables you need to supply

Variable nameValue
username the username of the user
password an md5 hash of the password of the user

Datanodes returned

NameValue
sessionid a string of the user's sessionid

signOut

This method signs the user out

Variables you need to supply

Variable nameValue
sessionid a valid sessionid

checkSession

for checking if the session is still OK

Variables you need to supply

Variable nameValue
sessionid a valid sessionid

addUrl

Adds a url

Variables you need to supply

Variable nameValue
sessionid a valid sessionid
url a valid url
adult 'yes' or 'no' if the url is a NSFW link
passwordOptional,supply this if a password should be added
descriptionOptional,a description for the url
tagsOptional,Comma seperated tags
donotrecycleOptional,'yes' if you need an absolute new url…
testmode If you want to test if everything is alright but don't want to keep adding urls set this to 'yes'

Datanodes returned

NameValue
url the new url
urlid just the urlid (base36)
 
api/rest/methods.txt · Last modified: 2011/10/15 19:11 (external edit)
 
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki