SMS Gateway API

<back to all web services

SendTask

Requires Authentication
using System;
using System.IO;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using Eros.Saguna.Common.GatewayClient.ServiceModel;
using Eros.Saguna.Common.Library;
using Eros.Saguna.Common.Library.Queuing;

namespace Eros.Saguna.Common.GatewayClient.ServiceModel
{
    public partial class SendTask
    {
        public virtual GatewayTask GatewayTask { get; set; }
    }

}

namespace Eros.Saguna.Common.Library
{
    public enum GatewayResponseStatus
    {
        Initiated,
        Successful,
        JobError,
    }

    public partial class GatewayTask
        : BaseQueueMessage
    {
        public virtual Guid ReferenceId { get; set; }
        public virtual Guid JobTypeId { get; set; }
        public virtual bool IsBeingProcessed { get; set; }
        public virtual string Payload { get; set; }
        public virtual bool ContentStoredExternally { get; set; }
        public virtual bool ResendRequest { get; set; }
    }

    public partial class GatewayTaskResponse
    {
        public virtual Guid ReferenceId { get; set; }
        public virtual GatewayResponseStatus GatewayTaskResponseStatus { get; set; }
        public virtual string Payload { get; set; }
    }

}

namespace Eros.Saguna.Common.Library.Queuing
{
    public partial class BaseQueueMessage
    {
        public virtual Guid LicenseeId { get; set; }
    }

}

C# SendTask DTOs

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

HTTP + OTHER

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

POST /jsonl/reply/SendTask HTTP/1.1 
Host: production-eros-gateway-api-sms-wa.azurewebsites.net 
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length

{"GatewayTask":{"ReferenceId":"00000000000000000000000000000000","JobTypeId":"00000000000000000000000000000000","IsBeingProcessed":false,"Payload":"String","ContentStoredExternally":false,"ResendRequest":false,"LicenseeId":"00000000000000000000000000000000"}}
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{"ReferenceId":"00000000000000000000000000000000","GatewayTaskResponseStatus":"Initiated","Payload":"String"}