-
Notifications
You must be signed in to change notification settings - Fork 4
III.2.g. Other
/api/fileHeaders.json?url=<url>
Returns an object map of header names and values retrieved with a HEAD request to the specified URL.
Example:
/api/fileHeaders.json?url=http://i.playground.ru/i/89/48/62/10/pix/image.jpg
{
"server": "nginx/1.6.1",
"date": "Thu, 25 Feb 2016 15:21:02 GMT",
"content-type": "image/jpeg",
"content-length": "245195",
"last-modified": "Thu, 23 Jul 2015 11:36:51 GMT",
"etag": "\"55b0d1d3-3bdcb\"",
"expires": "Sat, 26 Mar 2016 15:21:02 GMT",
"cache-control": "max-age=2592000",
"accept-ranges": "bytes",
"x-cache": "MISS from localhost",
"x-cache-lookup": "MISS from localhost:3128",
"via": "1.0 localhost (squid/3.1.19)",
"connection": "close"
}
Note: normally, the server should use a proxy to hide it's IP, so some headers may be proxy-related.
On any error, an error object.
Example:
/api/fileHeaders.json?url=http://i.playground.ru/i/89/48/62/10/pix/image.jpeg
{
"title": "Error",
"errorMessage": "Error",
"errorDescription": "Failed to get file headers"
}
/api/chatMessages.json[?lastRequestDate=<date>]
Returns an object containing chats and last request date in ISO format. The lastRequestDate
parameter may be specified in ISO date format. If so, only the messages added later than that date will be included in the reply.
Note: A combination of board name and post number is used to identify a chat, so no user data is revealed.
Note 2: By default, a chat is deleted if there are no new messages within 7 days (the TTL may be changed using the configuration file).
Example:
/api/chatMessages.json
{
"lastRequestDate": "2016-02-25T15:23:58.259Z",
"chats": {
"a:225": [
{
"text": "Hi!",
"date": "2016-02-22T06:33:08.084Z",
"type": "out"
},
{
"text": "Hello!",
"date": "2016-02-22T06:34:25.504Z",
"type": "in"
}
]
}
}
On any error, an error object is returned.
/api/synchronization.json?key=<key>
Returns an object containing user synchronization data (browser localStorage and cookies content).
If the key does not exist, null
is returned.
On any error, an error object is returned.
Example:
/api/synchronization.json
{
"title": "Error",
"errorMessage": "Error",
"errorDescription": "No key specified"
}