Evo Voice

<back to all web services

AppGetFlows

Requires Authentication
The following routes are available for this service:
GET/portal/flows


export class NodeParameterMap
{
    [key:string] : NodeParameter;

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


export enum SortOrders
{
    Ascend = 'Ascend',
    Descend = 'Descend',
}

export class ListRequest<T> implements IGet
{
    /** @description The page of data to retrieve */
    // @ApiMember(Description="The page of data to retrieve")
    public page: number;

    /** @description If you want all objects to be returned. This should be used with care */
    // @ApiMember(Description="If you want all objects to be returned. This should be used with care")
    public all: boolean;

    /** @description The number per page to retrieve */
    // @ApiMember(Description="The number per page to retrieve")
    public countPerPage: number;

    /** @description Specific IDs */
    // @ApiMember(Description="Specific IDs")
    public specificIds: string[];

    /** @description Specify a sort field */
    // @ApiMember(Description="Specify a sort field")
    public sortField: string;

    /** @description Specify a sort order */
    // @ApiMember(Description="Specify a sort order")
    public sortOrder: SortOrders;

    /** @description Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array */
    // @ApiMember(Description="Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array")
    public simplifiedPaging: boolean;

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

export class EntityInfo
{
    /** @description The ID of the object */
    // @ApiMember(Description="The ID of the object")
    public id: string;

    /** @description The date the object was created */
    // @ApiMember(Description="The date the object was created")
    public dateCreated: string;

    /** @description The date the object was last modified */
    // @ApiMember(Description="The date the object was last modified")
    public dateLastModified: string;

    /** @description The user that created this object */
    // @ApiMember(Description="The user that created this object")
    public createdBy: string;

    /** @description The user that last modified this object */
    // @ApiMember(Description="The user that last modified this object")
    public lastModifiedBy: string;

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

export enum FlowRoles
{
    UI = 'UI',
    Reference = 'Reference',
    PhoneNumberRouting = 'PhoneNumberRouting',
    UserDialOut = 'UserDialOut',
    FaxNumberRouting = 'FaxNumberRouting',
}

export class CustomerBreadcrumb
{
    public id: string;
    public name: string;

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

export enum FlowNodeCategories
{
    General = 'General',
    Voice = 'Voice',
    Logic = 'Logic',
    DateAndTime = 'DateAndTime',
    Audio = 'Audio',
    Messaging = 'Messaging',
    Assistant = 'Assistant',
    Flows = 'Flows',
    Fax = 'Fax',
    Network = 'Network',
    Cookies = 'Cookies',
    CallCenter = 'CallCenter',
    Intelligence = 'Intelligence',
}

export enum ValueTypes
{
    NotSpecified = 'NotSpecified',
    String = 'String',
    Boolean = 'Boolean',
    Number = 'Number',
    List = 'List',
    Struct = 'Struct',
    Transition = 'Transition',
    Custom = 'Custom',
    Date = 'Date',
    AudioFile = 'AudioFile',
    TimeZoneId = 'TimeZoneId',
    PhoneNumber = 'PhoneNumber',
    User = 'User',
    Endpoint = 'Endpoint',
    Time = 'Time',
    File = 'File',
    FaxNumber = 'FaxNumber',
    EmailAccount = 'EmailAccount',
    Customer = 'Customer',
    Flow = 'Flow',
    Team = 'Team',
    FlowReference = 'FlowReference',
    Integration = 'Integration',
    Assistant = 'Assistant',
}

export enum UIHints
{
    None = 'None',
    LargeText = 'LargeText',
    InlineForm = 'InlineForm',
    Password = 'Password',
    InlineStruct = 'InlineStruct',
}

export class Struct
{

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

export class Value
{
    public boolValue?: boolean;
    public stringValue: string;
    public numberValue?: number;
    public listValue: Struct[];
    public structValue: Struct;

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

export enum DataFieldUniqueness
{
    NotUnique = 'NotUnique',
    Unique = 'Unique',
    UniqueToCustomer = 'UniqueToCustomer',
}

export enum UserDataFieldModes
{
    Hidden = 'Hidden',
    ReadOnly = 'ReadOnly',
    ReadWrite = 'ReadWrite',
}

export class DataField
{
    public id: string;
    public name: string;
    public type: ValueTypes;
    public uiHint: UIHints;
    public uiTab: string;
    public isAsync: boolean;
    public disableBinding: boolean;
    public structType: DataType;
    public listType: DataType;
    public description: string;
    public possibleValues: string[];
    public isOutput: boolean;
    public customFieldValuesUrl: string;
    public defaultValue: Value;
    public transitionNameFormat: string;
    public uniqueness: DataFieldUniqueness;
    public voiceOnly: boolean;
    public conditionalVisibilityField: string;
    public conditionalVisibilityValue: string;
    public noEvalTemplate: boolean;
    public userMode: UserDataFieldModes;
    public anyValueType: boolean;

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

export class DataType
{
    public typeName: string;
    public fields: DataField[];

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

export enum FlowChannels
{
    Voice = 'Voice',
    Chat = 'Chat',
    Fax = 'Fax',
}

export class FlowNodeSpec
{
    /** @description The name of this node */
    // @ApiMember(Description="The name of this node")
    public name: string;

