Documentation

Crowdin
in package

Class Crowdin

Table of Contents

Properties

$responseErrorHandler  : ResponseErrorHandlerInterface
$accessToken  : string
$apis  : array<string|int, mixed>
$baseUri  : string
$client  : CrowdinHttpClientInterface
$isEnterprise  : bool
$organization  : string
$services  : array<string|int, mixed>
$servicesEnterprise  : mixed

Methods

apiRequest()  : mixed
getAccessToken()  : string
getBaseUri()  : string
getClient()  : CrowdinHttpClientInterface
getResponseErrorHandler()  : ResponseErrorHandlerInterface
setAccessToken()  : void
setBaseUri()  : void
setClient()  : void
setOrganization()  : void
setResponseErrorHandler()  : void
getFullUrl()  : string
request()  : mixed
updateBaseUri()  : self

Properties

$responseErrorHandler

public ResponseErrorHandlerInterface $responseErrorHandler

$accessToken

protected string $accessToken

$apis

protected array<string|int, mixed> $apis = []

$baseUri

protected string $baseUri = 'https://api.crowdin.com/api/v2'

$client

protected CrowdinHttpClientInterface $client

$isEnterprise

protected bool $isEnterprise = false

$organization

protected string $organization

$services

protected array<string|int, mixed> $services = ['storage', 'language', 'project', 'task', 'issue', 'branch', 'glossary', 'stringsExporterSetting', 'stringTranslation', 'stringComment', 'directory', 'label', 'user', 'screenshot', 'file', 'machineTranslationEngine', 'report', 'sourceString', 'translationMemory', 'webhook', 'translation', 'translationStatus', 'distribution', 'bundle', 'notification', 'organizationWebhook']

$servicesEnterprise

protected mixed $servicesEnterprise = ['storage', 'language', 'group', 'project', 'task', 'issue', 'branch', 'glossary', 'stringsExporterSetting', 'stringTranslation', 'stringTranslationApproval', 'stringComment', 'directory', 'label', 'vendor', 'user', 'screenshot', 'workflowTemplate', 'workflowStep', 'file', 'machineTranslationEngine', 'report', 'sourceString', 'translationMemory', 'webhook', 'translation', 'translationStatus', 'distribution', 'team', 'teamMember', 'bundle', 'notification', 'organizationWebhook']

Methods

apiRequest()

public apiRequest(string $method, string $path[, ResponseDecoratorInterface|null $decorator = null ][, array<string|int, mixed> $options = [] ]) : mixed
Parameters
$method : string
$path : string
$decorator : ResponseDecoratorInterface|null = null
$options : array<string|int, mixed> = []

getAccessToken()

public getAccessToken() : string
Return values
string

getBaseUri()

public getBaseUri() : string
Return values
string

getClient()

public getClient() : CrowdinHttpClientInterface
Return values
CrowdinHttpClientInterface

getResponseErrorHandler()

public getResponseErrorHandler() : ResponseErrorHandlerInterface
Return values
ResponseErrorHandlerInterface

setAccessToken()

public setAccessToken(string $accessToken) : void
Parameters
$accessToken : string

setBaseUri()

public setBaseUri(string $baseUri) : void
Parameters
$baseUri : string

setClient()

public setClient(CrowdinHttpClientInterface $client) : void
Parameters
$client : CrowdinHttpClientInterface

setOrganization()

public setOrganization(string|null $organization) : void
Parameters
$organization : string|null

setResponseErrorHandler()

public setResponseErrorHandler(ResponseErrorHandlerInterface $responseErrorHandler) : void
Parameters
$responseErrorHandler : ResponseErrorHandlerInterface

getFullUrl()

protected getFullUrl(string $path) : string
Parameters
$path : string
Return values
string

request()

protected request(string $method, string $uri[, array<string|int, mixed> $options = [] ]) : mixed
Parameters
$method : string
$uri : string
$options : array<string|int, mixed> = []

updateBaseUri()

protected updateBaseUri() : self
Return values
self

        
On this page

Search results