NobrainerWeb\Bilinfo\API\ListingsClient
Synopsis
class ListingsClient
{
- // members
- protected string $baseUrl = 'https://gw.bilinfo.net';
- protected string $endpoint = '/listingapi/api/export';
- protected string $username = '';
- protected string $password = '';
- protected string $contentType = 'application/json';
- protected ResponseInterface $response;
- protected array $params = ;
- // methods
- public void __construct()
- public void setPassword()
- public ListingsClient setUsername()
- public array get()
- protected void request()
- public $this setContentType()
- public ListingsClient setDealerId()
- public ListingsClient addParam()
- public ListingsClient setSinceDays()
Hierarchy
Uses
- SilverStripe\Core\Injector\Injectable
Tasks
Line | Task |
---|---|
99 | do actual request to the API using Guzzle |
Members
protected
- $baseUrl — string
- $contentType
—
string
API supports xml or json - $endpoint — string
- $params
—
array
params set as GET variables on the request - $password — string
- $response — Psr\Http\Message\ResponseInterface
- $username — string
Methods
protected
public
- __construct()
- addParam() — Set GET param
- get() — Gets entire response data as array
- setContentType()
- setDealerId() — Set dealerId in request params
- setPassword()
- setSinceDays()
- setUsername()