Platform API

<back to all web services

GetCommunicationTemplate

Get communication template for the current licensee and contact by setting id.

Requires Authentication
The following routes are available for this service:
All Verbs/api/communicationtemplate/{SettingId}
using System;
using System.IO;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using Eros.Subtle.Canvara.WebAPIModel.ServiceModel;
using Eros.Saguna.Common.WebAPIModel.Models;

namespace Eros.Saguna.Common.WebAPIModel.Models
{
    public partial class CommunicationTemplateModel
    {
        ///<summary>
        ///Communication Template Id
        ///</summary>
        [ApiMember(DataType="Guid", Description="Communication Template Id", IsRequired=true, Name="CommunicationTemplateId")]
        public virtual Guid CommunicationTemplateId { get; set; }

        ///<summary>
        ///Communication Template Name
        ///</summary>
        [ApiMember(DataType="string", Description="Communication Template Name", IsRequired=true, Name="TemplateName")]
        public virtual string TemplateName { get; set; }

        ///<summary>
        ///Communication Template Subject
        ///</summary>
        [ApiMember(DataType="string", Description="Communication Template Subject", Name="Subject")]
        public virtual string Subject { get; set; }

        ///<summary>
        ///Communication Template Content
        ///</summary>
        [ApiMember(DataType="string", Description="Communication Template Content", IsRequired=true, Name="Content")]
        public virtual string Content { get; set; }
    }

}

namespace Eros.Subtle.Canvara.WebAPIModel.ServiceModel
{
    ///<summary>
    ///Get communication template for the current licensee and contact by setting id.
    ///</summary>
    [Api(Description="Get communication template for the current licensee and contact by setting id.")]
    public partial class GetCommunicationTemplate
    {
        ///<summary>
        ///Setting Id linked to the communication template to get details for
        ///</summary>
        [ApiMember(Description="Setting Id linked to the communication template to get details for", IsRequired=true, Name="SettingId")]
        public virtual Guid SettingId { get; set; }
    }

    [ApiResponse(Description="Details of the communication template.")]
    public partial class GetCommunicationTemplateResponse
    {
        public virtual CommunicationTemplateModel CommunicationTemplate { get; set; }
        public virtual ResponseStatus ResponseStatus { get; set; }
    }

}

C# GetCommunicationTemplate 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 /api/communicationtemplate/{SettingId} HTTP/1.1 
Host: pfapi.pstpf.com.au 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	CommunicationTemplate: 
	{
		TemplateName: String,
		Subject: String,
		Content: String
	},
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}