Evo Voice

<back to all web services

GetInheritedSchedule

Get the inherited schedule for this customer

Requires Authentication
Requires any of the roles:SystemAdministrator, Manager, Customer
The following routes are available for this service:
GET/customers/{customerId}/inherited-schedule
GET/endpoints/{endpointId}/inherited-schedule
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using Voice.Api.Customers;
using Voice.Api.Scheduling;
using Voice.Api.Flows.Data;

namespace Voice.Api.Customers
{
    ///<summary>
    ///Get the inherited schedule for this customer
    ///</summary>
    [Api(Description="Get the inherited schedule for this customer")]
    public partial class GetInheritedSchedule
    {
        ///<summary>
        ///The customer ID whose inherited schedule you want to retrieve
        ///</summary>
        [ApiMember(Description="The customer ID whose inherited schedule you want to retrieve")]
        public virtual string CustomerId { get; set; }

        ///<summary>
        ///The endpoint ID whose inherited schedule you want to retrieve (use this OR customer id
        ///</summary>
        [ApiMember(Description="The endpoint ID whose inherited schedule you want to retrieve (use this OR customer id")]
        public virtual string EndpointId { get; set; }
    }

}

namespace Voice.Api.Flows.Data
{
    public partial class Struct
        : Dictionary<string, Value>
    {
    }

    public partial class Value
    {
        public Value()
        {
            ListValue = new List<Struct>{};
        }

        public virtual bool? BoolValue { get; set; }
        public virtual string StringValue { get; set; }
        public virtual double? NumberValue { get; set; }
        public virtual List<Struct> ListValue { get; set; }
        public virtual Struct StructValue { get; set; }
    }

}

namespace Voice.Api.Scheduling
{
    public partial class Schedule
    {
        public Schedule()
        {
            Rules = new List<SchedulingRule>{};
        }

        public virtual string TimeZoneId { get; set; }
        public virtual bool Inherit { get; set; }
        public virtual bool ForceClosed { get; set; }
        public virtual List<SchedulingRule> Rules { get; set; }
        public virtual string DefaultState { get; set; }
    }

    public partial class ScheduleDay
    {
        public virtual int Offset { get; set; }
        public virtual DayOfWeek DayOfWeek { get; set; }
    }

    public partial class SchedulingRule
    {
        public SchedulingRule()
        {
            BySetPosition = new List<int>{};
            ByMonth = new List<int>{};
            ByWeekNo = new List<int>{};
            ByYearDay = new List<int>{};
            ByMonthDay = new List<int>{};
            ByDay = new List<ScheduleDay>{};
            ByHour = new List<int>{};
            ByMinute = new List<int>{};
        }

        public virtual string Id { get; set; }
        public virtual string Name { get; set; }
        public virtual int Priority { get; set; }
        public virtual string State { get; set; }
        public virtual string Source { get; set; }
        public virtual string Condition { get; set; }
        public virtual SimpleSchedulingRuleTypes SimpleRuleType { get; set; }
        public virtual string CustomerState { get; set; }
        public virtual string FlowId { get; set; }
        public virtual Struct FlowParams { get; set; }
        public virtual bool IsAllDay { get; set; }
        public virtual string StartDate { get; set; }
        public virtual string StartTime { get; set; }
        public virtual string EndTime { get; set; }
        public virtual List<int> BySetPosition { get; set; }
        public virtual List<int> ByMonth { get; set; }
        public virtual List<int> ByWeekNo { get; set; }
        public virtual List<int> ByYearDay { get; set; }
        public virtual List<int> ByMonthDay { get; set; }
        public virtual List<ScheduleDay> ByDay { get; set; }
        public virtual List<int> ByHour { get; set; }
        public virtual List<int> ByMinute { get; set; }
        public virtual int Interval { get; set; }
        public virtual int Count { get; set; }
        public virtual string UntilDate { get; set; }
        public virtual SchedulingRuleFrequency Frequency { get; set; }
    }

    public enum SchedulingRuleFrequency
    {
        None,
        Secondly,
        Minutely,
        Hourly,
        Daily,
        Weekly,
        Monthly,
        Yearly,
    }

    public enum SimpleSchedulingRuleTypes
    {
        Always,
        CustomerState,
        Time,
    }

}

C# GetInheritedSchedule DTOs

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

HTTP + CSV

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

GET /customers/{customerId}/inherited-schedule HTTP/1.1 
Host: evovoice.io 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"timeZoneId":"String","inherit":false,"forceClosed":false,"rules":[{"id":"String","name":"String","priority":0,"state":"String","source":"String","condition":"String","simpleRuleType":"Always","customerState":"String","flowId":"String","flowParams":{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[null]}}],"structValue":{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[null]}}}}],"structValue":{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[null]}}],"structValue":{"String":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[null]}}}}}},"isAllDay":false,"startDate":"String","startTime":"String","endTime":"String","bySetPosition":[0],"byMonth":[0],"byWeekNo":[0],"byYearDay":[0],"byMonthDay":[0],"byDay":[{"offset":0,"dayOfWeek":"Sunday"}],"byHour":[0],"byMinute":[0],"interval":0,"count":0,"untilDate":"String","frequency":"None"}],"defaultState":"String"}