| POST | /api/notification/insert |
|---|
"use strict";
export class NotificationRole {
/** @param {{RoleId?:string,RoleName?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
RoleId;
/** @type {string} */
RoleName;
}
export class Notification {
/** @param {{NotificationId?:string,NotificationGroupId?:string,NotificationGroupName?:string,SuiteId?:string,SuiteName?:string,NotificationValueId?:string,Roles?:NotificationRole[],RolesToDisplay?:string,Name?:string,Description?:string,IsMandatory?:boolean,IsCardinality?:boolean,IsSystem?:boolean,IsAudit?:boolean,IsVisibleToRecipients?:boolean,IsSingleUse?:boolean,Email?:boolean,EmailDefault?:boolean,EmailTemplateId?:string,EmailTemplateBody?:string,EmailSubject?:string,SMS?:boolean,SMSDefault?:boolean,SMSTemplateId?:string,SMSTemplateBody?:string,UpdateNotification?:boolean,UpdateNotificationDefault?:boolean,UpdateTemplateId?:string,UpdateTemplateBody?:string,UpdateSubject?:string,Push?:boolean,PushDefault?:boolean,Phone?:boolean,PhoneDefault?:boolean,ContactIdOwner?:string,RecordStatus?:string,EmailTemplateDefinitionId?:string,SMSTemplateDefinitionId?:string,UpdateTemplateDefinitionId?:string,Index?:number}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
NotificationId;
/** @type {string} */
NotificationGroupId;
/** @type {string} */
NotificationGroupName;
/** @type {string} */
SuiteId;
/** @type {string} */
SuiteName;
/** @type {string} */
NotificationValueId;
/** @type {NotificationRole[]} */
Roles;
/** @type {string} */
RolesToDisplay;
/** @type {string} */
Name;
/** @type {string} */
Description;
/** @type {boolean} */
IsMandatory;
/** @type {boolean} */
IsCardinality;
/** @type {boolean} */
IsSystem;
/** @type {boolean} */
IsAudit;
/** @type {boolean} */
IsVisibleToRecipients;
/** @type {boolean} */
IsSingleUse;
/** @type {boolean} */
Email;
/** @type {boolean} */
EmailDefault;
/** @type {string} */
EmailTemplateId;
/** @type {string} */
EmailTemplateBody;
/** @type {string} */
EmailSubject;
/** @type {boolean} */
SMS;
/** @type {boolean} */
SMSDefault;
/** @type {string} */
SMSTemplateId;
/** @type {string} */
SMSTemplateBody;
/** @type {boolean} */
UpdateNotification;
/** @type {boolean} */
UpdateNotificationDefault;
/** @type {string} */
UpdateTemplateId;
/** @type {string} */
UpdateTemplateBody;
/** @type {string} */
UpdateSubject;
/** @type {boolean} */
Push;
/** @type {boolean} */
PushDefault;
/** @type {boolean} */
Phone;
/** @type {boolean} */
PhoneDefault;
/** @type {string} */
ContactIdOwner;
/** @type {string} */
RecordStatus;
/** @type {string} */
EmailTemplateDefinitionId;
/** @type {string} */
SMSTemplateDefinitionId;
/** @type {string} */
UpdateTemplateDefinitionId;
/** @type {number} */
Index;
}
export class InsertNotification {
/** @param {{Notification?:Notification}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {Notification} */
Notification;
}
JavaScript InsertNotification DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /api/notification/insert HTTP/1.1
Host: pfapi.pstpf.com.au
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
Notification:
{
NotificationGroupName: String,
SuiteName: String,
Roles:
[
{
RoleName: String
}
],
RolesToDisplay: String,
Name: String,
Description: String,
IsMandatory: False,
IsCardinality: False,
IsSystem: False,
IsAudit: False,
IsVisibleToRecipients: False,
IsSingleUse: False,
Email: False,
EmailDefault: False,
EmailTemplateBody: String,
EmailSubject: String,
SMS: False,
SMSDefault: False,
SMSTemplateBody: String,
UpdateNotification: False,
UpdateNotificationDefault: False,
UpdateTemplateBody: String,
UpdateSubject: String,
Push: False,
PushDefault: False,
Phone: False,
PhoneDefault: False,
RecordStatus: String,
Index: 0
}
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
}