Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Vlad Bukhanets
/
immoscout24-api-php
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Merge Requests
0
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
95628a5c
authored
2019-11-06 14:11:17 +0100
by
fehrlich
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
added getDomain
1 parent
c51ee11c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletions
src/ImmoScoutAPI.php
src/ImmoScoutAPI.php
View file @
95628a5
...
...
@@ -164,13 +164,25 @@ abstract class ImmoScoutAPI extends GuzzleClient
}
/**
* get is24 domain depending on the sandbox.
*
* @return string base url
*/
public
function
getDomain
()
{
return
$this
->
isSandbox
?
'sandbox-immobilienscout24.de'
:
'immobilienscout24.de'
;
}
/**
* get base api url depending on the sandbox.
*
* @return string base url
*/
private
function
getBaseUrl
()
{
return
$this
->
isSandbox
?
'https://rest.sandbox-immobilienscout24.de/restapi/'
:
'https://rest.immobilienscout24.de/restapi/'
;
$domain
=
$this
->
getDomain
();
return
'https://rest.'
.
$domain
.
'/restapi/'
;
}
/**
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment