Requires any of the roles: | Manager, SystemAdministrator |
POST | /sessions/outgoing |
---|
namespace Voice.Api.Sessions
open System
open System.IO
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations
///<summary>
///Create a new outgoing call and process it with the specified flow. This can only be used for voice sessions. If no caller ID is specified, we will use a random one.
///</summary>
[<Api(Description="Create a new outgoing call and process it with the specified flow. This can only be used for voice sessions. If no caller ID is specified, we will use a random one.")>]
[<AllowNullLiteral>]
type NewOutgoingSession() =
interface IPost
///<summary>
///The ID of the flow to use. This flow will be executed as soon as the call is answered.
///</summary>
[<ApiMember(Description="The ID of the flow to use. This flow will be executed as soon as the call is answered.")>]
member val FlowId:String = null with get,set
///<summary>
///The E164 number to dial, e.g. +18144043093
///</summary>
[<ApiMember(Description="The E164 number to dial, e.g. +18144043093")>]
member val NumberToDial:String = null with get,set
///<summary>
///The Caller ID to use. This must be the E164 number of an owned phone number
///</summary>
[<ApiMember(Description="The Caller ID to use. This must be the E164 number of an owned phone number")>]
member val CallerId:String = null with get,set
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /sessions/outgoing HTTP/1.1
Host: team.evovoice.io
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length
{"flowId":"String","numberToDial":"String","callerId":"String"}