    /** @description A description of this node */
    // @ApiMember(Description="A description of this node")
    public description: string;

    /** @description Icon class for this node (FontAwesome) */
    // @ApiMember(Description="Icon class for this node (FontAwesome)")
    public iconClass: string;

    /** @description The type name for this node */
    // @ApiMember(Description="The type name for this node")
    public typeName: string;

    /** @description The category this node should be grouped under */
    // @ApiMember(Description="The category this node should be grouped under")
    public category: FlowNodeCategories;

    /** @description The URL where this node is located */
    // @ApiMember(Description="The URL where this node is located")
    public url: string;

    /** @description The data type for this node */
    // @ApiMember(Description="The data type for this node")
    public dataType: DataType;

    /** @description URL for documentation for this node */
    // @ApiMember(Description="URL for documentation for this node")
    public documentationUrl: string;

    /** @description The channels that this node is restricted to */
    // @ApiMember(Description="The channels that this node is restricted to")
    public restrictToChannels: FlowChannels[];

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

export class FlowNodeUI
{
    /** @description The X position of the node */
    // @ApiMember(Description="The X position of the node")
    public x: number;

    /** @description The Y position of the node */
    // @ApiMember(Description="The Y position of the node")
    public y: number;

    /** @description Notes for this node */
    // @ApiMember(Description="Notes for this node")
    public notes: string;

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

export enum ValueSources
{
    Value = 'Value',
    Flow = 'Flow',
    System = 'System',
    Customer = 'Customer',
    Session = 'Session',
    Endpoint = 'Endpoint',
    Expression = 'Expression',
    User = 'User',
}

export class NodeParameter
{
    public id: string;
    public type: ValueTypes;
    public source: ValueSources;
    public isAsync: boolean;
    public referenceId: string;
    public value: Value;
    public noEvalTemplate: boolean;
    public listParameters: NodeParameterMap[];
    public structParameters: NodeParameterMap;
    public isOutput: boolean;
    public expression: string;
    public listType: DataType;

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

export class NodeParameterMap
{

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

export class FlowNode
{
    /** @description The ID of this node. Must be unique within the flow but can be anything */
    // @ApiMember(Description="The ID of this node. Must be unique within the flow but can be anything")
    public id: string;

    /** @description Is this the starting node for the flow. Only one node can have this set */
    // @ApiMember(Description="Is this the starting node for the flow. Only one node can have this set")
    public isStartNode: boolean;

    /** @description The name of the node, descriptive to be used as a reminder in the GUI */
    // @ApiMember(Description="The name of the node, descriptive to be used as a reminder in the GUI")
    public name: string;

    /** @description The specification for the node */
    // @ApiMember(Description="The specification for the node")
    public spec: FlowNodeSpec;

