ASH.ResourceLibrary.WebApi

<back to all web services

TopicRequest

Requires Authentication
The following routes are available for this service:
GET/topics/{topicid}Use to get Resource Library Topic

export class BasicResourceLibraryRequest
{
    public resourceLibraryMemberId?: number;

    public constructor(init?: Partial<BasicResourceLibraryRequest>) { (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 ScreenshotItem
{
    public largeFilepathS3?: string;
    public thumbFilepathS3?: string;
    public order?: number;
    public description?: string;

    public constructor(init?: Partial<ScreenshotItem>) { (Object as any).assign(this, init); }
}

export class ResourceCard
{
    public id?: string;
    public title?: string;
    public description?: string;
    public descriptionSummary?: string;
    public type?: string;
    public content?: string;
    public isComplete?: boolean;
    public isFavorite?: boolean;
    public isImplicitlyComplete?: boolean;
    public mediaPath?: string;
    public isConfirmable?: boolean;
    public isWcagCompliant?: boolean;
    public duration?: string;
    public preview?: string;
    public calories?: number;
    public instructor?: string;
    public thumbnail?: string;
    public difficulty?: string;
    public tags?: Tag[];
    public subtitles?: string;
    public screenshots?: ScreenshotItem[];
    public drmEncrypted?: boolean;

    public constructor(init?: Partial<ResourceCard>) { (Object as any).assign(this, init); }
}

export class SubtopicLite
{
    public id?: string;
    public title?: string;
    public resourceCount?: number;
    public resourceItems?: ResourceCard[];

    public constructor(init?: Partial<SubtopicLite>) { (Object as any).assign(this, init); }
}

export class TopicLite
{
    public id?: string;
    public subtopicItems?: SubtopicLite[];
    public resourceItems?: ResourceCard[];
    public title?: string;
    public isVisible?: string;
    public resourceCount?: number;

    public constructor(init?: Partial<TopicLite>) { (Object as any).assign(this, init); }
}

export class TopicResponse
{
    public topic?: TopicLite;

    public constructor(init?: Partial<TopicResponse>) { (Object as any).assign(this, init); }
}

export class TopicRequest extends BasicResourceLibraryRequest
{
    public includeCompletionStatus?: boolean;
    public limit?: string;
    public offset?: string;
    public topicId?: string;
    public isMobile?: boolean;
    /**
    * Set it to true if the topic being requested belogs to digital fitness. Don't set it if unsure.
    */
    // @ApiMember(Description="Set it to true if the topic being requested belogs to digital fitness. Don't set it if unsure.")
    public digitalFitness?: boolean;

    public constructor(init?: Partial<TopicRequest>) { super(init); (Object as any).assign(this, init); }
}

TypeScript TopicRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /topics/{topicid} HTTP/1.1 
Host: resourcelibrary.api.ashcompanies.com 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<TopicResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ASH.ResourceLibrary.Interfaces.ServiceModels">
  <Topic xmlns:d2p1="http://schemas.datacontract.org/2004/07/ASH.ResourceLibrary.Interfaces.Models">
    <d2p1:Id>String</d2p1:Id>
    <d2p1:IsVisible>String</d2p1:IsVisible>
    <d2p1:ResourceCount>0</d2p1:ResourceCount>
    <d2p1:ResourceItems i:nil="true" />
    <d2p1:SubtopicItems i:nil="true" />
    <d2p1:Title>String</d2p1:Title>
  </Topic>
</TopicResponse>