Get a cover from OPDS
GET
/opds/v2/publications/{publicationId}/cover
const url = 'http://localhost:8080/opds/v2/publications/1/cover';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url http://localhost:8080/opds/v2/publications/1/cover \ --header 'Authorization: Bearer <token>'The same as /api/v1/publications/{publicationId}/cover, with an OPDS sign-in challenge on 401.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”publicationId
required
integer format: int64
Responses
Section titled “Responses”A JPEG thumbnail.
Media typeimage/jpeg
string format: binary
The client’s copy is current.
No valid credentials. The Basic challenge and the Authentication for OPDS document both ask for a name and password.
Media typeapplication/opds-authentication+json
An Authentication for OPDS document offering HTTP Basic sign-in.
object
id
required
string format: uri
title
required
string
authentication
required
Array<object>
object
type
required
string
labels
object
login
string
password
string
Example
{ "authentication": [ { "type": "http://opds-spec.org/auth/basic" } ]}Headers
Section titled “Headers”WWW-Authenticate
string
Example
Basic realm="Chek", charset="UTF-8"Link
string
Example
<https://chek.example/opds/v2/auth>; rel="http://opds-spec.org/auth/document"; type="application/opds-authentication+json"The resource does not exist.
Media typeapplication/json
object
code
required
string
message
required
Explains the problem to a developer.
string
Example
{ "code": "bad_request"}The server failed; details are in its log.
Media typeapplication/json
object
code
required
string
message
required
Explains the problem to a developer.
string
Example
{ "code": "bad_request"}