Conferences¶
-
httpkom.conferences.
conferences_get
(conf_no)¶ Get information about a specific conference.
Query parameters:
Key
Type
Values
micro
boolean
- true
(Default) Return micro conference information (UConference) which causes less load on the server.
- false
Return full conference information.
Request
GET /<server_id>/conferences/14506 HTTP/1.1
Responses
With micro=true:
HTTP/1.0 200 OK { "highest_local_no": 1996, "nice": 77, "type": { "forbid_secret": 0, "allow_anonymous": 1, "rd_prot": 1, "secret": 0, "letterbox": 1, "original": 0, "reserved3": 0, "reserved2": 0 }, "name": "Oskars Testperson", "conf_no": 14506 }
With micro=false:
HTTP/1.0 200 OK { "super_conf": { "conf_name": "", "conf_no": 0 }, "creator": { "pers_no": 14506, "pers_name": "Oskars Testperson" }, "no_of_texts": 1977, "no_of_members": 1, "creation_time": "2013-11-30T15:58:06Z", "permitted_submitters": { "conf_name": "", "conf_no": 0 }, "conf_no": 14506, "last_written": "2013-11-30T15:58:06Z", "keep_commented": 77, "name": "Oskars Testperson", "type": { "forbid_secret": 0, "allow_anonymous": 1, "rd_prot": 1, "secret": 0, "letterbox": 1, "original": 0, "reserved3": 0, "reserved2": 0 }, "first_local_no": 20, "expire": 0, "msg_of_day": 0, "supervisor": { "conf_name": "Oskars Testperson", "conf_no": 14506 }, "presentation": 0, "nice": 77 }
Conference does not exist:
HTTP/1.0 404 NOT FOUND { TODO: error stuff }
Example
curl -v -X GET "http://localhost:5001/lyskom/conferences/14506?micro=true"
-
httpkom.conferences.
conferences_get_texts
(conf_no)¶ Get the last created texts in the conference. Returns all text stats, but not the subject or body.
TODO: Query parameters for pagination.
Query parameters:
Key
Type
Values
no-of-texts
integer
Number of text numbers to return. Default: 10
Request
GET /<server_id>/conferences/texts/ HTTP/1.0
Response
HTTP/1.0 200 OK { "texts": [ { "recipient_list": [ { "conf_name": "Oskars Testperson", "type": "to", "loc_no": 29, "conf_no": 14506 } ], "author": { "pers_no": 14506, "pers_name": "Oskars Testperson" }, "creation_time": "2013-11-30T15:58:06Z", "comment_in_list": [], "content_type": "text/x-kom-basic", "text_no": 19680717, "comment_to_list": [], }, ... ] }
Example
curl -v -X GET -H "Content-Type: application/json" \ "http://localhost:5001/lyskom/conferences/texts/?no-of-texts=3"
-
httpkom.conferences.
conferences_list
()¶ Lookup conference names.
Query parameters:
Key
Type
Values
name
string
Name to look up according to KOM conventions.
want-pers
boolean
- true
(Default) Include conferences that are mailboxes.
- false
Do not include conferences that are mailboxes.
want-confs
boolean
- true
(Default) Include conferences that are not mailboxes.
- false
Do not include conferences that are not mailboxes.
Request
GET /<server_id>/conferences/?name=osk%20t&want-confs=false HTTP/1.0
Response
HTTP/1.0 200 OK { "conferences": [ { "conf_name": "Oskars tredje person", "conf_no": 13212 }, { "conf_name": "Oskars Testperson", "conf_no": 14506 } ] }
Example
curl -v -X GET -H "Content-Type: application/json" \ "http://localhost:5001/lyskom/conferences/?name=osk%20t&want-confs=false"
-
httpkom.conferences.
conferences_put_text_read_marking
(conf_no, local_text_no)¶ Mark text as read in the specified recipient conference (only).
Request
PUT /<server_id>/conferences/14506/texts/29/read-marking HTTP/1.1
Response
HTTP/1.1 201 Created
Example
curl -v -X PUT "http://localhost:5001/lyskom/conferences/14506/texts/29/read-marking"