E-Democracy Pages Wiki

Search Wiki

 

Tools

 

Difference between revisions of "GroupServer API"

From E-Democracy.org

Line 3: Line 3:
 
There is a [https://redmine.iopen.net/issues/262 5 year old ticket] on this.
 
There is a [https://redmine.iopen.net/issues/262 5 year old ticket] on this.
  
Ideally, a RESTFUL API would exist that lets developers pull:
+
=GET=
  
* Group listings
+
Ideally, a RESTFUL API would exist that lets developers pull the following.
* Topics in a group
+
* Posts in a group
+
* Posts in a topic
+
* User profiles
+
  
and push:
+
==Groups==
 +
 
 +
A group object should be accessible by a group id and should include:
 +
 
 +
* The group's '''name'''
 +
* The group's '''url'''
 +
* The group's '''policy'''
 +
* A reference to a list of the group's '''members'''
 +
* A reference to the group's '''administrators''', '''moderators''', and '''coach'''
 +
* A reference to a list of the group's '''topics'''
 +
* A reference to a list of the group's '''posts'''
 +
 
 +
A '''list''' of references to publicly visible groups should also be available.
 +
 
 +
==Topics==
 +
 
 +
A topic object should be accessible by one of its post's ids and should include:
 +
 
 +
* A '''url''' to the topic's page
 +
* The '''subject''' of the topic
 +
* A reference to a list of '''posts''' in the topic
 +
* A list of the '''keywords''' of the topic
 +
* A reference to the '''group''' that the topic is in
 +
 
 +
A '''list''' of references to publicly visible topics should also be available. There should be the option to specify a group-id to as to retrieve a list of topics of a specific group.
 +
 
 +
A note about topic/post ids. To my knowledge, there is no canonical id for a given topic. Instead, a topic can be accessed via the id of any post that is found in that topic.
 +
 
 +
==Posts==
 +
 
 +
A post object should be accessible by its ID and should include:
 +
 
 +
* A '''url''' to the post's page
 +
* A reference to the '''topic''' that the post is a part of
 +
* A reference to the '''author''' of the post
 +
* The '''datetime''' of the post
 +
* The '''body''' of the post
 +
* A list of the '''keywords''' of the post
 +
* A list of references to '''files''' attached to the post.
 +
 
 +
A '''list''' of references to publicly visible posts should also be available. There should be the option to specify a group-id to as to retrieve a list of posts of a specific group. There should also be the option to retrieve a list of posts for the topic that the post is a part of.
 +
 
 +
==Users==
 +
 
 +
A user object should be accessible by the user's id and nickname, and should include:
 +
 
 +
* A url to the user's '''profile page'''
 +
* The '''first''', '''last''', and '''full name''' of the user
 +
* A url to the user's '''avatar'''
 +
* A list of references to '''groups''' that the user is a member of
 +
* A list of references to '''posts''' that the user has made
 +
 
 +
==Pagination==
 +
 
 +
Any of the list retrieval methods should limit the number of results returned, and allow requests to be made for a specific number of results, specific indices, and offsets. Where it makes sense, a request should also be able to specify an order by parameter.
 +
 
 +
=Authenticate=
 +
 
 +
The API will provide authentication and provide content based on the authenticated status of the user.
 +
 
 +
=PUT=
  
 
* New topics
 
* New topics
 
* New posts
 
* New posts
 
* Changes to user profiles
 
* Changes to user profiles
 
The API will provide authentication and provide content based on the authenticated status of the user.
 
  
 
[[Category:Technology:Project Ideas]][[Category:Technology:Project Ideas:GroupServer]][[Category:Technology:Project Ideas:Python]]
 
[[Category:Technology:Project Ideas]][[Category:Technology:Project Ideas:GroupServer]][[Category:Technology:Project Ideas:Python]]

Revision as of 09:52, 14 March 2013

GroupServer does not have an API. That should be changed.

There is a 5 year old ticket on this.

GET

Ideally, a RESTFUL API would exist that lets developers pull the following.

Groups

A group object should be accessible by a group id and should include:

  • The group's name
  • The group's url
  • The group's policy
  • A reference to a list of the group's members
  • A reference to the group's administrators, moderators, and coach
  • A reference to a list of the group's topics
  • A reference to a list of the group's posts

A list of references to publicly visible groups should also be available.

Topics

A topic object should be accessible by one of its post's ids and should include:

  • A url to the topic's page
  • The subject of the topic
  • A reference to a list of posts in the topic
  • A list of the keywords of the topic
  • A reference to the group that the topic is in

A list of references to publicly visible topics should also be available. There should be the option to specify a group-id to as to retrieve a list of topics of a specific group.

A note about topic/post ids. To my knowledge, there is no canonical id for a given topic. Instead, a topic can be accessed via the id of any post that is found in that topic.

Posts

A post object should be accessible by its ID and should include:

  • A url to the post's page
  • A reference to the topic that the post is a part of
  • A reference to the author of the post
  • The datetime of the post
  • The body of the post
  • A list of the keywords of the post
  • A list of references to files attached to the post.

A list of references to publicly visible posts should also be available. There should be the option to specify a group-id to as to retrieve a list of posts of a specific group. There should also be the option to retrieve a list of posts for the topic that the post is a part of.

Users

A user object should be accessible by the user's id and nickname, and should include:

  • A url to the user's profile page
  • The first, last, and full name of the user
  • A url to the user's avatar
  • A list of references to groups that the user is a member of
  • A list of references to posts that the user has made

Pagination

Any of the list retrieval methods should limit the number of results returned, and allow requests to be made for a specific number of results, specific indices, and offsets. Where it makes sense, a request should also be able to specify an order by parameter.

Authenticate

The API will provide authentication and provide content based on the authenticated status of the user.

PUT

  • New topics
  • New posts
  • Changes to user profiles
 

Home - Mobile - Forums - Wiki - Blog - About - Help - Contact - People - Donate - Rules - Archives