TicketUserServices

<back to all web services

OutboundEnqueueRequest

Requires Authentication
Required role:Admin
The following routes are available for this service:
POST/Outbound/Enqueue
import datetime
import decimal
from marshmallow.fields import *
from servicestack import *
from typing import *
from dataclasses import dataclass, field
from dataclasses_json import dataclass_json, LetterCase, Undefined, config
from enum import Enum, IntEnum


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class OutboundEnqueueResult:
    status: Optional[str] = None
    message_id: Optional[int] = None
    reason: Optional[str] = None
    status_code: Optional[int] = None
    message: Optional[str] = None


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class OutboundEnqueueRequest:
    channel: Optional[str] = None
    lane: Optional[str] = None
    priority: Optional[int] = None
    address: Optional[str] = None
    platform: Optional[str] = None
    recipient_key: Optional[str] = None
    template_key: Optional[str] = None
    language: Optional[str] = None
    payload_json: Optional[str] = None
    dedup_key: Optional[str] = None
    campaign_id: Optional[int] = None
    owner_id: Optional[int] = None
    guard_key: Optional[str] = None
    guard_subject: Optional[str] = None
    not_before: Optional[datetime.datetime] = None
    expires_at: Optional[datetime.datetime] = None

Python OutboundEnqueueRequest 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 /Outbound/Enqueue HTTP/1.1 
Host: stubbur-app.azurewebsites.net 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	channel: String,
	lane: String,
	priority: 0,
	address: String,
	platform: String,
	recipientKey: String,
	templateKey: String,
	language: String,
	payloadJson: String,
	dedupKey: String,
	campaignId: 0,
	ownerId: 0,
	guardKey: String,
	guardSubject: String,
	notBefore: 0001-01-01,
	expiresAt: 0001-01-01
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	status: String,
	messageId: 0,
	reason: String,
	statusCode: 0,
	message: String
}