    /** @description The UI data for the node */
    // @ApiMember(Description="The UI data for the node")
    public ui: FlowNodeUI;

    /** @description The data for this node. These will be POST'd to the endpoint when it is called. */
    // @ApiMember(Description="The data for this node. These will be POST'd to the endpoint when it is called.")
    public parameters: NodeParameterMap;

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

export class FlowParameter extends DataField
{
    public isPublic: boolean;
    public isKnob: boolean;

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

export class FlowExit
{
    /** @description The unique ID for this exit */
    // @ApiMember(Description="The unique ID for this exit")
    public id: string;

    /** @description The name of this exit */
    // @ApiMember(Description="The name of this exit")
    public name: string;

    /** @description The UI for the exit */
    // @ApiMember(Description="The UI for the exit")
    public ui: FlowNodeUI;

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

export class FlowUI
{
    public selectedNode: string;
    public canvasX: number;
    public canvasY: number;
    public canvasZoom: number;

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

export enum TagColors
{
    Magenta = 'Magenta',
    Red = 'Red',
    Volcano = 'Volcano',
    Orange = 'Orange',
    Gold = 'Gold',
    Lime = 'Lime',
    Green = 'Green',
    Cyan = 'Cyan',
    Blue = 'Blue',
    GeekBlue = 'GeekBlue',
    Purple = 'Purple',
}

export class Tag
{
    public id: string;
    public name: string;
    public color: TagColors;

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

export class FlowInfo extends EntityInfo
{
    /** @description The name of this flow */
    // @ApiMember(Description="The name of this flow")
    public name: string;

    /** @description The roles that this flow has */
    // @ApiMember(Description="The roles that this flow has")
    public roles: FlowRoles[];

    /** @description What this flow does */
    // @ApiMember(Description="What this flow does")
    public description: string;

    /** @description Any notes for this flow */
    // @ApiMember(Description="Any notes for this flow")
    public notes: string;

    /** @description The ID of the account associated with the flow */
    // @ApiMember(Description="The ID of the account associated with the flow")
    public accountId: string;

    /** @description The name of the account associated with the flow */
    // @ApiMember(Description="The name of the account associated with the flow")
    public accountName: string;

    /** @description The ID of the customer this flow is associated with */
    // @ApiMember(Description="The ID of the customer this flow is associated with")
    public customerId: string;

    /** @description The name of the customer this flow is associated with */
    // @ApiMember(Description="The name of the customer this flow is associated with")
    public customerName: string;

    /** @description The breadcrumb to the flow for this endpoint */
    // @ApiMember(Description="The breadcrumb to the flow for this endpoint")
    public customerBreadcrumb: CustomerBreadcrumb[];

    /** @description The nodes in this flow */
    // @ApiMember(Description="The nodes in this flow")
    public nodes: FlowNode[];

    /** @description The flow's parameters */
    // @ApiMember(Description="The flow's parameters")
    public parameters: FlowParameter[];

    /** @description The flow's exits */
    // @ApiMember(Description="The flow's exits")
    public exits: FlowExit[];

    /** @description The UI data for the flow */
    // @ApiMember(Description="The UI data for the flow")
    public ui: FlowUI;

    /** @description The list of tags for this flow */
    // @ApiMember(Description="The list of tags for this flow")
    public tags: Tag[];

    /** @description The number of nodes in this flow */
    // @ApiMember(Description="The number of nodes in this flow")
    public nodeCount: number;

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

export class AppGetFlows extends ListRequest<FlowInfo>
{
    public accountId: string;
    public customerId: string;
    public nameFilter: string;
    public role?: FlowRoles;

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

export class BillingItem
{
    public baseCost: number;
    public rawUnitMultiplier: number;
    public unitCost: number;
    public allowance: number;

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

export class BillingSettings
{
    public base: BillingItem;
    public localNumbers: BillingItem;
    public tollFreeNumbers: BillingItem;
    public inboundVoiceCalls: BillingItem;
    public outboundVoiceCalls: BillingItem;
    public inboundFaxes: BillingItem;
    public outboundFaxes: BillingItem;
    public inboundSmsMessages: BillingItem;
    public outboundSmsMessages: BillingItem;
    public aiInsights: BillingItem;
    public aiLiveMinutes: BillingItem;

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

export class AccountInfo extends EntityInfo
{
    /** @description The name of this account */
    // @ApiMember(Description="The name of this account")
    public name: string;

