BokaMera.API.Host

<back to all web services

SettingQuery

Requires Authentication
Requires any of the roles:bookingsupplier-administrator-write, superadmin, bookingsupplier-administrator-read
The following routes are available for this service:
GET/settingsGet settings for the currently logged in userGet settings for the currently logged in user.
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using BokaMera.API.ServiceModel.Dtos;
using BokaMera.API.ServiceModel.Db;

namespace BokaMera.API.ServiceModel.Db
{
    public partial class BookingStatusOptions
    {
        public virtual int Id { get; set; }
        public virtual string Name { get; set; }
        public virtual string Description { get; set; }
    }

}

namespace BokaMera.API.ServiceModel.Dtos
{
    public partial class BookingTemplateResponse
    {
        public virtual int Id { get; set; }
        public virtual string Name { get; set; }
        public virtual string Description { get; set; }
        public virtual string UsedByApplication { get; set; }
    }

    public partial class CalendarTypeResponse
    {
        public virtual int Id { get; set; }
        public virtual string Name { get; set; }
        public virtual string Description { get; set; }
        public virtual bool Active { get; set; }
    }

    public partial class FreeSpotTextsResponse
    {
        public virtual int Id { get; set; }
        public virtual string TextSingular { get; set; }
        public virtual string TextPlural { get; set; }
    }

    public partial class ScheduleViewResponse
    {
        public virtual int Id { get; set; }
        public virtual string Name { get; set; }
    }

    [ApiResponse(Description="You were unauthorized to call this service", StatusCode=401)]
    [ApiResponse(Description="You have too low privilegies to call this service", StatusCode=403)]
    [ValidateRequest("IsAuthenticated")]
    public partial class SettingQuery
    {
        ///<summary>
        ///If you want to include the schedule views to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you want to include the schedule views to select from", ParameterType="query")]
        public virtual bool IncludeScheduleViewOptions { get; set; }

        ///<summary>
        ///If you want to include the week number settings to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you want to include the week number settings to select from", ParameterType="query")]
        public virtual bool IncludeWeekNumberOptions { get; set; }

        ///<summary>
        ///If you want to include the booking template options to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you want to include the booking template options to select from", ParameterType="query")]
        public virtual bool IncludeBookingTemplateOptions { get; set; }

        ///<summary>
        ///If you want to include the calendar type options to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you want to include the calendar type options to select from", ParameterType="query")]
        public virtual bool IncludeCalendarTypeOptions { get; set; }

        ///<summary>
        ///If you want to include the booking status options to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you want to include the booking status options to select from", ParameterType="query")]
        public virtual bool IncludeBookingStatusOptions { get; set; }

        ///<summary>
        ///If you want to include the Free spot text options to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you want to include the Free spot text options to select from", ParameterType="query")]
        public virtual bool IncludeFreeSpotTextOptions { get; set; }
    }

    public partial class SettingResponse
    {
        public SettingResponse()
        {
            ScheduleViewOptions = new List<ScheduleViewResponse>{};
            WeekNumberOptions = new List<WeekNumberSettingResponse>{};
            BookingTemplateOptions = new List<BookingTemplateResponse>{};
            CalendarTypeOptions = new List<CalendarTypeResponse>{};
            BookingStatusOptions = new List<BookingStatusOptions>{};
            FreeSpotTextOptions = new List<FreeSpotTextsResponse>{};
        }

