Cochrane+ App API

<back to all web services

GetDashboardInfo

Requires Authentication
The following routes are available for this service:
GET/dashboard/info

export class ApiServiceRequest implements IServiceRequest, IHasApiKey, IHasDeviceInfo
{
    /** @description The API Key required for authentication */
    // @ApiMember(DataType="string", Description="The API Key required for authentication", IsRequired=true)
    public apiKey: string;

    /** @description Latitude of the user making this request */
    // @ApiMember(DataType="double", Description="Latitude of the user making this request")
    public latitude: number;

    /** @description Longitude of the user making this request */
    // @ApiMember(DataType="double", Description="Longitude of the user making this request")
    public longitude: number;

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

export class ApiServiceResponse implements IServiceResponse
{
    public description: string;
    public heading: string;
    public wasSuccessful: boolean;
    public modelState: Object;

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

export class MeetingData
{
    public meetingId: number;
    public startTime: string;
    public arrivalTime: string;
    public leftTime: string;
    public duration: string;
    public showTimeFields: boolean;
    public arrivalStatus: string;
    public email: string;
    public hasEmail: boolean;
    public contactName: string;
    public latitude: number;
    public longitude: number;
    public location: string;
    public address: string;
    public subject: string;
    public description: string;
    public endTime: string;
    public company: string;
    public contactNumber: string;
    public hasContactNumber: boolean;
    public hasLocation: boolean;
    public setBy: string;
    public virtualOrInPerson: string;

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

export enum AttendanceEventType
{
    ClockOut = 0,
    ClockIn = 1,
    StartLunch = 2,
    EndLunch = 3,
    StartBreak = 4,
    EndBreak = 5,
}

export class GetDashboardInfoResponse extends ApiServiceResponse
{
    public unreadNotificationCount: number;
    public nextMeetingDate: string;
    public totalMeetingsToday: number;
    public outstandingRatingsCount: number;
    public usersAverageRating: number;
    public hasSharedRatings: boolean;
    public isSalesPerson: boolean;
    public usersRatingTotalVotes: number;
    public usersRatingPosition: number;
    public teamIds: number[];
    public nextMeeting: MeetingData;
    public attendanceEventType: AttendanceEventType;
    public outstandingDebriefsToReviewCount: number;
    public outstandingTemplateApprovalsCount: number;

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

export class GetDashboardInfo extends ApiServiceRequest
{

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

TypeScript GetDashboardInfo 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

HTTP + JSON

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

GET /dashboard/info HTTP/1.1 
Host: cochraneplus-api-dev.happen.zone 
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"unreadNotificationCount":0,"nextMeetingDate":"String","totalMeetingsToday":0,"outstandingRatingsCount":0,"usersAverageRating":0,"hasSharedRatings":false,"isSalesPerson":false,"usersRatingTotalVotes":0,"usersRatingPosition":0,"teamIds":[0],"nextMeeting":{"meetingId":0,"startTime":"String","arrivalTime":"String","leftTime":"String","duration":"String","showTimeFields":false,"arrivalStatus":"String","email":"String","hasEmail":true,"contactName":"String","latitude":0,"longitude":0,"location":"String","address":"String","subject":"String","description":"String","endTime":"String","company":"String","contactNumber":"String","hasContactNumber":true,"hasLocation":false,"setBy":"String","virtualOrInPerson":"String"},"attendanceEventType":0,"outstandingDebriefsToReviewCount":0,"outstandingTemplateApprovalsCount":0,"description":"String","heading":"String","wasSuccessful":false,"modelState":{}}