-
-
Notifications
You must be signed in to change notification settings - Fork 175
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 #126 from winkelco/main
Add missing parameters to webhook and set nullable fields in contact object
- Loading branch information
Showing
8 changed files
with
230 additions
and
9 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
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,34 @@ | ||
<?php | ||
|
||
namespace Netflie\WhatsAppCloudApi\WebHook\Notification\Support; | ||
|
||
final class Pricing | ||
{ | ||
private PricingCategory $category; | ||
|
||
private string $model; | ||
|
||
private bool $billable; | ||
|
||
public function __construct(string $category, string $model, bool $billable) | ||
{ | ||
$this->category = new PricingCategory($category); | ||
$this->model = $model; | ||
$this->billable = $billable; | ||
} | ||
|
||
public function category(): PricingCategory | ||
{ | ||
return $this->category; | ||
} | ||
|
||
public function model(): string | ||
{ | ||
return $this->model; | ||
} | ||
|
||
public function isBillable(): bool | ||
{ | ||
return $this->billable; | ||
} | ||
} |
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,23 @@ | ||
<?php | ||
|
||
namespace Netflie\WhatsAppCloudApi\WebHook\Notification\Support; | ||
|
||
/** | ||
* @method static PricingCategory AUTHENTICATION() | ||
* @method static PricingCategory MARKETING() | ||
* @method static PricingCategory UTILITY() | ||
* @method static PricingCategory SERVICE() | ||
* @method static PricingCategory REFERRAL_INITIATED() | ||
*/ | ||
final class PricingCategory extends \MyCLabs\Enum\Enum | ||
{ | ||
private const AUTHENTICATION = 'authentication'; | ||
|
||
private const MARKETING = 'marketing'; | ||
|
||
private const UTILITY = 'utility'; | ||
|
||
private const SERVICE = 'service'; | ||
|
||
private const REFERRAL_INITIATED = 'referral_conversion'; | ||
} |
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