Line 3: |
Line 3: |
| == Overview == | | == Overview == |
| | | |
− | The API operates with [[#Resources|resources]] that are collections of objects. All objects are identified by global unique identifiers, GUIDs. Resources might support [[#Common_actions|common actions]]. While processing requests, server might generate [[#events|events]]. There are [[#Common_events|common events]] that all resources might generate. | + | The API operates with [[#Resources|resources]] that are collections of objects. All objects are identified by global unique identifiers, GUIDs. Resources might support [[#Aactions|common actions]]. While processing requests, server might generate [[#events|events]]. There are [[#Events|common events]] that all resources might generate. |
| | | |
| The API is [[Wikipedia:Restful|RESTful]] and being served via HTTP(S) using [[Wikipedia:Json|JSON]] notation. The common RESTful request url format is: | | The API is [[Wikipedia:Restful|RESTful]] and being served via HTTP(S) using [[Wikipedia:Json|JSON]] notation. The common RESTful request url format is: |
Line 27: |
Line 27: |
| * The ''AUTH-TOKEN'' is the {{Code|uid}} which is a hashed value from Sugar profile public SSH key (the same as JID value in Sugar Shell but without the domain part) that does not require any handshake procedures. | | * The ''AUTH-TOKEN'' is the {{Code|uid}} which is a hashed value from Sugar profile public SSH key (the same as JID value in Sugar Shell but without the domain part) that does not require any handshake procedures. |
| | | |
− | === Common properties === | + | == Commons == |
| + | |
| + | === Properties === |
| | | |
| All resources have the following properties: | | All resources have the following properties: |
Line 43: |
Line 45: |
| * {{Code|vote}}, ''bool'', ''read'', ''write''<br>did url requester voted for the current object or not. | | * {{Code|vote}}, ''bool'', ''read'', ''write''<br>did url requester voted for the current object or not. |
| | | |
− | === Common actions === | + | === Actions === |
| | | |
| Actions might be restricted for particular resource, see the corresponding section for detailed information. | | Actions might be restricted for particular resource, see the corresponding section for detailed information. |
Line 123: |
Line 125: |
| : {{Code|type: update}} | | : {{Code|type: update}} |
| | | |
− | === Common events === | + | === Events === |
| | | |
| All events have the following common properties: | | All events have the following common properties: |
Line 318: |
Line 320: |
| Actions: | | Actions: |
| | | |
− | : Only read-only [[#Common_actions|common]] actions. | + | : Only read-only [[#Actions|common]] actions. |
| | | |
| PUT /report/<GUID>/'''logs''' | | PUT /report/<GUID>/'''logs''' |
Line 358: |
Line 360: |
| | | |
| Properties: | | Properties: |
− | : No specific properties except the [[#Common_events|common]] ones. | + | : No specific properties except the [[#Events|common]] ones. |
| | | |
| Actions: | | Actions: |
− | : Only read-only [[#Common_actions|common]] actions. | + | : Only read-only [[#Actions|common]] actions. |
| | | |
| == Changelog == | | == Changelog == |