Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@
"type": "library",
"description": "RebaseData API client for PHP",
"require": {
"php": ">=7.2"
"php": ">=7.2",
"ext-curl": "*",
"ext-json": "*",
"ext-zip": "*"
},
"require-dev": {
"phpunit/phpunit": "^8",
"ext-zip": "*"
"phpunit/phpunit": "^8"
},
"suggest": {
"ext-zip": "Allows compressed up- and downloads"
Expand Down
7 changes: 6 additions & 1 deletion src/Config/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class Config
public function __construct()
{
$this->protocol = 'https';
$this->host = 'www.rebasedata.com';
$this->host = 'www.rebasedata.com/api/v1';
$this->cacheEnabled = false;
$this->useZipIfAvailable = true;
}
Expand Down Expand Up @@ -86,6 +86,11 @@ public function getCacheEnabled()
return $this->cacheEnabled;
}

public function getUrl(): string
{
return $this->protocol . '://' . $this->host;
}

public function setCacheDirectory($cacheDirectory)
{
if (!is_dir($cacheDirectory)) {
Expand Down
Loading