REST interface for the social networking library (posts).
| name | type | description |
|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources |
| Content-Type | header | application/json |
| code | condition |
|---|---|
| 201 | Sccessfull retrieved ids, they are reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-id-liked-posts
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 201 Created
Content-Type: application/json
...
| name | type | description | default | constraints |
|---|---|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources | ||
| Content-Type | header | application/json | ||
| limit | query | 10 | min: 0 |
| code | condition |
|---|---|
| 200 | Successfull retrieved posts, they are reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-liked-posts
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 200 OK
Content-Type: application/json
...
| name | type | description |
|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources |
| Content-Type | header | application/json |
| code | condition |
|---|---|
| 200 | Successfull created, the new post is reported in the 'result' field of the returned object |
| 403 | "There is no application profile with such token |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-posts-app
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 200 OK
Content-Type: application/json
...
| name | type | description | constraints |
|---|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources | |
| Content-Type | header | application/json | |
| hashtag | query | required |
| code | condition |
|---|---|
| 201 | Sccessfull retrieved posts, they are reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-posts-by-hashtag
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 201 Created
Content-Type: application/json
...
| name | type | description |
|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources |
| Content-Type | header | application/json |
| code | condition |
|---|---|
| 200 | Successful retrieval of posts, reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-posts-user
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 200 OK
Content-Type: application/json
...
| name | type | description | default | constraints |
|---|---|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources | ||
| Content-Type | header | application/json | ||
| quantity | query | 10 | min: 0 |
| code | condition |
|---|---|
| 200 | Successful retrieval of posts, reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-posts-user-quantity
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 200 OK
Content-Type: application/json
...
| name | type | description | constraints |
|---|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources | |
| Content-Type | header | application/json | |
| time | query | required long, min: 0 |
| code | condition |
|---|---|
| 200 | Successful retrieval of posts, reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-posts-user-since
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 200 OK
Content-Type: application/json
...
| name | type | description |
|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources |
| Content-Type | header | application/json |
| code | condition |
|---|---|
| 201 | Sccessfull retrieved posts, they are reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
GET /2/posts/get-posts-vre
Content-Type: */*
Accept: application/json
Authorization: ...
...
HTTP/1.1 201 Created
Content-Type: application/json
...
| name | type | description |
|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources |
| Content-Type | header | application/json |
| media type | data type |
|---|---|
| application/json | PostInputBean (JSON) |
| code | condition |
|---|---|
| 200 | Successfull created, the new post is reported in the 'result' field of the returned object |
| 403 | "There is no application profile with such token |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
POST /2/posts/write-post-app
Content-Type: application/json
Accept: application/json
Authorization: ...
{
"text" : "Dear vre members, ...",
"preview_description" : "...",
"preview_host" : "...",
"preview_url" : "...",
"image_url" : "...",
"enable_notification" : true,
"params" : "...",
"previewtitle" : "..."
}
HTTP/1.1 200 OK
Content-Type: application/json
...
| name | type | description |
|---|---|---|
| Authorization | header | Bearer token, see https://dev.d4science.org/how-to-access-resources |
| Content-Type | header | application/json |
| media type | data type |
|---|---|
| application/json | PostInputBean (JSON) |
| code | condition |
|---|---|
| 201 | Successfull created, the new post is reported in the 'result' field of the returned object |
| 500 | The error is reported into the 'message' field of the returned object |
| media type | data type | description |
|---|---|---|
| application/json | object (JSON) |
POST /2/posts/write-post-user
Content-Type: application/json
Accept: application/json
Authorization: ...
{
"text" : "Dear vre members, ...",
"preview_description" : "...",
"preview_host" : "...",
"preview_url" : "...",
"image_url" : "...",
"enable_notification" : true,
"params" : "...",
"previewtitle" : "..."
}
HTTP/1.1 201 Created
Content-Type: application/json
...