PHP Класс Intercom\IntercomClient

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$admins IntercomAdmins
$bulk IntercomBulk
$companies IntercomCompanies
$conversations IntercomConversations
$counts IntercomCounts
$events IntercomEvents
$leads IntercomLeads
$messages IntercomMessages
$segments IntercomSegments
$tags IntercomTags
$users IntercomUsers

Защищенные свойства (Protected)

Свойство Тип Описание
$passwordPart API password authentication
$usernamePart API user authentication

Открытые методы

Метод Описание
__construct ( string $usernamePart, string $passwordPart ) IntercomClient constructor.
delete ( string $endpoint, string $json ) : mixed Sends DELETE request to Intercom API.
get ( string $endpoint, string $query ) : mixed
getAuth ( ) : array Returns authentication parameters.
nextPage ( array $pages ) : mixed Returns next page of the result.
post ( string $endpoint, string $json ) : mixed Sends POST request to Intercom API.
setClient ( Client $client ) Sets GuzzleHttp client.

Приватные методы

Метод Описание
handleResponse ( Response $response ) : mixed
setDefaultClient ( )

Описание методов

__construct() публичный метод

IntercomClient constructor.
public __construct ( string $usernamePart, string $passwordPart )
$usernamePart string App ID.
$passwordPart string Api Key.

delete() публичный метод

Sends DELETE request to Intercom API.
public delete ( string $endpoint, string $json ) : mixed
$endpoint string
$json string
Результат mixed

get() публичный метод

public get ( string $endpoint, string $query ) : mixed
$endpoint string
$query string
Результат mixed

getAuth() публичный метод

Returns authentication parameters.
public getAuth ( ) : array
Результат array

nextPage() публичный метод

Returns next page of the result.
public nextPage ( array $pages ) : mixed
$pages array
Результат mixed

post() публичный метод

Sends POST request to Intercom API.
public post ( string $endpoint, string $json ) : mixed
$endpoint string
$json string
Результат mixed

setClient() публичный метод

Sets GuzzleHttp client.
public setClient ( Client $client )
$client GuzzleHttp\Client

Описание свойств

$admins публичное свойство

public IntercomAdmins,intercom $admins
Результат IntercomAdmins

$bulk публичное свойство

public IntercomBulk,intercom $bulk
Результат IntercomBulk

$companies публичное свойство

public IntercomCompanies,intercom $companies
Результат IntercomCompanies

$conversations публичное свойство

public IntercomConversations,intercom $conversations
Результат IntercomConversations

$counts публичное свойство

public IntercomCounts,intercom $counts
Результат IntercomCounts

$events публичное свойство

public IntercomEvents,intercom $events
Результат IntercomEvents

$leads публичное свойство

public IntercomLeads,intercom $leads
Результат IntercomLeads

$messages публичное свойство

public IntercomMessages,intercom $messages
Результат IntercomMessages

$passwordPart защищенное свойство

API password authentication
protected $passwordPart

$segments публичное свойство

public IntercomSegments,intercom $segments
Результат IntercomSegments

$tags публичное свойство

public IntercomTags,intercom $tags
Результат IntercomTags

$usernamePart защищенное свойство

API user authentication
protected $usernamePart

$users публичное свойство

public IntercomUsers,intercom $users
Результат IntercomUsers