-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #287 from HubSpot/feature/newDiscoveries
Discoveries for new clients
- Loading branch information
Showing
22 changed files
with
302 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<?php | ||
|
||
namespace HubSpot\Discovery\Cms\Pages; | ||
|
||
use HubSpot\Client\Cms\Pages\Api\LandingPagesApi; | ||
use HubSpot\Client\Cms\Pages\Api\SitePagesApi; | ||
use HubSpot\Discovery\DiscoveryBase; | ||
|
||
/** | ||
* @method LandingPagesApi landingPagesApi() | ||
* @method SitePagesApi sitePagesApi() | ||
*/ | ||
class Discovery extends DiscoveryBase {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<?php | ||
|
||
namespace HubSpot\Discovery\Crm\Lists; | ||
|
||
use HubSpot\Client\Crm\Lists\Api\ListsApi; | ||
use HubSpot\Client\Crm\Lists\Api\MembershipsApi; | ||
use HubSpot\Discovery\DiscoveryBase; | ||
|
||
/** | ||
* @method ListsApi listsApi() | ||
* @method MembershipsApi membershipsApi() | ||
*/ | ||
class Discovery extends DiscoveryBase {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
|
||
namespace HubSpot\Discovery\Crm\Objects\Goals; | ||
|
||
use HubSpot\Client\Crm\Objects\Goals\Api\BasicApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\BatchApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\GDPRApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\PublicObjectApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\SearchApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Configuration; | ||
use HubSpot\Discovery\DiscoveryBase; | ||
|
||
/** | ||
* @method BasicApi basicApi() | ||
* @method BatchApi batchApi() | ||
* @method GDPRApi gdprApi() | ||
* @method PublicObjectApi publicObjectApi() | ||
* @method SearchApi searchApi() | ||
*/ | ||
class Discovery extends DiscoveryBase | ||
{ | ||
public function gdprApi() | ||
{ | ||
$config = $this->config->convertToClientConfig(Configuration::class); | ||
|
||
return new GDPRApi($this->client, $config); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
|
||
namespace HubSpot\Discovery\Crm\Objects\Taxes; | ||
|
||
use HubSpot\Client\Crm\Objects\Taxes\Api\BasicApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\BatchApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\GDPRApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\PublicObjectApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\SearchApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Configuration; | ||
use HubSpot\Discovery\DiscoveryBase; | ||
|
||
/** | ||
* @method BasicApi basicApi() | ||
* @method BatchApi batchApi() | ||
* @method GDPRApi gdprApi() | ||
* @method PublicObjectApi publicObjectApi() | ||
* @method SearchApi searchApi() | ||
*/ | ||
class Discovery extends DiscoveryBase | ||
{ | ||
public function gdprApi() | ||
{ | ||
$config = $this->config->convertToClientConfig(Configuration::class); | ||
|
||
return new GDPRApi($this->client, $config); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<?php | ||
|
||
namespace HubSpot\Discovery\Events\Send; | ||
|
||
use HubSpot\Client\Events\Send\Api\BehavioralEventsTrackingApi; | ||
use HubSpot\Discovery\DiscoveryBase; | ||
|
||
/** | ||
* @method BehavioralEventsTrackingApi behavioralEventsTrackingApi() | ||
*/ | ||
class Discovery extends DiscoveryBase {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<?php | ||
|
||
namespace HubSpot\Discovery\Settings\BusinessUnits; | ||
|
||
use HubSpot\Client\Settings\BusinessUnits\Api\BusinessUnitApi; | ||
use HubSpot\Discovery\DiscoveryBase; | ||
|
||
/** | ||
* @method BusinessUnitApi businessUnitApi() | ||
*/ | ||
class Discovery extends DiscoveryBase {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
|
||
namespace spec\HubSpot\Discovery\Cms\Pages; | ||
|
||
use GuzzleHttp\Client; | ||
use HubSpot\Client\Cms\Pages\Api\LandingPagesApi; | ||
use HubSpot\Client\Cms\Pages\Api\SitePagesApi; | ||
use HubSpot\Config; | ||
use PhpSpec\ObjectBehavior; | ||
|
||
class DiscoverySpec extends ObjectBehavior | ||
{ | ||
public function let(Client $client, Config $config) | ||
{ | ||
$this->beConstructedWith($client, $config); | ||
} | ||
|
||
public function it_is_initializable() | ||
{ | ||
$this->shouldHaveType(\HubSpot\Discovery\Cms\Pages\Discovery::class); | ||
} | ||
|
||
public function it_creates_clients() | ||
{ | ||
$this->landingPagesApi()->shouldHaveType(LandingPagesApi::class); | ||
$this->sitePagesApi()->shouldHaveType(SitePagesApi::class); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
|
||
namespace spec\HubSpot\Discovery\Crm\Lists; | ||
|
||
use GuzzleHttp\Client; | ||
use HubSpot\Client\Crm\Lists\Api\ListsApi; | ||
use HubSpot\Client\Crm\Lists\Api\MembershipsApi; | ||
use HubSpot\Config; | ||
use PhpSpec\ObjectBehavior; | ||
|
||
class DiscoverySpec extends ObjectBehavior | ||
{ | ||
public function let(Client $client, Config $config) | ||
{ | ||
$this->beConstructedWith($client, $config); | ||
} | ||
|
||
public function it_is_initializable() | ||
{ | ||
$this->shouldHaveType(\HubSpot\Discovery\Crm\Lists\Discovery::class); | ||
} | ||
|
||
public function it_creates_clients() | ||
{ | ||
$this->listsApi()->shouldHaveType(ListsApi::class); | ||
$this->membershipsApi()->shouldHaveType(MembershipsApi::class); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
|
||
namespace spec\HubSpot\Discovery\Crm\Objects\Goals; | ||
|
||
use GuzzleHttp\Client; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\BasicApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\BatchApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\GDPRApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\PublicObjectApi; | ||
use HubSpot\Client\Crm\Objects\Goals\Api\SearchApi; | ||
use HubSpot\Config; | ||
use HubSpot\Discovery\Crm\Objects\Goals\Discovery; | ||
use PhpSpec\ObjectBehavior; | ||
|
||
class DiscoverySpec extends ObjectBehavior | ||
{ | ||
public function let(Client $client, Config $config) | ||
{ | ||
$this->beConstructedWith($client, $config); | ||
} | ||
|
||
public function it_is_initializable() | ||
{ | ||
$this->shouldHaveType(Discovery::class); | ||
} | ||
|
||
public function it_creates_clients() | ||
{ | ||
$this->basicApi()->shouldHaveType(BasicApi::class); | ||
$this->batchApi()->shouldHaveType(BatchApi::class); | ||
$this->gdprApi()->shouldHaveType(GDPRApi::class); | ||
$this->publicObjectApi()->shouldHaveType(PublicObjectApi::class); | ||
$this->searchApi()->shouldHaveType(SearchApi::class); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
|
||
namespace spec\HubSpot\Discovery\Crm\Objects\Taxes; | ||
|
||
use GuzzleHttp\Client; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\BasicApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\BatchApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\GDPRApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\PublicObjectApi; | ||
use HubSpot\Client\Crm\Objects\Taxes\Api\SearchApi; | ||
use HubSpot\Config; | ||
use HubSpot\Discovery\Crm\Objects\Taxes\Discovery; | ||
use PhpSpec\ObjectBehavior; | ||
|
||
class DiscoverySpec extends ObjectBehavior | ||
{ | ||
public function let(Client $client, Config $config) | ||
{ | ||
$this->beConstructedWith($client, $config); | ||
} | ||
|
||
public function it_is_initializable() | ||
{ | ||
$this->shouldHaveType(Discovery::class); | ||
} | ||
|
||
public function it_creates_clients() | ||
{ | ||
$this->basicApi()->shouldHaveType(BasicApi::class); | ||
$this->batchApi()->shouldHaveType(BatchApi::class); | ||
$this->gdprApi()->shouldHaveType(GDPRApi::class); | ||
$this->publicObjectApi()->shouldHaveType(PublicObjectApi::class); | ||
$this->searchApi()->shouldHaveType(SearchApi::class); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
|
||
namespace spec\HubSpot\Discovery\Events\Send; | ||
|
||
use GuzzleHttp\Client; | ||
use HubSpot\Client\Events\Send\Api\BehavioralEventsTrackingApi; | ||
use HubSpot\Config; | ||
use PhpSpec\ObjectBehavior; | ||
|
||
class DiscoverySpec extends ObjectBehavior | ||
{ | ||
public function let(Client $client, Config $config) | ||
{ | ||
$this->beConstructedWith($client, $config); | ||
} | ||
|
||
public function it_is_initializable() | ||
{ | ||
$this->shouldHaveType(\HubSpot\Discovery\Events\Send\Discovery::class); | ||
} | ||
|
||
public function it_creates_clients() | ||
{ | ||
$this->behavioralEventsTrackingApi()->shouldHaveType(BehavioralEventsTrackingApi::class); | ||
} | ||
} |
Oops, something went wrong.