GET | /scheduling/class-schedule | Get Class Schedule | Specify ToDate/FromDate (max 7 days) to get a list of classes within a date range. Omitting dates will retrieve classes for today. |
---|---|---|---|
GET | /v2/{Apikey}/club/{StoreID}/classschedule | (obsolete) Get Class Schedule | Specify ToDate/FromDate (max 7 days) to get a list of classes within a date range. Omitting dates will retrieve classes for today. |
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using ClubReady.Web.Api.Scheduling.Model;
using ClubReady.Core.Api.Models;
using ClubReady.Web.Api;
namespace ClubReady.Core.Api.Models
{
public partial class ApiDtoBase
{
public virtual string ApiKey { get; set; }
public virtual int? StoreId { get; set; }
public virtual int? ChainId { get; set; }
}
public partial class GetClassScheduleRequestDto
: ApiDtoBase
{
public virtual DateTime? FromDate { get; set; }
public virtual DateTime? ToDate { get; set; }
public virtual int? FilterByCategoryId { get; set; }
}
}
namespace ClubReady.Web.Api
{
public enum RestrictedResourceType
{
Store,
Chain,
User,
Undefined,
}
}
namespace ClubReady.Web.Api.Scheduling.Model
{
///<summary>
///Get a list of classes for a locations. Specify ToDate / FromDate (max 7 days) to get a list of classes within a date range. Omitting dates will retrieve classes for today.
///</summary>
[Api(Description="Get a list of classes for a locations. Specify ToDate / FromDate (max 7 days) to get a list of classes within a date range. Omitting dates will retrieve classes for today.")]
public partial class GetClassScheduleRequest
: GetClassScheduleRequestDto, IRestrictedApiRequest
{
///<summary>
///Api Key - grants access to resources
///</summary>
[ApiMember(DataType="string", Description="Api Key - grants access to resources", IsRequired=true, Name="ApiKey", ParameterType="query")]
public virtual string ApiKey { get; set; }
///<summary>
///StoreID
///</summary>
[ApiMember(DataType="integer", Description="StoreID", IsRequired=true, Name="StoreID", ParameterType="query")]
public virtual int? StoreId { get; set; }
///<summary>
///From Date (if blank, defaults to today; format: YYYY-MM-DD)
///</summary>
[ApiMember(DataType="date", Description="From Date (if blank, defaults to today; format: YYYY-MM-DD)", Name="FromDate", ParameterType="query")]
public virtual DateTime? FromDate { get; set; }
///<summary>
///To Date (max 7 days; format: YYYY-MM-DD)
///</summary>
[ApiMember(DataType="date", Description="To Date (max 7 days; format: YYYY-MM-DD)", IsRequired=true, Name="ToDate", ParameterType="query")]
public virtual DateTime? ToDate { get; set; }
///<summary>
///Id of Category Names to filter results by
///</summary>
[ApiMember(DataType="int", Description="Id of Category Names to filter results by", Name="FilterByCategoryId", ParameterType="query")]
public virtual int? FilterByCategoryId { get; set; }
public virtual int? RestrictedId { get; set; }
public virtual RestrictedResourceType RestrictedResourceType { get; set; }
}
}
C# GetClassScheduleRequest 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 /scheduling/class-schedule HTTP/1.1 Host: clubready.com Accept: application/json