| GET | /v1/links/list |
|---|
import java.math.*
import java.util.*
import java.io.InputStream
import net.servicestack.client.*
import com.google.gson.annotations.*
import com.google.gson.reflect.*
@DataContract
open class GetLinksRequest : PaginatedBaseRequest()
{
@DataMember(Name="ids")
@SerializedName("ids")
open var ids:ArrayList<String>? = null
}
@DataContract
open class PaginatedBaseRequest
{
@DataMember(Name="skip")
@SerializedName("skip")
open var skip:Int? = null
@DataMember(Name="take")
@SerializedName("take")
open var take:Int? = null
}
@DataContract
open class GetLinksResponse
{
@DataMember(Name="allLinksLoaded")
@SerializedName("allLinksLoaded")
open var allLinksLoaded:Boolean? = null
@DataMember(Name="results")
@SerializedName("results")
open var results:ArrayList<LinkResult>? = null
@DataMember(Name="responseStatus")
@SerializedName("responseStatus")
open var responseStatus:ResponseStatus? = null
}
@DataContract
open class LinkResult
{
@DataMember(Name="baseCode")
@SerializedName("baseCode")
open var baseCode:String? = null
@DataMember(Name="url")
@SerializedName("url")
open var url:String? = null
@DataMember(Name="originalUrl")
@SerializedName("originalUrl")
open var originalUrl:String? = null
@DataMember(Name="imageUrl")
@SerializedName("imageUrl")
open var imageUrl:String? = null
@DataMember(Name="retailer")
@SerializedName("retailer")
open var retailer:String? = null
@DataMember(Name="title")
@SerializedName("title")
open var title:String? = null
@DataMember(Name="author")
@SerializedName("author")
open var author:String? = null
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /v1/links/list HTTP/1.1 Host: api.booklinker.com Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"allLinksLoaded":false,"results":[{"baseCode":"String","url":"String","originalUrl":"String","imageUrl":"String","retailer":"String","title":"String","author":"String"}],"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}