Trendsic Platform Service

<back to all web services

IncomingSMSWebhookHandleAll

The following routes are available for this service:
POST,OPTIONS/v1/sms/handleall
namespace CRM.AgencyPlatform.API.Internal

open System
open System.IO
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations

    [<AllowNullLiteral>]
    type TwilioRequest() = 
        member val AccountSid:String = null with get,set
        member val From:String = null with get,set
        member val To:String = null with get,set
        member val FromCity:String = null with get,set
        member val FromState:String = null with get,set
        member val FromZip:String = null with get,set
        member val FromCountry:String = null with get,set
        member val ToCity:String = null with get,set
        member val ToState:String = null with get,set
        member val ToZip:String = null with get,set
        member val ToCountry:String = null with get,set

    [<AllowNullLiteral>]
    type SmsRequest() = 
        inherit TwilioRequest()
        member val MessageSid:String = null with get,set
        member val SmsSid:String = null with get,set
        member val Body:String = null with get,set
        member val MessageStatus:String = null with get,set
        member val OptOutType:String = null with get,set
        member val MessagingServiceSid:String = null with get,set
        member val NumMedia:Int32 = new Int32() with get,set
        member val ReferralNumMedia:Int32 = new Int32() with get,set

    [<AllowNullLiteral>]
    type IncomingSMSWebhookHandleAll() = 
        inherit SmsRequest()

F# IncomingSMSWebhookHandleAll DTOs

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

HTTP + JSV

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

POST /v1/sms/handleall HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	MessageSid: String,
	SmsSid: String,
	Body: String,
	MessageStatus: String,
	OptOutType: String,
	MessagingServiceSid: String,
	NumMedia: 0,
	ReferralNumMedia: 0,
	AccountSid: String,
	From: String,
	To: String,
	FromCity: String,
	FromState: String,
	FromZip: String,
	FromCountry: String,
	ToCity: String,
	ToState: String,
	ToZip: String,
	ToCountry: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

(string)