class Factory (View source)

Factory class with static methods to easily instantiate clients.

Constants

API_BASE_URL

PROXY

GUZZLE_OPTIONS

Methods

static Image
getImageClient(string $organization, string $apiKey, array|string $options = [])

Return an image client.

static User
getUserClient(string|null|array $organization = null, string|null $apiKey = null, array $options = [])

Return a user client.

Details

static Image getImageClient(string $organization, string $apiKey, array|string $options = [])

Return an image client.

Parameters

string $organization

Organization name

string $apiKey

API key

array|string $options

Options like api_base_url or proxy

Return Value

Image

Exceptions

RuntimeException

static User getUserClient(string|null|array $organization = null, string|null $apiKey = null, array $options = [])

Return a user client.

Parameters

string|null|array $organization
string|null $apiKey

API key

array $options

Options like api_base_url or proxy

Return Value

User

Exceptions

RuntimeException