        public virtual Guid CompanyId { get; set; }
        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int BookingStatusId { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int ScheduleViewId { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int BookingTemplateId { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int CalendarTypeId { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool AllowBookingOnUnbookedTimes { get; set; }

        ///<summary>
        ///
        ///</summary>
        [DataMember(Name="SendEmailReminder")]
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool SendEmailReminder { get; set; }

        ///<summary>
        ///
        ///</summary>
        [DataMember(Name="SendSmsReminder")]
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool SendSmsReminder { get; set; }

        ///<summary>
        ///
        ///</summary>
        [DataMember(Name="SendEmailConfirmation")]
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool SendEmailConfirmation { get; set; }

        ///<summary>
        ///
        ///</summary>
        [DataMember(Name="SendSmsConfirmation")]
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool SendSmsConfirmation { get; set; }

        ///<summary>
        ///Message text field that could be used inside message templates using [MessageText].
        ///</summary>
        [ApiMember(DataType="string", Description="Message text field that could be used inside message templates using [MessageText].")]
        public virtual string MessageText { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int EmailReminderTime { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int SmsReminderTime { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int MaxActiveBookings { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool SendNotifications { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="string", Description="")]
        public virtual string SendNotificationsEmail { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool EnableMobileApp { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(Description="")]
        public virtual TimeSpan? ScheduleStartTime { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual TimeSpan? ScheduleEndTime { get; set; }

        ///<summary>
        ///The admin scheduler if each resources should be shown in a seperate group
        ///</summary>
        [ApiMember(DataType="boolean", Description="The admin scheduler if each resources should be shown in a seperate group")]
        public virtual bool ScheduleGroupResources { get; set; }

        ///<summary>
        ///The admin scheduler if the horizontal scrolling should be turned off
        ///</summary>
        [ApiMember(DataType="boolean", Description="The admin scheduler if the horizontal scrolling should be turned off")]
        public virtual bool SchedulerDisableHorizontalScrolling { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="string", Description="")]
        public virtual string ReceiptTemplate { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int ScheduleTimeSlotMinutes { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool ShowFreeTimesLeft { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int FreeSpotTextsId { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool EnableICalGroupBookings { get; set; }

        ///<summary>
        ///Booking agreement text. All html needs to entered using markup. Read about markup here https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet. Use this editor to create markup https://stackedit.io/app#
        ///</summary>
        [ApiMember(DataType="string", Description="Booking agreement text. All html needs to entered using markup. Read about markup here https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet. Use this editor to create markup https://stackedit.io/app#")]
        public virtual string AgreementTemplate { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool ScheduleShowTimeExeptions { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool EnableBookingsOnSameTime { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="int", Description="")]
        public virtual int ShowWeekNumberSettingId { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool EnableShowBookedTimes { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="", Description="")]
        public virtual int? BookSpotUserResponseMinutes { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="", Description="")]
        public virtual bool IsBookSpotDirectly { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="", Description="")]
        public virtual int BookSpotDirectlyTimeLeftMinutes { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="", Description="")]
        public virtual bool? SendEmailNotificationQueue { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="", Description="")]
        public virtual bool? SendSMSNotificationQueue { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(Description="")]
        public virtual bool EnableSendFollowUpMessage { get; set; }

        ///<summary>
        ///When follow up message should be sent in hours after the booking.
        ///</summary>
        [ApiMember(Description="When follow up message should be sent in hours after the booking.")]
        public virtual int FollowUpMessageTime { get; set; }

        ///<summary>
        ///If it's only allowed for existing customers to book
        ///</summary>
        [ApiMember(DataType="boolean", Description="If it's only allowed for existing customers to book")]
        public virtual bool BookOnlyOnExistingCustomers { get; set; }

        ///<summary>
        ///If a unique pin code should be generated for the customer
        ///</summary>
        [ApiMember(DataType="boolean", Description="If a unique pin code should be generated for the customer")]
        public virtual bool AutoGenerateUniquePinCode { get; set; }

        ///<summary>
        ///If a user profile should be created when customer is booking time. With the property customer can login.
        ///</summary>
        [ApiMember(DataType="boolean", Description="If a user profile should be created when customer is booking time. With the property customer can login.")]
        public virtual bool AutoCreateUserProfile { get; set; }

        ///<summary>
        ///The available schedule view options to choose from
        ///</summary>
        [ApiMember(Description="The available schedule view options to choose from")]
        public virtual List<ScheduleViewResponse> ScheduleViewOptions { get; set; }

        ///<summary>
        ///The available week number options to choose from
        ///</summary>
        [ApiMember(Description="The available week number options to choose from")]
        public virtual List<WeekNumberSettingResponse> WeekNumberOptions { get; set; }

        ///<summary>
        ///The booking template options to choose from
        ///</summary>
        [ApiMember(Description="The booking template options to choose from")]
        public virtual List<BookingTemplateResponse> BookingTemplateOptions { get; set; }

        ///<summary>
        ///The calendar type options to choose from
        ///</summary>
        [ApiMember(Description="The calendar type options to choose from")]
        public virtual List<CalendarTypeResponse> CalendarTypeOptions { get; set; }

        ///<summary>
        ///The booking status options to choose from
        ///</summary>
        [ApiMember(Description="The booking status options to choose from")]
        public virtual List<BookingStatusOptions> BookingStatusOptions { get; set; }

        ///<summary>
        ///The free spot text options to choose from
        ///</summary>
        [ApiMember(Description="The free spot text options to choose from")]
        public virtual List<FreeSpotTextsResponse> FreeSpotTextOptions { get; set; }

        ///<summary>
        ///If you have different prices over different times per day and want it to calculate the weighted price for the booked time.
        ///</summary>
        [ApiMember(DataType="boolean", Description="If you have different prices over different times per day and want it to calculate the weighted price for the booked time.")]
        public virtual bool WeightedPrices { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool ShowMultiDayAsTime { get; set; }

        ///<summary>
        ///
        ///</summary>
        [ApiMember(DataType="boolean", Description="")]
        public virtual bool ShowMultipleResourcesAsOne { get; set; }
    }

    public partial class WeekNumberSettingResponse
    {
        public virtual int Id { get; set; }
        public virtual string Name { get; set; }
        public virtual string Description { get; set; }
    }

}

C# SettingQuery 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 /settings HTTP/1.1 
Host: api.bokamera.se 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<SettingResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
  <AgreementTemplate>String</AgreementTemplate>
  <AllowBookingOnUnbookedTimes>false</AllowBookingOnUnbookedTimes>
  <AutoCreateUserProfile>false</AutoCreateUserProfile>
  <AutoGenerateUniquePinCode>false</AutoGenerateUniquePinCode>
  <BookOnlyOnExistingCustomers>false</BookOnlyOnExistingCustomers>
  <BookSpotDirectlyTimeLeftMinutes>0</BookSpotDirectlyTimeLeftMinutes>
  <BookSpotUserResponseMinutes>0</BookSpotUserResponseMinutes>
  <BookingStatusId>0</BookingStatusId>
  <BookingStatusOptions xmlns:d2p1="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Db">
    <d2p1:BookingStatusOptions>
      <d2p1:Description>String</d2p1:Description>
      <d2p1:Id>0</d2p1:Id>
      <d2p1:Name>String</d2p1:Name>
    </d2p1:BookingStatusOptions>
  </BookingStatusOptions>
  <BookingTemplateId>0</BookingTemplateId>
  <BookingTemplateOptions>
    <BookingTemplateResponse>
      <Description>String</Description>
      <Id>0</Id>
      <Name>String</Name>
      <UsedByApplication>String</UsedByApplication>
    </BookingTemplateResponse>
  </BookingTemplateOptions>
  <CalendarTypeId>0</CalendarTypeId>
  <CalendarTypeOptions>
    <CalendarTypeResponse>
      <Active>false</Active>
      <Description>String</Description>
      <Id>0</Id>
      <Name>String</Name>
    </CalendarTypeResponse>
  </CalendarTypeOptions>
  <CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
  <EmailReminderTime>0</EmailReminderTime>
  <EnableBookingsOnSameTime>false</EnableBookingsOnSameTime>
  <EnableICalGroupBookings>false</EnableICalGroupBookings>
  <EnableMobileApp>false</EnableMobileApp>
  <EnableSendFollowUpMessage>false</EnableSendFollowUpMessage>
  <EnableShowBookedTimes>false</EnableShowBookedTimes>
  <FollowUpMessageTime>0</FollowUpMessageTime>
  <FreeSpotTextOptions>
    <FreeSpotTextsResponse>
      <Id>0</Id>
      <TextPlural>String</TextPlural>
      <TextSingular>String</TextSingular>
    </FreeSpotTextsResponse>
  </FreeSpotTextOptions>
  <FreeSpotTextsId>0</FreeSpotTextsId>
  <IsBookSpotDirectly>false</IsBookSpotDirectly>
  <MaxActiveBookings>0</MaxActiveBookings>
  <MessageText>String</MessageText>
  <ReceiptTemplate>String</ReceiptTemplate>
  <ScheduleEndTime>PT0S</ScheduleEndTime>
  <ScheduleGroupResources>false</ScheduleGroupResources>
  <ScheduleShowTimeExeptions>false</ScheduleShowTimeExeptions>
  <ScheduleStartTime>PT0S</ScheduleStartTime>
  <ScheduleTimeSlotMinutes>0</ScheduleTimeSlotMinutes>
  <ScheduleViewId>0</ScheduleViewId>
  <ScheduleViewOptions>
    <ScheduleViewResponse>
      <Id>0</Id>
      <Name>String</Name>
    </ScheduleViewResponse>
  </ScheduleViewOptions>
  <SchedulerDisableHorizontalScrolling>false</SchedulerDisableHorizontalScrolling>
  <SendEmailConfirmation>false</SendEmailConfirmation>
  <SendEmailNotificationQueue>false</SendEmailNotificationQueue>
  <SendEmailReminder>false</SendEmailReminder>
  <SendNotifications>false</SendNotifications>
  <SendNotificationsEmail>String</SendNotificationsEmail>
  <SendSMSNotificationQueue>false</SendSMSNotificationQueue>
  <SendSmsConfirmation>false</SendSmsConfirmation>
  <SendSmsReminder>false</SendSmsReminder>
  <ShowFreeTimesLeft>false</ShowFreeTimesLeft>
  <ShowMultiDayAsTime>false</ShowMultiDayAsTime>
  <ShowMultipleResourcesAsOne>false</ShowMultipleResourcesAsOne>
  <ShowWeekNumberSettingId>0</ShowWeekNumberSettingId>
  <SmsReminderTime>0</SmsReminderTime>
  <WeekNumberOptions>
    <WeekNumberSettingResponse>
      <Description>String</Description>
      <Id>0</Id>
      <Name>String</Name>
    </WeekNumberSettingResponse>
  </WeekNumberOptions>
  <WeightedPrices>false</WeightedPrices>
</SettingResponse>