Trendsic Platform Service

<back to all web services

FormInvitesRequest

Requires Authentication
The following routes are available for this service:
GET/v1/forms/{FormUID}/invites
import Foundation
import ServiceStack

public class FormInvitesRequest : Codable
{
    public var formUID:String

    required public init(){}
}

public class FormInvitesResponse : Codable
{
    public var invites:[FormInviteView] = []
    public var created:[FormInviteView] = []
    public var emails:Int
    public var texts:Int
    public var consequence:String
    public var responseStatus:ResponseStatus

    required public init(){}
}

public class FormInviteView : Codable
{
    public var inviteUID:String
    public var name:String
    public var email:String
    public var phone:String
    public var createdBy:String
    public var createdAt:Date?
    public var expiresAt:Date?
    public var sentAt:Date?
    public var lastSentAt:Date?
    public var sendCount:Int
    public var openedAt:Date?
    public var revokedAt:Date?
    public var number:String
    public var state:String
    public var link:String
    public var sends:[FormFillReceiptLine] = []

    required public init(){}
}

public class FormFillReceiptLine : Codable
{
    public var channel:String
    public var to:String
    public var outcome:String

    required public init(){}
}


Swift FormInvitesRequest 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.

GET /v1/forms/{FormUID}/invites HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	Invites: 
	[
		{
			InviteUID: 00000000000000000000000000000000,
			Name: String,
			Email: String,
			Phone: String,
			CreatedBy: String,
			CreatedAt: 0001-01-01,
			ExpiresAt: 0001-01-01,
			SentAt: 0001-01-01,
			LastSentAt: 0001-01-01,
			SendCount: 0,
			OpenedAt: 0001-01-01,
			RevokedAt: 0001-01-01,
			Number: String,
			State: String,
			Link: String,
			Sends: 
			[
				{
					Channel: String,
					To: String,
					Outcome: String
				}
			]
		}
	],
	Created: 
	[
		{
			InviteUID: 00000000000000000000000000000000,
			Name: String,
			Email: String,
			Phone: String,
			CreatedBy: String,
			CreatedAt: 0001-01-01,
			ExpiresAt: 0001-01-01,
			SentAt: 0001-01-01,
			LastSentAt: 0001-01-01,
			SendCount: 0,
			OpenedAt: 0001-01-01,
			RevokedAt: 0001-01-01,
			Number: String,
			State: String,
			Link: String,
			Sends: 
			[
				{
					Channel: String,
					To: String,
					Outcome: String
				}
			]
		}
	],
	Emails: 0,
	Texts: 0,
	Consequence: String,
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}