GET | /searchResults | Use to search Resource Items |
---|
export class BasicResourceLibraryRequest
{
public resourceLibraryMemberId?: number;
public constructor(init?: Partial<BasicResourceLibraryRequest>) { (Object as any).assign(this, init); }
}
export class ResourceItemSearchRequest extends BasicResourceLibraryRequest
{
public request?: string;
public tags?: string[];
public categoryId?: string;
public offset?: number;
public limit?: number;
public digitalFitness?: boolean;
public constructor(init?: Partial<ResourceItemSearchRequest>) { super(init); (Object as any).assign(this, init); }
}
export class ResourceItemForSearch
{
public id?: string;
public type?: string;
public categories?: string[];
public categoryIndexes?: string[];
public title?: string;
public description?: string;
public descriptionSummary?: string;
public content?: string;
public tags?: string[];
public isComplete?: boolean;
public isFavorite?: boolean;
public isImplicitlyComplete?: boolean;
public transcript?: string;
public thumbnail?: string;
public difficulty?: string;
public duration?: string;
public mediaPath?: string;
public constructor(init?: Partial<ResourceItemForSearch>) { (Object as any).assign(this, init); }
}
export class Tag
{
public id?: string;
public title?: string;
public constructor(init?: Partial<Tag>) { (Object as any).assign(this, init); }
}
export class SearchResult
{
public id?: string;
public resourceItems?: ResourceItemForSearch[];
public searchItems?: ResourceItemForSearch[];
public tags?: Tag[];
public itemCount?: number;
public constructor(init?: Partial<SearchResult>) { (Object as any).assign(this, init); }
}
export class ResourceItemSearchResponse
{
public searchResults?: SearchResult;
public constructor(init?: Partial<ResourceItemSearchResponse>) { (Object as any).assign(this, init); }
}
TypeScript ResourceItemSearchRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
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: text/csv
HTTP/1.1 200 OK Content-Type: text/csv 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}}