GET | /searchResults | Use to search Resource Items |
---|
import java.math.*
import java.util.*
import net.servicestack.client.*
import com.google.gson.annotations.*
import com.google.gson.reflect.*
open class ResourceItemSearchRequest : BasicResourceLibraryRequest()
{
var request:String? = null
var tags:ArrayList<String> = ArrayList<String>()
var categoryId:String? = null
var offset:Int? = null
var limit:Int? = null
var digitalFitness:Boolean? = null
}
open class BasicResourceLibraryRequest
{
var resourceLibraryMemberId:Int? = null
}
open class ResourceItemSearchResponse
{
var searchResults:SearchResult? = null
}
open class SearchResult
{
var id:String? = null
var resourceItems:ArrayList<ResourceItemForSearch> = ArrayList<ResourceItemForSearch>()
var searchItems:ArrayList<ResourceItemForSearch> = ArrayList<ResourceItemForSearch>()
var tags:ArrayList<Tag> = ArrayList<Tag>()
var itemCount:Long? = null
}
open class ResourceItemForSearch
{
var id:String? = null
@SerializedName("type") var Type:String? = null
var categories:ArrayList<String> = ArrayList<String>()
var categoryIndexes:ArrayList<String> = ArrayList<String>()
var title:String? = null
var description:String? = null
var descriptionSummary:String? = null
var content:String? = null
var tags:ArrayList<String> = ArrayList<String>()
var isComplete:Boolean? = null
var isFavorite:Boolean? = null
var isImplicitlyComplete:Boolean? = null
var transcript:String? = null
var thumbnail:String? = null
var difficulty:String? = null
var duration:String? = null
var mediaPath:String? = null
}
open class Tag
{
var id:String? = null
var title:String? = null
}
Kotlin ResourceItemSearchRequest DTOs
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 /searchResults HTTP/1.1 Host: resourcelibrary.api.ashcompanies.com Accept: application/json
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"searchResults":{"id":"String","resourceItems":[{"id":"String","type":"String","categories":["String"],"categoryIndexes":["String"],"title":"String","description":"String","descriptionSummary":"String","content":"String","tags":["String"],"isComplete":false,"isFavorite":false,"isImplicitlyComplete":false,"transcript":"String","thumbnail":"String","difficulty":"String","duration":"String","mediaPath":"String"}],"searchItems":[{"id":"String","type":"String","categories":["String"],"categoryIndexes":["String"],"title":"String","description":"String","descriptionSummary":"String","content":"String","tags":["String"],"isComplete":false,"isFavorite":false,"isImplicitlyComplete":false,"transcript":"String","thumbnail":"String","difficulty":"String","duration":"String","mediaPath":"String"}],"tags":[{"id":"String","title":"String"}],"itemCount":0}}