| All Verbs | /api/contacts/{ContactId}/links |
|---|
"use strict";
export class UserRoleModel {
/** @param {{ContactRoleId?:string,RoleId?:string,RoleName?:string,RolePrimaryImageURL?:string,RolePrimaryImageThumbnailURL?:string,RolePrimaryImageId?:string,StartDate?:string,EndDate?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/**
* @type {string}
* @description The Contact Role Id, that links the Contact to their role. */
ContactRoleId;
/**
* @type {string}
* @description The Role Id. */
RoleId;
/**
* @type {string}
* @description The role name. */
RoleName;
/**
* @type {string}
* @description The URL of the role's image icon. */
RolePrimaryImageURL;
/**
* @type {string}
* @description The URL of the role's thumbnail image icon. */
RolePrimaryImageThumbnailURL;
/**
* @type {string}
* @description The Guid of the role's media file containing the image icon details. */
RolePrimaryImageId;
/**
* @type {string}
* @description The date the contact started having this role. */
StartDate;
/**
* @type {?string}
* @description The date the contact will end having this role. */
EndDate;
}
export class UserContactConnectionModel {
/** @param {{ContactRoleId?:string,ContactRoleName?:string,ContactListItemRoleId?:string,ContactRolePrimaryImageURL?:string,ContactRolePrimaryImageThumbnailURL?:string,ContactRolePrimaryImageId?:string,ConnectionContactId?:string,ConnectionContactName?:string,ConnectionContactRoleName?:string,ConnectionContactRoleId?:string,ConnectionContactListItemRoleId?:string,ContactTypeName?:string,ConnectionContactPhotoURL?:string,IsContactLicenseeRole?:boolean,IsConnectionLicenseeRole?:boolean,ConnectionStatusName?:string,ConnectionStatusId?:string,ConnectionId?:string,ConnectionRequestId?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/**
* @type {string}
* @description The Contact Role Id, that links the Contact to their role. */
ContactRoleId;
/**
* @type {string}
* @description The role name. */
ContactRoleName;
/**
* @type {string}
* @description The list item role Id. */
ContactListItemRoleId;
/**
* @type {string}
* @description The URL of the contact role's image icon. */
ContactRolePrimaryImageURL;
/**
* @type {string}
* @description The URL of the contact role's thumbnail image icon. */
ContactRolePrimaryImageThumbnailURL;
/**
* @type {string}
* @description The Guid of the contact role's media file containing the image icon details. */
ContactRolePrimaryImageId;
/**
* @type {string}
* @description The connected contacts Id. (licensee) */
ConnectionContactId;
/**
* @type {string}
* @description The connected contacts Full Name. */
ConnectionContactName;
/**
* @type {string}
* @description The connected contacts role. */
ConnectionContactRoleName;
/**
* @type {string}
* @description The connected contacts role Id. */
ConnectionContactRoleId;
/**
* @type {string}
* @description The connected contacts list item role Id. */
ConnectionContactListItemRoleId;
/**
* @type {string}
* @description The Contacts Type. */
ContactTypeName;
/**
* @type {string}
* @description The URL to the Connected Contacts Photo. */
ConnectionContactPhotoURL;
/**
* @type {boolean}
* @description . */
IsContactLicenseeRole;
/**
* @type {boolean}
* @description If the connection is as a licensee this is true. */
IsConnectionLicenseeRole;
/**
* @type {string}
* @description The status of the connection with the contact. */
ConnectionStatusName;
/**
* @type {string}
* @description The status Id of the connection with the contact. */
ConnectionStatusId;
/**
* @type {string}
* @description The ContactRoleConnectionId of an active connection with the contact. */
ConnectionId;
/**
* @type {string}
* @description The ContactRoleConnectionRequest of a pending connection with the contact. */
ConnectionRequestId;
}
export class ContactEmailAddress {
/** @param {{ContactId?:string,ContactName?:string,EmailAddress?:string,ContactPhotoURL?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/**
* @type {string}
* @description The Contact Id of the contact. */
ContactId;
/**
* @type {string}
* @description The Contact Full Name */
ContactName;
/**
* @type {string}
* @description The Contact Email Address. */
EmailAddress;
/**
* @type {string}
* @description The Contact Photo URL */
ContactPhotoURL;
}
export class ContactConnectedLinksResponse {
/** @param {{Roles?:UserRoleModel[],ContactConnections?:UserContactConnectionModel[],EmailAddressBook?:ContactEmailAddress[],ResponseStatus?:ResponseStatus}} [init] */
constructor(init) { Object.assign(this, init) }
/**
* @type {UserRoleModel[]}
* @description A list of roles assigned to the contact/user. */
Roles;
/**
* @type {UserContactConnectionModel[]}
* @description A list of contact connections assigned to the contact/user. */
ContactConnections;
/**
* @type {ContactEmailAddress[]}
* @description A list of connected contacts and their email addresses. */
EmailAddressBook;
/** @type {ResponseStatus} */
ResponseStatus;
}
export class ContactConnectedLinks {
/** @param {{ContactId?:string}} [init] */
constructor(init) { Object.assign(this, init) }
/** @type {string} */
ContactId;
}
JavaScript ContactConnectedLinks DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /api/contacts/{ContactId}/links HTTP/1.1
Host: pfapi.pstpf.com.au
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"ContactId":"00000000-0000-0000-0000-000000000000"}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length
{"Roles":[{"ContactRoleId":"00000000-0000-0000-0000-000000000000","RoleId":"00000000-0000-0000-0000-000000000000","RoleName":"String","RolePrimaryImageURL":"String","RolePrimaryImageThumbnailURL":"String","RolePrimaryImageId":"00000000-0000-0000-0000-000000000000","StartDate":"0001-01-01T00:00:00.0000000","EndDate":"0001-01-01T00:00:00.0000000"}],"ContactConnections":[{"ContactRoleId":"00000000-0000-0000-0000-000000000000","ContactRoleName":"String","ContactListItemRoleId":"00000000-0000-0000-0000-000000000000","ContactRolePrimaryImageURL":"String","ContactRolePrimaryImageThumbnailURL":"String","ContactRolePrimaryImageId":"00000000-0000-0000-0000-000000000000","ConnectionContactId":"00000000-0000-0000-0000-000000000000","ConnectionContactName":"String","ConnectionContactRoleName":"String","ConnectionContactRoleId":"00000000-0000-0000-0000-000000000000","ConnectionContactListItemRoleId":"00000000-0000-0000-0000-000000000000","ContactTypeName":"String","ConnectionContactPhotoURL":"String","IsContactLicenseeRole":false,"IsConnectionLicenseeRole":false,"ConnectionStatusName":"String","ConnectionStatusId":"00000000-0000-0000-0000-000000000000","ConnectionId":"00000000-0000-0000-0000-000000000000","ConnectionRequestId":"00000000-0000-0000-0000-000000000000"}],"EmailAddressBook":[{"ContactId":"00000000-0000-0000-0000-000000000000","ContactName":"String","EmailAddress":"String","ContactPhotoURL":"String"}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}