WordApiService
in package
Read onlyYes
Used to interact with words API
Table of Contents
Properties
- $httpClient : HttpClientInterface
- $logger : LoggerInterface
- $wordApiUrl : string
Methods
- __construct() : mixed
- getWord() : array<string|int, mixed>
- fetchData() : array<string|int, mixed>
Properties
$httpClient
private
HttpClientInterface
$httpClient
$logger
private
LoggerInterface
$logger
$wordApiUrl
private
string
$wordApiUrl
Methods
__construct()
public
__construct(LoggerInterface $logger, HttpClientInterface $httpClient, string $wordApiUrl) : mixed
Parameters
- $logger : LoggerInterface
- $httpClient : HttpClientInterface
- $wordApiUrl : string
getWord()
public
getWord() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>fetchData()
private
fetchData() : array<string|int, mixed>