BokaMera.API.Host

<back to all web services

HomepageSettingsQuery

The following routes are available for this service:
GET/homepage/settingsGet the homepage settings for the company
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using BokaMera.API.ServiceModel.Dtos;

namespace BokaMera.API.ServiceModel.Dtos
{
    public partial class HomepageHeroSectionStyleResponse
    {
        ///<summary>
        ///The hero section style id
        ///</summary>
        [ApiMember(Description="The hero section style id")]
        public virtual int Id { get; set; }

        ///<summary>
        ///The hero section style name
        ///</summary>
        [ApiMember(Description="The hero section style name")]
        public virtual string Name { get; set; }

        ///<summary>
        ///The hero section style description
        ///</summary>
        [ApiMember(Description="The hero section style description")]
        public virtual string Description { get; set; }
    }

    public partial class HomepageSettingsQuery
        : ICompany, ICompanyRequest
    {
        ///<summary>
        ///The company id, if empty will use the company id for the user you are logged in with.
        ///</summary>
        [ApiMember(Description="The company id, if empty will use the company id for the user you are logged in with.", ParameterType="path")]
        public virtual Guid? CompanyId { get; set; }

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

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

        ///<summary>
        ///The homeage sitepath.
        ///</summary>
        [ApiMember(Description="The homeage sitepath.")]
        public virtual string SitePath { get; set; }
    }

    public partial class HomepageSettingsQueryResponse
    {
        public HomepageSettingsQueryResponse()
        {
            HomePageTemplateOptions = new List<HomepageTemplateResponse>{};
            HomepageHeroSectionStyleOptions = new List<HomepageHeroSectionStyleResponse>{};
        }

        ///<summary>
        ///The company id
        ///</summary>
        [ApiMember(Description="The company id")]
        public virtual Guid CompanyId { get; set; }

        ///<summary>
        ///The text for homepage heading
        ///</summary>
        [ApiMember(Description="The text for homepage heading")]
        public virtual string HomepageHeading { get; set; }

        ///<summary>
        ///The text for homepage startpage heading
        ///</summary>
        [ApiMember(Description="The text for homepage startpage heading")]
        public virtual string WelcomePageHeading { get; set; }

        ///<summary>
        ///The text for homepage startpage body
        ///</summary>
        [ApiMember(Description="The text for homepage startpage body")]
        public virtual string WelcomePageBody { get; set; }

        ///<summary>
        ///The text for homepage about us page heading
        ///</summary>
        [ApiMember(Description="The text for homepage about us page heading")]
        public virtual string AboutUsPageHeading { get; set; }

        ///<summary>
        ///The text for homepage about us page body
        ///</summary>
        [ApiMember(Description="The text for homepage about us page body")]
        public virtual string AboutUsPageBody { get; set; }

        ///<summary>
        ///The startpage image url
        ///</summary>
        [ApiMember(Description="The startpage image url")]
        public virtual Uri ImageUrl { get; set; }

        ///<summary>
        ///The template for the homepage
        ///</summary>
        [ApiMember(Description="The template for the homepage")]
        public virtual int HomePageTemplateId { get; set; }

        ///<summary>
        ///The hero section style for the homepage
        ///</summary>
        [ApiMember(Description="The hero section style for the homepage")]
        public virtual int HeroSectionStyleId { get; set; }

        ///<summary>
        ///Show rating on the page
        ///</summary>
        [ApiMember(Description="Show rating on the page")]
        public virtual bool ShowRating { get; set; }

        ///<summary>
        ///Enable the BokaMera Homepage
        ///</summary>
        [ApiMember(Description="Enable the BokaMera Homepage")]
        public virtual bool EnableHomepage { get; set; }

        ///<summary>
        ///Will show when the homepage settings was created, note it will only be shown if your logged in as admin for the company.
        ///</summary>
        [ApiMember(DataType="datetime", Description="Will show when the homepage settings was created, note it will only be shown if your logged in as admin for the company.")]
        public virtual DateTime? Updated { get; set; }

        ///<summary>
        ///Will show when the homepage settings was updated, note it will only be shown if your logged in as admin for the company.
        ///</summary>
        [ApiMember(DataType="datetime", Description="Will show when the homepage settings was updated, note it will only be shown if your logged in as admin for the company.")]
        public virtual DateTime? Created { get; set; }

        ///<summary>
        ///The homepage templates options to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="The homepage templates options to select from", ParameterType="query")]
        public virtual List<HomepageTemplateResponse> HomePageTemplateOptions { get; set; }

        ///<summary>
        ///The homepage hero section style options to select from
        ///</summary>
        [ApiMember(DataType="boolean", Description="The homepage hero section style options to select from", ParameterType="query")]
        public virtual List<HomepageHeroSectionStyleResponse> HomepageHeroSectionStyleOptions { get; set; }
    }

    public partial class HomepageTemplateResponse
    {
        ///<summary>
        ///The template id
        ///</summary>
        [ApiMember(Description="The template id")]
        public virtual int Id { get; set; }

        ///<summary>
        ///The template name
        ///</summary>
        [ApiMember(Description="The template name")]
        public virtual string Name { get; set; }

        ///<summary>
        ///The template description
        ///</summary>
        [ApiMember(Description="The template description")]
        public virtual string Description { get; set; }

        ///<summary>
        ///The template image url
        ///</summary>
        [ApiMember(Description="The template image url")]
        public virtual Uri ImageUrl { get; set; }
    }

}

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

{"HomepageHeading":"String","WelcomePageHeading":"String","WelcomePageBody":"String","AboutUsPageHeading":"String","AboutUsPageBody":"String","HomePageTemplateId":0,"HeroSectionStyleId":0,"ShowRating":false,"EnableHomepage":false,"Updated":"0001-01-01T00:00:00","Created":"0001-01-01T00:00:00","HomePageTemplateOptions":[{"Id":0,"Name":"String","Description":"String"}],"HomepageHeroSectionStyleOptions":[{"Id":0,"Name":"String","Description":"String"}]}