    /** @description The ID of this account's parent */
    // @ApiMember(Description="The ID of this account's parent")
    public parentAccountId: string;

    /** @description The twilio account SID */
    // @ApiMember(Description="The twilio account SID")
    public twilioAccountSid: string;

    /** @description The ancestors of this account. Useful for breadcrumbs */
    // @ApiMember(Description="The ancestors of this account. Useful for breadcrumbs")
    public ancestorIds: string[];

    /** @description The max number of phone numbers this account can have */
    // @ApiMember(Description="The max number of phone numbers this account can have")
    public maxPhoneNumbers: number;

    /** @description This account is BYOA */
    // @ApiMember(Description="This account is BYOA")
    public isBYOA: boolean;

    /** @description TrustHub Profile Sid */
    // @ApiMember(Description="TrustHub Profile Sid")
    public trustHubProfileSid: string;

    /** @description The ID of the logo file */
    // @ApiMember(Description="The ID of the logo file")
    public logoId: string;

    /** @description The URI of the logo file */
    // @ApiMember(Description="The URI of the logo file")
    public logoUri: string;

    /** @description The billing settings for this account */
    // @ApiMember(Description="The billing settings for this account")
    public billingSettings: BillingSettings;

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

export class ListResponse<T>
{
    /** @description The items */
    // @ApiMember(Description="The items")
    public items: AccountInfo[];

    /** @description The total number of items */
    // @ApiMember(Description="The total number of items")
    public totalCount: number;

    /** @description The total number of pages */
    // @ApiMember(Description="The total number of pages")
    public totalPages: number;

    /** @description Are there more pages of items? Used with simplified paging */
    // @ApiMember(Description="Are there more pages of items? Used with simplified paging")
    public hasMorePages: boolean;

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

TypeScript AppGetFlows 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 /portal/flows HTTP/1.1 
Host: team.evovoice.io 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"items":[{"name":"String","roles":["UI"],"description":"String","notes":"String","accountId":"String","accountName":"String","customerId":"String","customerName":"String","customerBreadcrumb":[{"id":"String","name":"String"}],"nodes":[{"id":"String","isStartNode":false,"name":"String","spec":{"name":"String","description":"String","iconClass":"String","typeName":"String","category":"General","url":"String","documentationUrl":"String","restrictToChannels":["Voice"]},"ui":{"x":0,"y":0,"notes":"String"},"parameters":{}}],"parameters":[{"isPublic":false,"isKnob":false,"id":"String","name":"String","type":"NotSpecified","uiHint":"None","uiTab":"String","isAsync":false,"disableBinding":false,"description":"String","possibleValues":["String"],"isOutput":false,"customFieldValuesUrl":"String","defaultValue":{"boolValue":false,"stringValue":"String","numberValue":0,"listValue":[null]},"transitionNameFormat":"String","uniqueness":"NotUnique","voiceOnly":false,"conditionalVisibilityField":"String","conditionalVisibilityValue":"String","noEvalTemplate":false,"userMode":"Hidden","anyValueType":false}],"exits":[{"id":"String","name":"String","ui":{"x":0,"y":0,"notes":"String"}}],"ui":{"selectedNode":"String","canvasX":0,"canvasY":0,"canvasZoom":0},"tags":[{"id":"String","name":"String","color":"Magenta"}],"nodeCount":0,"id":"String","dateCreated":"String","dateLastModified":"String","createdBy":"String","lastModifiedBy":"String"}],"totalCount":0,"totalPages":0,"hasMorePages":false}