// This is Generated Source. import ContactList from "../definitions/ContactList"; import PersonalContactResource from "../definitions/PersonalContactResource"; import PathSegment from "../PathSegment"; export default class Contact extends PathSegment { constructor(prv: PathSegment, id?: string, service?) { super("contact", id, prv, service); } /** *

Required Permissions

PermissionDescription
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

*/ list(query?: ListQuery): Promise { return this._send({ body: undefined, ignoreId: false, method: "get", query: query, }).then((res) => { return res.json(); }); } /** *

Required Permissions

PermissionDescription
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

* return {ApiResponse} */ listRaw(query?: ListQuery): Promise { return this._send({ body: undefined, ignoreId: false, method: "get", query: query, }); } /** *

Required Permissions

PermissionDescription
ContactsCreating, viewing, editing and deleting user personal contacts
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

*/ post(body: PersonalContactResource): Promise { return this._send({ body: body, ignoreId: true, method: "post", query: undefined, }).then((res) => { return res.json(); }); } /** *

Required Permissions

PermissionDescription
ContactsCreating, viewing, editing and deleting user personal contacts
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

* return {ApiResponse} */ postRaw(body: PersonalContactResource): Promise { return this._send({ body: body, ignoreId: true, method: "post", query: undefined, }); } /** *

Required Permissions

PermissionDescription
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

*/ get(): Promise { return this._send({ body: undefined, ignoreId: true, method: "get", query: undefined, }).then((res) => { return res.json(); }); } /** *

Required Permissions

PermissionDescription
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

* return {ApiResponse} */ getRaw(): Promise { return this._send({ body: undefined, ignoreId: true, method: "get", query: undefined, }); } /** *

Required Permissions

PermissionDescription
ContactsCreating, viewing, editing and deleting user personal contacts
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

*/ put(body: PersonalContactResource): Promise { return this._send({ body: body, ignoreId: true, method: "put", query: undefined, }).then((res) => { return res.json(); }); } /** *

Required Permissions

PermissionDescription
ContactsCreating, viewing, editing and deleting user personal contacts
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

* return {ApiResponse} */ putRaw(body: PersonalContactResource): Promise { return this._send({ body: body, ignoreId: true, method: "put", query: undefined, }); } /** *

Required Permissions

PermissionDescription
ContactsCreating, viewing, editing and deleting user personal contacts
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

*/ delete(): Promise { return this._send({ body: undefined, ignoreId: true, method: "delete", query: undefined, }); } /** *

Required Permissions

PermissionDescription
ContactsCreating, viewing, editing and deleting user personal contacts
ReadContactsViewing user personal contacts

Usage Plan Group

Heavy

* return {ApiResponse} */ deleteRaw(): Promise { return this._send({ body: undefined, ignoreId: true, method: "delete", query: undefined, }); } } export interface ListQuery { /** * If specified, only contacts whose First name or Last name start with the mentioned substring are returned. Case-insensitive */ startsWith?: string; /** * Sorts results by the specified property. The default is 'First Name' */ sortBy?: ("FirstName" | "LastName" | "Company")[]; /** * Indicates the page number to retrieve. Only positive number values are allowed. Default value is '1' */ page?: number; /** * Indicates the page size (number of items). If not specified, the value is '100' by default */ perPage?: number; /** * */ phoneNumber?: string[]; }