<?php
 declare(strict_types=1); namespace Square\Models; use stdClass; class BulkCreateTeamMembersRequest implements \JsonSerializable { private $teamMembers; public function __construct(array $teamMembers) { $this->teamMembers = $teamMembers; } public function getTeamMembers(): array { return $this->teamMembers; } public function setTeamMembers(array $teamMembers): void { $this->teamMembers = $teamMembers; } #[\ReturnTypeWillChange] public function jsonSerialize(bool $asArrayWhenEmpty = false) { $json = []; $json['team_members'] = $this->teamMembers; $json = array_filter($json, function ($val) { return $val !== null; }); return (!$asArrayWhenEmpty && empty($json)) ? new stdClass() : $json; } } 