From b03cca0a0636e558b4540716a01d20a12ebd7935 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Mon, 2 Feb 2026 20:27:02 +0000 Subject: [PATCH] SDK regeneration --- src/Contacts/Traits/Contact.php | 126 ++++++------- src/Contacts/Types/Contact.php | 146 +++++++-------- src/Contacts/Types/ContactsCreateResponse.php | 38 ++-- src/Contacts/Types/ContactsFindResponse.php | 38 ++-- .../Types/ContactsMergeLeadInUserResponse.php | 38 ++-- src/Contacts/Types/ContactsUpdateResponse.php | 38 ++-- .../Types/ShowContactByExternalIdResponse.php | 38 ++-- src/Conversations/Types/Conversation.php | 172 +++++++++--------- src/DataEvents/Types/DataEvent.php | 16 +- src/IntercomClient.php | 4 +- src/Messages/Types/Message.php | 16 +- src/Notes/Types/Note.php | 66 +++---- src/Tickets/Types/Ticket.php | 98 +++++----- src/Types/Visitor.php | 50 ++--- 14 files changed, 442 insertions(+), 442 deletions(-) diff --git a/src/Contacts/Traits/Contact.php b/src/Contacts/Traits/Contact.php index 068664e6..82b4567e 100644 --- a/src/Contacts/Traits/Contact.php +++ b/src/Contacts/Traits/Contact.php @@ -13,21 +13,21 @@ /** * Contacts represent your leads and users in Intercom. * - * @property ?'contact' $type - * @property ?string $id + * @property 'contact' $type + * @property string $id * @property ?string $externalId - * @property ?string $workspaceId - * @property ?string $role + * @property string $workspaceId + * @property string $role * @property ?string $email * @property ?string $emailDomain * @property ?string $phone * @property ?string $name * @property ?int $ownerId - * @property ?bool $hasHardBounced - * @property ?bool $markedEmailAsSpam - * @property ?bool $unsubscribedFromEmails - * @property ?int $createdAt - * @property ?int $updatedAt + * @property bool $hasHardBounced + * @property bool $markedEmailAsSpam + * @property bool $unsubscribedFromEmails + * @property int $createdAt + * @property int $updatedAt * @property ?int $signedUpAt * @property ?int $lastSeenAt * @property ?int $lastRepliedAt @@ -62,16 +62,16 @@ trait Contact { /** - * @var ?'contact' $type The type of object. + * @var 'contact' $type The type of object. */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** - * @var ?string $id The unique identifier for the contact which is given by Intercom. + * @var string $id The unique identifier for the contact which is given by Intercom. */ #[JsonProperty('id')] - private ?string $id; + private string $id; /** * @var ?string $externalId The unique identifier for the contact which is provided by the Client. @@ -80,16 +80,16 @@ trait Contact private ?string $externalId; /** - * @var ?string $workspaceId The id of the workspace which the contact belongs to. + * @var string $workspaceId The id of the workspace which the contact belongs to. */ #[JsonProperty('workspace_id')] - private ?string $workspaceId; + private string $workspaceId; /** - * @var ?string $role The role of the contact. + * @var string $role The role of the contact. */ #[JsonProperty('role')] - private ?string $role; + private string $role; /** * @var ?string $email The contact's email. @@ -122,34 +122,34 @@ trait Contact private ?int $ownerId; /** - * @var ?bool $hasHardBounced Whether the contact has had an email sent to them hard bounce. + * @var bool $hasHardBounced Whether the contact has had an email sent to them hard bounce. */ #[JsonProperty('has_hard_bounced')] - private ?bool $hasHardBounced; + private bool $hasHardBounced; /** - * @var ?bool $markedEmailAsSpam Whether the contact has marked an email sent to them as spam. + * @var bool $markedEmailAsSpam Whether the contact has marked an email sent to them as spam. */ #[JsonProperty('marked_email_as_spam')] - private ?bool $markedEmailAsSpam; + private bool $markedEmailAsSpam; /** - * @var ?bool $unsubscribedFromEmails Whether the contact is unsubscribed from emails. + * @var bool $unsubscribedFromEmails Whether the contact is unsubscribed from emails. */ #[JsonProperty('unsubscribed_from_emails')] - private ?bool $unsubscribedFromEmails; + private bool $unsubscribedFromEmails; /** - * @var ?int $createdAt (UNIX timestamp) The time when the contact was created. + * @var int $createdAt (UNIX timestamp) The time when the contact was created. */ #[JsonProperty('created_at')] - private ?int $createdAt; + private int $createdAt; /** - * @var ?int $updatedAt (UNIX timestamp) The time when the contact was last updated. + * @var int $updatedAt (UNIX timestamp) The time when the contact was last updated. */ #[JsonProperty('updated_at')] - private ?int $updatedAt; + private int $updatedAt; /** * @var ?int $signedUpAt (UNIX timestamp) The time specified for when a contact signed up. @@ -332,34 +332,34 @@ trait Contact private ?ContactSocialProfiles $socialProfiles; /** - * @return ?'contact' + * @return 'contact' */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?'contact' $value + * @param 'contact' $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; } /** - * @return ?string + * @return string */ - public function getId(): ?string + public function getId(): string { return $this->id; } /** - * @param ?string $value + * @param string $value */ - public function setId(?string $value = null): self + public function setId(string $value): self { $this->id = $value; return $this; @@ -383,34 +383,34 @@ public function setExternalId(?string $value = null): self } /** - * @return ?string + * @return string */ - public function getWorkspaceId(): ?string + public function getWorkspaceId(): string { return $this->workspaceId; } /** - * @param ?string $value + * @param string $value */ - public function setWorkspaceId(?string $value = null): self + public function setWorkspaceId(string $value): self { $this->workspaceId = $value; return $this; } /** - * @return ?string + * @return string */ - public function getRole(): ?string + public function getRole(): string { return $this->role; } /** - * @param ?string $value + * @param string $value */ - public function setRole(?string $value = null): self + public function setRole(string $value): self { $this->role = $value; return $this; @@ -502,85 +502,85 @@ public function setOwnerId(?int $value = null): self } /** - * @return ?bool + * @return bool */ - public function getHasHardBounced(): ?bool + public function getHasHardBounced(): bool { return $this->hasHardBounced; } /** - * @param ?bool $value + * @param bool $value */ - public function setHasHardBounced(?bool $value = null): self + public function setHasHardBounced(bool $value): self { $this->hasHardBounced = $value; return $this; } /** - * @return ?bool + * @return bool */ - public function getMarkedEmailAsSpam(): ?bool + public function getMarkedEmailAsSpam(): bool { return $this->markedEmailAsSpam; } /** - * @param ?bool $value + * @param bool $value */ - public function setMarkedEmailAsSpam(?bool $value = null): self + public function setMarkedEmailAsSpam(bool $value): self { $this->markedEmailAsSpam = $value; return $this; } /** - * @return ?bool + * @return bool */ - public function getUnsubscribedFromEmails(): ?bool + public function getUnsubscribedFromEmails(): bool { return $this->unsubscribedFromEmails; } /** - * @param ?bool $value + * @param bool $value */ - public function setUnsubscribedFromEmails(?bool $value = null): self + public function setUnsubscribedFromEmails(bool $value): self { $this->unsubscribedFromEmails = $value; return $this; } /** - * @return ?int + * @return int */ - public function getCreatedAt(): ?int + public function getCreatedAt(): int { return $this->createdAt; } /** - * @param ?int $value + * @param int $value */ - public function setCreatedAt(?int $value = null): self + public function setCreatedAt(int $value): self { $this->createdAt = $value; return $this; } /** - * @return ?int + * @return int */ - public function getUpdatedAt(): ?int + public function getUpdatedAt(): int { return $this->updatedAt; } /** - * @param ?int $value + * @param int $value */ - public function setUpdatedAt(?int $value = null): self + public function setUpdatedAt(int $value): self { $this->updatedAt = $value; return $this; diff --git a/src/Contacts/Types/Contact.php b/src/Contacts/Types/Contact.php index c16c44f3..8da20d34 100644 --- a/src/Contacts/Types/Contact.php +++ b/src/Contacts/Types/Contact.php @@ -17,16 +17,16 @@ class Contact extends JsonSerializableType { /** - * @var ?'contact' $type The type of object. + * @var 'contact' $type The type of object. */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** - * @var ?string $id The unique identifier for the contact which is given by Intercom. + * @var string $id The unique identifier for the contact which is given by Intercom. */ #[JsonProperty('id')] - private ?string $id; + private string $id; /** * @var ?string $externalId The unique identifier for the contact which is provided by the Client. @@ -35,16 +35,16 @@ class Contact extends JsonSerializableType private ?string $externalId; /** - * @var ?string $workspaceId The id of the workspace which the contact belongs to. + * @var string $workspaceId The id of the workspace which the contact belongs to. */ #[JsonProperty('workspace_id')] - private ?string $workspaceId; + private string $workspaceId; /** - * @var ?string $role The role of the contact. + * @var string $role The role of the contact. */ #[JsonProperty('role')] - private ?string $role; + private string $role; /** * @var ?string $email The contact's email. @@ -77,34 +77,34 @@ class Contact extends JsonSerializableType private ?int $ownerId; /** - * @var ?bool $hasHardBounced Whether the contact has had an email sent to them hard bounce. + * @var bool $hasHardBounced Whether the contact has had an email sent to them hard bounce. */ #[JsonProperty('has_hard_bounced')] - private ?bool $hasHardBounced; + private bool $hasHardBounced; /** - * @var ?bool $markedEmailAsSpam Whether the contact has marked an email sent to them as spam. + * @var bool $markedEmailAsSpam Whether the contact has marked an email sent to them as spam. */ #[JsonProperty('marked_email_as_spam')] - private ?bool $markedEmailAsSpam; + private bool $markedEmailAsSpam; /** - * @var ?bool $unsubscribedFromEmails Whether the contact is unsubscribed from emails. + * @var bool $unsubscribedFromEmails Whether the contact is unsubscribed from emails. */ #[JsonProperty('unsubscribed_from_emails')] - private ?bool $unsubscribedFromEmails; + private bool $unsubscribedFromEmails; /** - * @var ?int $createdAt (UNIX timestamp) The time when the contact was created. + * @var int $createdAt (UNIX timestamp) The time when the contact was created. */ #[JsonProperty('created_at')] - private ?int $createdAt; + private int $createdAt; /** - * @var ?int $updatedAt (UNIX timestamp) The time when the contact was last updated. + * @var int $updatedAt (UNIX timestamp) The time when the contact was last updated. */ #[JsonProperty('updated_at')] - private ?int $updatedAt; + private int $updatedAt; /** * @var ?int $signedUpAt (UNIX timestamp) The time specified for when a contact signed up. @@ -288,21 +288,21 @@ class Contact extends JsonSerializableType /** * @param array{ - * type?: ?'contact', - * id?: ?string, + * type: 'contact', + * id: string, + * workspaceId: string, + * role: string, + * hasHardBounced: bool, + * markedEmailAsSpam: bool, + * unsubscribedFromEmails: bool, + * createdAt: int, + * updatedAt: int, * externalId?: ?string, - * workspaceId?: ?string, - * role?: ?string, * email?: ?string, * emailDomain?: ?string, * phone?: ?string, * name?: ?string, * ownerId?: ?int, - * hasHardBounced?: ?bool, - * markedEmailAsSpam?: ?bool, - * unsubscribedFromEmails?: ?bool, - * createdAt?: ?int, - * updatedAt?: ?int, * signedUpAt?: ?int, * lastSeenAt?: ?int, * lastRepliedAt?: ?int, @@ -336,23 +336,23 @@ class Contact extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->externalId = $values['externalId'] ?? null; - $this->workspaceId = $values['workspaceId'] ?? null; - $this->role = $values['role'] ?? null; + $this->workspaceId = $values['workspaceId']; + $this->role = $values['role']; $this->email = $values['email'] ?? null; $this->emailDomain = $values['emailDomain'] ?? null; $this->phone = $values['phone'] ?? null; $this->name = $values['name'] ?? null; $this->ownerId = $values['ownerId'] ?? null; - $this->hasHardBounced = $values['hasHardBounced'] ?? null; - $this->markedEmailAsSpam = $values['markedEmailAsSpam'] ?? null; - $this->unsubscribedFromEmails = $values['unsubscribedFromEmails'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->hasHardBounced = $values['hasHardBounced']; + $this->markedEmailAsSpam = $values['markedEmailAsSpam']; + $this->unsubscribedFromEmails = $values['unsubscribedFromEmails']; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->signedUpAt = $values['signedUpAt'] ?? null; $this->lastSeenAt = $values['lastSeenAt'] ?? null; $this->lastRepliedAt = $values['lastRepliedAt'] ?? null; @@ -386,34 +386,34 @@ public function __construct( } /** - * @return ?'contact' + * @return 'contact' */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?'contact' $value + * @param 'contact' $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; } /** - * @return ?string + * @return string */ - public function getId(): ?string + public function getId(): string { return $this->id; } /** - * @param ?string $value + * @param string $value */ - public function setId(?string $value = null): self + public function setId(string $value): self { $this->id = $value; return $this; @@ -437,34 +437,34 @@ public function setExternalId(?string $value = null): self } /** - * @return ?string + * @return string */ - public function getWorkspaceId(): ?string + public function getWorkspaceId(): string { return $this->workspaceId; } /** - * @param ?string $value + * @param string $value */ - public function setWorkspaceId(?string $value = null): self + public function setWorkspaceId(string $value): self { $this->workspaceId = $value; return $this; } /** - * @return ?string + * @return string */ - public function getRole(): ?string + public function getRole(): string { return $this->role; } /** - * @param ?string $value + * @param string $value */ - public function setRole(?string $value = null): self + public function setRole(string $value): self { $this->role = $value; return $this; @@ -556,85 +556,85 @@ public function setOwnerId(?int $value = null): self } /** - * @return ?bool + * @return bool */ - public function getHasHardBounced(): ?bool + public function getHasHardBounced(): bool { return $this->hasHardBounced; } /** - * @param ?bool $value + * @param bool $value */ - public function setHasHardBounced(?bool $value = null): self + public function setHasHardBounced(bool $value): self { $this->hasHardBounced = $value; return $this; } /** - * @return ?bool + * @return bool */ - public function getMarkedEmailAsSpam(): ?bool + public function getMarkedEmailAsSpam(): bool { return $this->markedEmailAsSpam; } /** - * @param ?bool $value + * @param bool $value */ - public function setMarkedEmailAsSpam(?bool $value = null): self + public function setMarkedEmailAsSpam(bool $value): self { $this->markedEmailAsSpam = $value; return $this; } /** - * @return ?bool + * @return bool */ - public function getUnsubscribedFromEmails(): ?bool + public function getUnsubscribedFromEmails(): bool { return $this->unsubscribedFromEmails; } /** - * @param ?bool $value + * @param bool $value */ - public function setUnsubscribedFromEmails(?bool $value = null): self + public function setUnsubscribedFromEmails(bool $value): self { $this->unsubscribedFromEmails = $value; return $this; } /** - * @return ?int + * @return int */ - public function getCreatedAt(): ?int + public function getCreatedAt(): int { return $this->createdAt; } /** - * @param ?int $value + * @param int $value */ - public function setCreatedAt(?int $value = null): self + public function setCreatedAt(int $value): self { $this->createdAt = $value; return $this; } /** - * @return ?int + * @return int */ - public function getUpdatedAt(): ?int + public function getUpdatedAt(): int { return $this->updatedAt; } /** - * @param ?int $value + * @param int $value */ - public function setUpdatedAt(?int $value = null): self + public function setUpdatedAt(int $value): self { $this->updatedAt = $value; return $this; diff --git a/src/Contacts/Types/ContactsCreateResponse.php b/src/Contacts/Types/ContactsCreateResponse.php index c01ea0b4..f4cd92b5 100644 --- a/src/Contacts/Types/ContactsCreateResponse.php +++ b/src/Contacts/Types/ContactsCreateResponse.php @@ -23,21 +23,21 @@ class ContactsCreateResponse extends JsonSerializableType /** * @param array{ - * type?: ?'contact', - * id?: ?string, + * type: 'contact', + * id: string, + * workspaceId: string, + * role: string, + * hasHardBounced: bool, + * markedEmailAsSpam: bool, + * unsubscribedFromEmails: bool, + * createdAt: int, + * updatedAt: int, * externalId?: ?string, - * workspaceId?: ?string, - * role?: ?string, * email?: ?string, * emailDomain?: ?string, * phone?: ?string, * name?: ?string, * ownerId?: ?int, - * hasHardBounced?: ?bool, - * markedEmailAsSpam?: ?bool, - * unsubscribedFromEmails?: ?bool, - * createdAt?: ?int, - * updatedAt?: ?int, * signedUpAt?: ?int, * lastSeenAt?: ?int, * lastRepliedAt?: ?int, @@ -72,23 +72,23 @@ class ContactsCreateResponse extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->externalId = $values['externalId'] ?? null; - $this->workspaceId = $values['workspaceId'] ?? null; - $this->role = $values['role'] ?? null; + $this->workspaceId = $values['workspaceId']; + $this->role = $values['role']; $this->email = $values['email'] ?? null; $this->emailDomain = $values['emailDomain'] ?? null; $this->phone = $values['phone'] ?? null; $this->name = $values['name'] ?? null; $this->ownerId = $values['ownerId'] ?? null; - $this->hasHardBounced = $values['hasHardBounced'] ?? null; - $this->markedEmailAsSpam = $values['markedEmailAsSpam'] ?? null; - $this->unsubscribedFromEmails = $values['unsubscribedFromEmails'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->hasHardBounced = $values['hasHardBounced']; + $this->markedEmailAsSpam = $values['markedEmailAsSpam']; + $this->unsubscribedFromEmails = $values['unsubscribedFromEmails']; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->signedUpAt = $values['signedUpAt'] ?? null; $this->lastSeenAt = $values['lastSeenAt'] ?? null; $this->lastRepliedAt = $values['lastRepliedAt'] ?? null; diff --git a/src/Contacts/Types/ContactsFindResponse.php b/src/Contacts/Types/ContactsFindResponse.php index c108e48e..d5c61369 100644 --- a/src/Contacts/Types/ContactsFindResponse.php +++ b/src/Contacts/Types/ContactsFindResponse.php @@ -23,21 +23,21 @@ class ContactsFindResponse extends JsonSerializableType /** * @param array{ - * type?: ?'contact', - * id?: ?string, + * type: 'contact', + * id: string, + * workspaceId: string, + * role: string, + * hasHardBounced: bool, + * markedEmailAsSpam: bool, + * unsubscribedFromEmails: bool, + * createdAt: int, + * updatedAt: int, * externalId?: ?string, - * workspaceId?: ?string, - * role?: ?string, * email?: ?string, * emailDomain?: ?string, * phone?: ?string, * name?: ?string, * ownerId?: ?int, - * hasHardBounced?: ?bool, - * markedEmailAsSpam?: ?bool, - * unsubscribedFromEmails?: ?bool, - * createdAt?: ?int, - * updatedAt?: ?int, * signedUpAt?: ?int, * lastSeenAt?: ?int, * lastRepliedAt?: ?int, @@ -72,23 +72,23 @@ class ContactsFindResponse extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->externalId = $values['externalId'] ?? null; - $this->workspaceId = $values['workspaceId'] ?? null; - $this->role = $values['role'] ?? null; + $this->workspaceId = $values['workspaceId']; + $this->role = $values['role']; $this->email = $values['email'] ?? null; $this->emailDomain = $values['emailDomain'] ?? null; $this->phone = $values['phone'] ?? null; $this->name = $values['name'] ?? null; $this->ownerId = $values['ownerId'] ?? null; - $this->hasHardBounced = $values['hasHardBounced'] ?? null; - $this->markedEmailAsSpam = $values['markedEmailAsSpam'] ?? null; - $this->unsubscribedFromEmails = $values['unsubscribedFromEmails'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->hasHardBounced = $values['hasHardBounced']; + $this->markedEmailAsSpam = $values['markedEmailAsSpam']; + $this->unsubscribedFromEmails = $values['unsubscribedFromEmails']; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->signedUpAt = $values['signedUpAt'] ?? null; $this->lastSeenAt = $values['lastSeenAt'] ?? null; $this->lastRepliedAt = $values['lastRepliedAt'] ?? null; diff --git a/src/Contacts/Types/ContactsMergeLeadInUserResponse.php b/src/Contacts/Types/ContactsMergeLeadInUserResponse.php index 5c689107..3b369602 100644 --- a/src/Contacts/Types/ContactsMergeLeadInUserResponse.php +++ b/src/Contacts/Types/ContactsMergeLeadInUserResponse.php @@ -23,21 +23,21 @@ class ContactsMergeLeadInUserResponse extends JsonSerializableType /** * @param array{ - * type?: ?'contact', - * id?: ?string, + * type: 'contact', + * id: string, + * workspaceId: string, + * role: string, + * hasHardBounced: bool, + * markedEmailAsSpam: bool, + * unsubscribedFromEmails: bool, + * createdAt: int, + * updatedAt: int, * externalId?: ?string, - * workspaceId?: ?string, - * role?: ?string, * email?: ?string, * emailDomain?: ?string, * phone?: ?string, * name?: ?string, * ownerId?: ?int, - * hasHardBounced?: ?bool, - * markedEmailAsSpam?: ?bool, - * unsubscribedFromEmails?: ?bool, - * createdAt?: ?int, - * updatedAt?: ?int, * signedUpAt?: ?int, * lastSeenAt?: ?int, * lastRepliedAt?: ?int, @@ -72,23 +72,23 @@ class ContactsMergeLeadInUserResponse extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->externalId = $values['externalId'] ?? null; - $this->workspaceId = $values['workspaceId'] ?? null; - $this->role = $values['role'] ?? null; + $this->workspaceId = $values['workspaceId']; + $this->role = $values['role']; $this->email = $values['email'] ?? null; $this->emailDomain = $values['emailDomain'] ?? null; $this->phone = $values['phone'] ?? null; $this->name = $values['name'] ?? null; $this->ownerId = $values['ownerId'] ?? null; - $this->hasHardBounced = $values['hasHardBounced'] ?? null; - $this->markedEmailAsSpam = $values['markedEmailAsSpam'] ?? null; - $this->unsubscribedFromEmails = $values['unsubscribedFromEmails'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->hasHardBounced = $values['hasHardBounced']; + $this->markedEmailAsSpam = $values['markedEmailAsSpam']; + $this->unsubscribedFromEmails = $values['unsubscribedFromEmails']; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->signedUpAt = $values['signedUpAt'] ?? null; $this->lastSeenAt = $values['lastSeenAt'] ?? null; $this->lastRepliedAt = $values['lastRepliedAt'] ?? null; diff --git a/src/Contacts/Types/ContactsUpdateResponse.php b/src/Contacts/Types/ContactsUpdateResponse.php index c4a2e146..9bc3e580 100644 --- a/src/Contacts/Types/ContactsUpdateResponse.php +++ b/src/Contacts/Types/ContactsUpdateResponse.php @@ -23,21 +23,21 @@ class ContactsUpdateResponse extends JsonSerializableType /** * @param array{ - * type?: ?'contact', - * id?: ?string, + * type: 'contact', + * id: string, + * workspaceId: string, + * role: string, + * hasHardBounced: bool, + * markedEmailAsSpam: bool, + * unsubscribedFromEmails: bool, + * createdAt: int, + * updatedAt: int, * externalId?: ?string, - * workspaceId?: ?string, - * role?: ?string, * email?: ?string, * emailDomain?: ?string, * phone?: ?string, * name?: ?string, * ownerId?: ?int, - * hasHardBounced?: ?bool, - * markedEmailAsSpam?: ?bool, - * unsubscribedFromEmails?: ?bool, - * createdAt?: ?int, - * updatedAt?: ?int, * signedUpAt?: ?int, * lastSeenAt?: ?int, * lastRepliedAt?: ?int, @@ -72,23 +72,23 @@ class ContactsUpdateResponse extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->externalId = $values['externalId'] ?? null; - $this->workspaceId = $values['workspaceId'] ?? null; - $this->role = $values['role'] ?? null; + $this->workspaceId = $values['workspaceId']; + $this->role = $values['role']; $this->email = $values['email'] ?? null; $this->emailDomain = $values['emailDomain'] ?? null; $this->phone = $values['phone'] ?? null; $this->name = $values['name'] ?? null; $this->ownerId = $values['ownerId'] ?? null; - $this->hasHardBounced = $values['hasHardBounced'] ?? null; - $this->markedEmailAsSpam = $values['markedEmailAsSpam'] ?? null; - $this->unsubscribedFromEmails = $values['unsubscribedFromEmails'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->hasHardBounced = $values['hasHardBounced']; + $this->markedEmailAsSpam = $values['markedEmailAsSpam']; + $this->unsubscribedFromEmails = $values['unsubscribedFromEmails']; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->signedUpAt = $values['signedUpAt'] ?? null; $this->lastSeenAt = $values['lastSeenAt'] ?? null; $this->lastRepliedAt = $values['lastRepliedAt'] ?? null; diff --git a/src/Contacts/Types/ShowContactByExternalIdResponse.php b/src/Contacts/Types/ShowContactByExternalIdResponse.php index 14078506..9e7bd0c3 100644 --- a/src/Contacts/Types/ShowContactByExternalIdResponse.php +++ b/src/Contacts/Types/ShowContactByExternalIdResponse.php @@ -23,21 +23,21 @@ class ShowContactByExternalIdResponse extends JsonSerializableType /** * @param array{ - * type?: ?'contact', - * id?: ?string, + * type: 'contact', + * id: string, + * workspaceId: string, + * role: string, + * hasHardBounced: bool, + * markedEmailAsSpam: bool, + * unsubscribedFromEmails: bool, + * createdAt: int, + * updatedAt: int, * externalId?: ?string, - * workspaceId?: ?string, - * role?: ?string, * email?: ?string, * emailDomain?: ?string, * phone?: ?string, * name?: ?string, * ownerId?: ?int, - * hasHardBounced?: ?bool, - * markedEmailAsSpam?: ?bool, - * unsubscribedFromEmails?: ?bool, - * createdAt?: ?int, - * updatedAt?: ?int, * signedUpAt?: ?int, * lastSeenAt?: ?int, * lastRepliedAt?: ?int, @@ -72,23 +72,23 @@ class ShowContactByExternalIdResponse extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->externalId = $values['externalId'] ?? null; - $this->workspaceId = $values['workspaceId'] ?? null; - $this->role = $values['role'] ?? null; + $this->workspaceId = $values['workspaceId']; + $this->role = $values['role']; $this->email = $values['email'] ?? null; $this->emailDomain = $values['emailDomain'] ?? null; $this->phone = $values['phone'] ?? null; $this->name = $values['name'] ?? null; $this->ownerId = $values['ownerId'] ?? null; - $this->hasHardBounced = $values['hasHardBounced'] ?? null; - $this->markedEmailAsSpam = $values['markedEmailAsSpam'] ?? null; - $this->unsubscribedFromEmails = $values['unsubscribedFromEmails'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->hasHardBounced = $values['hasHardBounced']; + $this->markedEmailAsSpam = $values['markedEmailAsSpam']; + $this->unsubscribedFromEmails = $values['unsubscribedFromEmails']; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->signedUpAt = $values['signedUpAt'] ?? null; $this->lastSeenAt = $values['lastSeenAt'] ?? null; $this->lastRepliedAt = $values['lastRepliedAt'] ?? null; diff --git a/src/Conversations/Types/Conversation.php b/src/Conversations/Types/Conversation.php index 90fa29bd..34e7aa48 100644 --- a/src/Conversations/Types/Conversation.php +++ b/src/Conversations/Types/Conversation.php @@ -26,16 +26,16 @@ class Conversation extends JsonSerializableType { /** - * @var ?string $type Always conversation. + * @var string $type Always conversation. */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** - * @var ?string $id The id representing the conversation. + * @var string $id The id representing the conversation. */ #[JsonProperty('id')] - private ?string $id; + private string $id; /** * @var ?string $title The title given to the conversation. @@ -44,16 +44,16 @@ class Conversation extends JsonSerializableType private ?string $title; /** - * @var ?int $createdAt The time the conversation was created. + * @var int $createdAt The time the conversation was created. */ #[JsonProperty('created_at')] - private ?int $createdAt; + private int $createdAt; /** - * @var ?int $updatedAt The last time the conversation was updated. + * @var int $updatedAt The last time the conversation was updated. */ #[JsonProperty('updated_at')] - private ?int $updatedAt; + private int $updatedAt; /** * @var ?int $waitingSince The last time a Contact responded to an Admin. In other words, the time a customer started waiting for a response. Set to null if last reply is from an Admin. @@ -68,22 +68,22 @@ class Conversation extends JsonSerializableType private ?int $snoozedUntil; /** - * @var ?bool $open Indicates whether a conversation is open (true) or closed (false). + * @var bool $open Indicates whether a conversation is open (true) or closed (false). */ #[JsonProperty('open')] - private ?bool $open; + private bool $open; /** - * @var ?value-of $state Can be set to "open", "closed" or "snoozed". + * @var value-of $state Can be set to "open", "closed" or "snoozed". */ #[JsonProperty('state')] - private ?string $state; + private string $state; /** - * @var ?bool $read Indicates whether a conversation has been read. + * @var bool $read Indicates whether a conversation has been read. */ #[JsonProperty('read')] - private ?bool $read; + private bool $read; /** * @var ?value-of $priority If marked as priority, it will return priority or else not_priority. @@ -122,16 +122,16 @@ class Conversation extends JsonSerializableType private ?ConversationRating $conversationRating; /** - * @var ?ConversationSource $source + * @var ConversationSource $source */ #[JsonProperty('source')] - private ?ConversationSource $source; + private ConversationSource $source; /** - * @var ?ConversationContacts $contacts + * @var ConversationContacts $contacts */ #[JsonProperty('contacts')] - private ?ConversationContacts $contacts; + private ConversationContacts $contacts; /** * @var ?ConversationTeammates $teammates @@ -140,7 +140,7 @@ class Conversation extends JsonSerializableType private ?ConversationTeammates $teammates; /** - * @var ?array $customAttributes */ #[JsonProperty('custom_attributes'), ArrayType(['string' => new Union('string', 'integer', 'datetime', CustomObjectInstanceList::class)])] - private ?array $customAttributes; + private array $customAttributes; /** * @var ?ConversationFirstContactReply $firstContactReply @@ -194,31 +194,31 @@ class Conversation extends JsonSerializableType /** * @param array{ - * type?: ?string, - * id?: ?string, + * type: string, + * id: string, + * createdAt: int, + * updatedAt: int, + * open: bool, + * state: value-of, + * read: bool, + * source: ConversationSource, + * contacts: ConversationContacts, + * customAttributes: array, * title?: ?string, - * createdAt?: ?int, - * updatedAt?: ?int, * waitingSince?: ?int, * snoozedUntil?: ?int, - * open?: ?bool, - * state?: ?value-of, - * read?: ?bool, * priority?: ?value-of, * adminAssigneeId?: ?int, * teamAssigneeId?: ?string, * companyId?: ?string, * tags?: ?Tags, * conversationRating?: ?ConversationRating, - * source?: ?ConversationSource, - * contacts?: ?ConversationContacts, * teammates?: ?ConversationTeammates, - * customAttributes?: ?array, * firstContactReply?: ?ConversationFirstContactReply, * slaApplied?: ?SlaApplied, * statistics?: ?ConversationStatistics, @@ -229,28 +229,28 @@ class Conversation extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; $this->title = $values['title'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; - $this->updatedAt = $values['updatedAt'] ?? null; + $this->createdAt = $values['createdAt']; + $this->updatedAt = $values['updatedAt']; $this->waitingSince = $values['waitingSince'] ?? null; $this->snoozedUntil = $values['snoozedUntil'] ?? null; - $this->open = $values['open'] ?? null; - $this->state = $values['state'] ?? null; - $this->read = $values['read'] ?? null; + $this->open = $values['open']; + $this->state = $values['state']; + $this->read = $values['read']; $this->priority = $values['priority'] ?? null; $this->adminAssigneeId = $values['adminAssigneeId'] ?? null; $this->teamAssigneeId = $values['teamAssigneeId'] ?? null; $this->companyId = $values['companyId'] ?? null; $this->tags = $values['tags'] ?? null; $this->conversationRating = $values['conversationRating'] ?? null; - $this->source = $values['source'] ?? null; - $this->contacts = $values['contacts'] ?? null; + $this->source = $values['source']; + $this->contacts = $values['contacts']; $this->teammates = $values['teammates'] ?? null; - $this->customAttributes = $values['customAttributes'] ?? null; + $this->customAttributes = $values['customAttributes']; $this->firstContactReply = $values['firstContactReply'] ?? null; $this->slaApplied = $values['slaApplied'] ?? null; $this->statistics = $values['statistics'] ?? null; @@ -261,34 +261,34 @@ public function __construct( } /** - * @return ?string + * @return string */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?string $value + * @param string $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; } /** - * @return ?string + * @return string */ - public function getId(): ?string + public function getId(): string { return $this->id; } /** - * @param ?string $value + * @param string $value */ - public function setId(?string $value = null): self + public function setId(string $value): self { $this->id = $value; return $this; @@ -312,34 +312,34 @@ public function setTitle(?string $value = null): self } /** - * @return ?int + * @return int */ - public function getCreatedAt(): ?int + public function getCreatedAt(): int { return $this->createdAt; } /** - * @param ?int $value + * @param int $value */ - public function setCreatedAt(?int $value = null): self + public function setCreatedAt(int $value): self { $this->createdAt = $value; return $this; } /** - * @return ?int + * @return int */ - public function getUpdatedAt(): ?int + public function getUpdatedAt(): int { return $this->updatedAt; } /** - * @param ?int $value + * @param int $value */ - public function setUpdatedAt(?int $value = null): self + public function setUpdatedAt(int $value): self { $this->updatedAt = $value; return $this; @@ -380,51 +380,51 @@ public function setSnoozedUntil(?int $value = null): self } /** - * @return ?bool + * @return bool */ - public function getOpen(): ?bool + public function getOpen(): bool { return $this->open; } /** - * @param ?bool $value + * @param bool $value */ - public function setOpen(?bool $value = null): self + public function setOpen(bool $value): self { $this->open = $value; return $this; } /** - * @return ?value-of + * @return value-of */ - public function getState(): ?string + public function getState(): string { return $this->state; } /** - * @param ?value-of $value + * @param value-of $value */ - public function setState(?string $value = null): self + public function setState(string $value): self { $this->state = $value; return $this; } /** - * @return ?bool + * @return bool */ - public function getRead(): ?bool + public function getRead(): bool { return $this->read; } /** - * @param ?bool $value + * @param bool $value */ - public function setRead(?bool $value = null): self + public function setRead(bool $value): self { $this->read = $value; return $this; @@ -533,34 +533,34 @@ public function setConversationRating(?ConversationRating $value = null): self } /** - * @return ?ConversationSource + * @return ConversationSource */ - public function getSource(): ?ConversationSource + public function getSource(): ConversationSource { return $this->source; } /** - * @param ?ConversationSource $value + * @param ConversationSource $value */ - public function setSource(?ConversationSource $value = null): self + public function setSource(ConversationSource $value): self { $this->source = $value; return $this; } /** - * @return ?ConversationContacts + * @return ConversationContacts */ - public function getContacts(): ?ConversationContacts + public function getContacts(): ConversationContacts { return $this->contacts; } /** - * @param ?ConversationContacts $value + * @param ConversationContacts $value */ - public function setContacts(?ConversationContacts $value = null): self + public function setContacts(ConversationContacts $value): self { $this->contacts = $value; return $this; @@ -584,27 +584,27 @@ public function setTeammates(?ConversationTeammates $value = null): self } /** - * @return ?array */ - public function getCustomAttributes(): ?array + public function getCustomAttributes(): array { return $this->customAttributes; } /** - * @param ?array $value */ - public function setCustomAttributes(?array $value = null): self + public function setCustomAttributes(array $value): self { $this->customAttributes = $value; return $this; diff --git a/src/DataEvents/Types/DataEvent.php b/src/DataEvents/Types/DataEvent.php index 394b2db3..398ef482 100644 --- a/src/DataEvents/Types/DataEvent.php +++ b/src/DataEvents/Types/DataEvent.php @@ -12,10 +12,10 @@ class DataEvent extends JsonSerializableType { /** - * @var ?'event' $type The type of the object + * @var 'event' $type The type of the object */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** * @var string $eventName The name of the event that occurred. This is presented to your App's admins when filtering and creating segments - a good event name is typically a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. @@ -61,9 +61,9 @@ class DataEvent extends JsonSerializableType /** * @param array{ + * type: 'event', * eventName: string, * createdAt: int, - * type?: ?'event', * userId?: ?string, * id?: ?string, * intercomUserId?: ?string, @@ -74,7 +74,7 @@ class DataEvent extends JsonSerializableType public function __construct( array $values, ) { - $this->type = $values['type'] ?? null; + $this->type = $values['type']; $this->eventName = $values['eventName']; $this->createdAt = $values['createdAt']; $this->userId = $values['userId'] ?? null; @@ -85,17 +85,17 @@ public function __construct( } /** - * @return ?'event' + * @return 'event' */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?'event' $value + * @param 'event' $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; diff --git a/src/IntercomClient.php b/src/IntercomClient.php index 238dd851..a0fa3e89 100644 --- a/src/IntercomClient.php +++ b/src/IntercomClient.php @@ -229,8 +229,8 @@ public function __construct( 'Authorization' => "Bearer $token", 'X-Fern-Language' => 'PHP', 'X-Fern-SDK-Name' => 'Intercom', - 'X-Fern-SDK-Version' => '5.0.2', - 'User-Agent' => 'intercom/intercom-php/5.0.2', + 'X-Fern-SDK-Version' => '0.0.475', + 'User-Agent' => 'intercom/intercom-php/0.0.475', 'Intercom-Version' => '2.14', ]; diff --git a/src/Messages/Types/Message.php b/src/Messages/Types/Message.php index 18bc4600..14842e53 100644 --- a/src/Messages/Types/Message.php +++ b/src/Messages/Types/Message.php @@ -47,10 +47,10 @@ class Message extends JsonSerializableType private string $messageType; /** - * @var ?string $conversationId The associated conversation_id + * @var string $conversationId The associated conversation_id */ #[JsonProperty('conversation_id')] - private ?string $conversationId; + private string $conversationId; /** * @param array{ @@ -59,8 +59,8 @@ class Message extends JsonSerializableType * createdAt: int, * body: string, * messageType: value-of, + * conversationId: string, * subject?: ?string, - * conversationId?: ?string, * } $values */ public function __construct( @@ -72,7 +72,7 @@ public function __construct( $this->subject = $values['subject'] ?? null; $this->body = $values['body']; $this->messageType = $values['messageType']; - $this->conversationId = $values['conversationId'] ?? null; + $this->conversationId = $values['conversationId']; } /** @@ -178,17 +178,17 @@ public function setMessageType(string $value): self } /** - * @return ?string + * @return string */ - public function getConversationId(): ?string + public function getConversationId(): string { return $this->conversationId; } /** - * @param ?string $value + * @param string $value */ - public function setConversationId(?string $value = null): self + public function setConversationId(string $value): self { $this->conversationId = $value; return $this; diff --git a/src/Notes/Types/Note.php b/src/Notes/Types/Note.php index 5e47daa6..28d2257c 100644 --- a/src/Notes/Types/Note.php +++ b/src/Notes/Types/Note.php @@ -12,22 +12,22 @@ class Note extends JsonSerializableType { /** - * @var ?string $type String representing the object's type. Always has the value `note`. + * @var string $type String representing the object's type. Always has the value `note`. */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** - * @var ?string $id The id of the note. + * @var string $id The id of the note. */ #[JsonProperty('id')] - private ?string $id; + private string $id; /** - * @var ?int $createdAt The time the note was created. + * @var int $createdAt The time the note was created. */ #[JsonProperty('created_at')] - private ?int $createdAt; + private int $createdAt; /** * @var ?NoteContact $contact Represents the contact that the note was created about. @@ -42,78 +42,78 @@ class Note extends JsonSerializableType private ?Admin $author; /** - * @var ?string $body The body text of the note. + * @var string $body The body text of the note. */ #[JsonProperty('body')] - private ?string $body; + private string $body; /** * @param array{ - * type?: ?string, - * id?: ?string, - * createdAt?: ?int, + * type: string, + * id: string, + * createdAt: int, + * body: string, * contact?: ?NoteContact, * author?: ?Admin, - * body?: ?string, * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; - $this->createdAt = $values['createdAt'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; + $this->createdAt = $values['createdAt']; $this->contact = $values['contact'] ?? null; $this->author = $values['author'] ?? null; - $this->body = $values['body'] ?? null; + $this->body = $values['body']; } /** - * @return ?string + * @return string */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?string $value + * @param string $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; } /** - * @return ?string + * @return string */ - public function getId(): ?string + public function getId(): string { return $this->id; } /** - * @param ?string $value + * @param string $value */ - public function setId(?string $value = null): self + public function setId(string $value): self { $this->id = $value; return $this; } /** - * @return ?int + * @return int */ - public function getCreatedAt(): ?int + public function getCreatedAt(): int { return $this->createdAt; } /** - * @param ?int $value + * @param int $value */ - public function setCreatedAt(?int $value = null): self + public function setCreatedAt(int $value): self { $this->createdAt = $value; return $this; @@ -154,17 +154,17 @@ public function setAuthor(?Admin $value = null): self } /** - * @return ?string + * @return string */ - public function getBody(): ?string + public function getBody(): string { return $this->body; } /** - * @param ?string $value + * @param string $value */ - public function setBody(?string $value = null): self + public function setBody(string $value): self { $this->body = $value; return $this; diff --git a/src/Tickets/Types/Ticket.php b/src/Tickets/Types/Ticket.php index 55be236e..b06ea171 100644 --- a/src/Tickets/Types/Ticket.php +++ b/src/Tickets/Types/Ticket.php @@ -14,34 +14,34 @@ class Ticket extends JsonSerializableType { /** - * @var ?'ticket' $type Always ticket + * @var 'ticket' $type Always ticket */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** - * @var ?string $id The unique identifier for the ticket which is given by Intercom. + * @var string $id The unique identifier for the ticket which is given by Intercom. */ #[JsonProperty('id')] - private ?string $id; + private string $id; /** - * @var ?string $ticketId The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries. + * @var string $ticketId The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries. */ #[JsonProperty('ticket_id')] - private ?string $ticketId; + private string $ticketId; /** - * @var ?value-of $category Category of the Ticket. + * @var value-of $category Category of the Ticket. */ #[JsonProperty('category')] - private ?string $category; + private string $category; /** - * @var ?array $ticketAttributes + * @var array $ticketAttributes */ #[JsonProperty('ticket_attributes'), ArrayType(['string' => 'mixed'])] - private ?array $ticketAttributes; + private array $ticketAttributes; /** * @var ?TicketState $ticketState @@ -56,10 +56,10 @@ class Ticket extends JsonSerializableType private ?TicketType $ticketType; /** - * @var ?TicketContacts $contacts + * @var TicketContacts $contacts */ #[JsonProperty('contacts')] - private ?TicketContacts $contacts; + private TicketContacts $contacts; /** * @var ?string $adminAssigneeId The id representing the admin assigned to the ticket. @@ -117,14 +117,14 @@ class Ticket extends JsonSerializableType /** * @param array{ - * type?: ?'ticket', - * id?: ?string, - * ticketId?: ?string, - * category?: ?value-of, - * ticketAttributes?: ?array, + * type: 'ticket', + * id: string, + * ticketId: string, + * category: value-of, + * ticketAttributes: array, + * contacts: TicketContacts, * ticketState?: ?TicketState, * ticketType?: ?TicketType, - * contacts?: ?TicketContacts, * adminAssigneeId?: ?string, * teamAssigneeId?: ?string, * createdAt?: ?int, @@ -137,16 +137,16 @@ class Ticket extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; - $this->ticketId = $values['ticketId'] ?? null; - $this->category = $values['category'] ?? null; - $this->ticketAttributes = $values['ticketAttributes'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; + $this->ticketId = $values['ticketId']; + $this->category = $values['category']; + $this->ticketAttributes = $values['ticketAttributes']; $this->ticketState = $values['ticketState'] ?? null; $this->ticketType = $values['ticketType'] ?? null; - $this->contacts = $values['contacts'] ?? null; + $this->contacts = $values['contacts']; $this->adminAssigneeId = $values['adminAssigneeId'] ?? null; $this->teamAssigneeId = $values['teamAssigneeId'] ?? null; $this->createdAt = $values['createdAt'] ?? null; @@ -159,85 +159,85 @@ public function __construct( } /** - * @return ?'ticket' + * @return 'ticket' */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?'ticket' $value + * @param 'ticket' $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; } /** - * @return ?string + * @return string */ - public function getId(): ?string + public function getId(): string { return $this->id; } /** - * @param ?string $value + * @param string $value */ - public function setId(?string $value = null): self + public function setId(string $value): self { $this->id = $value; return $this; } /** - * @return ?string + * @return string */ - public function getTicketId(): ?string + public function getTicketId(): string { return $this->ticketId; } /** - * @param ?string $value + * @param string $value */ - public function setTicketId(?string $value = null): self + public function setTicketId(string $value): self { $this->ticketId = $value; return $this; } /** - * @return ?value-of + * @return value-of */ - public function getCategory(): ?string + public function getCategory(): string { return $this->category; } /** - * @param ?value-of $value + * @param value-of $value */ - public function setCategory(?string $value = null): self + public function setCategory(string $value): self { $this->category = $value; return $this; } /** - * @return ?array + * @return array */ - public function getTicketAttributes(): ?array + public function getTicketAttributes(): array { return $this->ticketAttributes; } /** - * @param ?array $value + * @param array $value */ - public function setTicketAttributes(?array $value = null): self + public function setTicketAttributes(array $value): self { $this->ticketAttributes = $value; return $this; @@ -278,17 +278,17 @@ public function setTicketType(?TicketType $value = null): self } /** - * @return ?TicketContacts + * @return TicketContacts */ - public function getContacts(): ?TicketContacts + public function getContacts(): TicketContacts { return $this->contacts; } /** - * @param ?TicketContacts $value + * @param TicketContacts $value */ - public function setContacts(?TicketContacts $value = null): self + public function setContacts(TicketContacts $value): self { $this->contacts = $value; return $this; diff --git a/src/Types/Visitor.php b/src/Types/Visitor.php index 8ebfa5ac..40469894 100644 --- a/src/Types/Visitor.php +++ b/src/Types/Visitor.php @@ -12,22 +12,22 @@ class Visitor extends JsonSerializableType { /** - * @var ?'visitor' $type Value is 'visitor' + * @var 'visitor' $type Value is 'visitor' */ #[JsonProperty('type')] - private ?string $type; + private string $type; /** - * @var ?string $id The Intercom defined id representing the Visitor. + * @var string $id The Intercom defined id representing the Visitor. */ #[JsonProperty('id')] - private ?string $id; + private string $id; /** - * @var ?string $userId Automatically generated identifier for the Visitor. + * @var string $userId Automatically generated identifier for the Visitor. */ #[JsonProperty('user_id')] - private ?string $userId; + private string $userId; /** * @var ?bool $anonymous Identifies if this visitor is anonymous. @@ -211,9 +211,9 @@ class Visitor extends JsonSerializableType /** * @param array{ - * type?: ?'visitor', - * id?: ?string, - * userId?: ?string, + * type: 'visitor', + * id: string, + * userId: string, * anonymous?: ?bool, * email?: ?string, * phone?: ?string, @@ -247,11 +247,11 @@ class Visitor extends JsonSerializableType * } $values */ public function __construct( - array $values = [], + array $values, ) { - $this->type = $values['type'] ?? null; - $this->id = $values['id'] ?? null; - $this->userId = $values['userId'] ?? null; + $this->type = $values['type']; + $this->id = $values['id']; + $this->userId = $values['userId']; $this->anonymous = $values['anonymous'] ?? null; $this->email = $values['email'] ?? null; $this->phone = $values['phone'] ?? null; @@ -285,51 +285,51 @@ public function __construct( } /** - * @return ?'visitor' + * @return 'visitor' */ - public function getType(): ?string + public function getType(): string { return $this->type; } /** - * @param ?'visitor' $value + * @param 'visitor' $value */ - public function setType(?string $value = null): self + public function setType(string $value): self { $this->type = $value; return $this; } /** - * @return ?string + * @return string */ - public function getId(): ?string + public function getId(): string { return $this->id; } /** - * @param ?string $value + * @param string $value */ - public function setId(?string $value = null): self + public function setId(string $value): self { $this->id = $value; return $this; } /** - * @return ?string + * @return string */ - public function getUserId(): ?string + public function getUserId(): string { return $this->userId; } /** - * @param ?string $value + * @param string $value */ - public function setUserId(?string $value = null): self + public function setUserId(string $value): self { $this->userId = $value; return $this;