Skip to content
Mateusz Bruno-Kamiński edited this page Apr 20, 2014 · 9 revisions

Webservice operations

There are several operations under development. They are accessible by sending a HTTP request to:

http://ocean-coral.no-ip.biz:14/<operation_path>

All these operations take a json object as a parameter which travels in a HTTP request body message.


The methods returns (in a HTTP response) a serialised object:

{ key1: value1, key2: value2 }

The whole communication begins when a client requests a handshake. It may be performed by a special operation:

handshake

Parameter contains keys:

  • client_key string

Returned value: object

Returned value contains keys:

  • coral_key string
  • client_id string

When keys are successfully exchanged and a client ID is assigned, then a client service is eligible to perform other requests:

sign_in

Parameter contains keys:

  • username string
  • password string
  • client_id string

Returned value: object

Returned value contains keys:

  • status bool

sign_out

Parameter contains keys:

  • client_id string

Returned value: object

Returned value contains keys:

  • status bool

get_article_list

Parameter contains keys:

  • last_news_id string
  • count int
  • feed_id string
  • client_id string

Returned value: object

Returned value contains keys:

  • article_list list[object]

Each element of article_list contains keys:

  • article_id string
  • author string
  • title string
  • time int
  • description string
  • image_source string

get_article_details

Parameter contains keys:

  • article_id string
  • client_id string

Returned value: object

Returned value contains keys:

  • article_id string
  • body string

get_feed_list

Parameter contains keys:

  • client_id string

Returned value: object

Returned value contains keys:

  • feed_list list[object]

Each element of feed_list contains keys:

  • link string
  • title string

create_feed

Parameter contains keys:

  • feed_tags list[string]
  • client_id string

Returned value: object

Returned value contains keys:

  • status bool

Clone this wiki locally