<?php
/**
 * This code was generated by
 * ___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
 *  |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
 *  |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \
 *
 * Twilio - Lookups
 * This is the public Twilio REST API.
 *
 * NOTE: This class is auto generated by OpenAPI Generator.
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

namespace Twilio\Rest\Lookups\V2;

use Twilio\Values;
abstract class QueryModels
{
    /**
     * @property string $firstName
     * @property string $lastName
     * @property string $addressLine1
     * @property string $addressLine2
     * @property string $city
     * @property string $state
     * @property string $postalCode
     * @property string $addressCountryCode
     * @property string $nationalId
     * @property string $dateOfBirth
    */
    public static function createIdentityMatchParameters(array $payload = []): IdentityMatchParameters
    {
        return new IdentityMatchParameters($payload);
    }

    /**
     * @property string $lastVerifiedDate
    */
    public static function createReassignedNumberRequest(array $payload = []): ReassignedNumberRequest
    {
        return new ReassignedNumberRequest($payload);
    }

    /**
     * @property string $partnerSubId
    */
    public static function createSmsPumpingRiskParameters(array $payload = []): SmsPumpingRiskParameters
    {
        return new SmsPumpingRiskParameters($payload);
    }

    /**
     * @property string $correlationId Unique identifier used to match request with response
     * @property string $phoneNumber
     * @property string[][] $fields
     * @property string $countryCode
     * @property IdentityMatchParameters $identityMatch
     * @property ReassignedNumberRequest $reassignedNumber
     * @property SmsPumpingRiskParameters $smsPumpingRisk
    */
    public static function createLookupRequestWithCorId(array $payload = []): LookupRequestWithCorId
    {
        return new LookupRequestWithCorId($payload);
    }

    /**
     * @property LookupRequestWithCorId[] $phoneNumbers
    */
    public static function createLookupRequest1(array $payload = []): LookupRequest1
    {
        return new LookupRequest1($payload);
    }

}

class IdentityMatchParameters implements \JsonSerializable
{
    /**
     * @property string $firstName
     * @property string $lastName
     * @property string $addressLine1
     * @property string $addressLine2
     * @property string $city
     * @property string $state
     * @property string $postalCode
     * @property string $addressCountryCode
     * @property string $nationalId
     * @property string $dateOfBirth
    */
        protected $firstName;
        protected $lastName;
        protected $addressLine1;
        protected $addressLine2;
        protected $city;
        protected $state;
        protected $postalCode;
        protected $addressCountryCode;
        protected $nationalId;
        protected $dateOfBirth;
    public function __construct(array $payload = []) {
        $this->firstName = Values::array_get($payload, 'first_name');
        $this->lastName = Values::array_get($payload, 'last_name');
        $this->addressLine1 = Values::array_get($payload, 'address_line1');
        $this->addressLine2 = Values::array_get($payload, 'address_line2');
        $this->city = Values::array_get($payload, 'city');
        $this->state = Values::array_get($payload, 'state');
        $this->postalCode = Values::array_get($payload, 'postal_code');
        $this->addressCountryCode = Values::array_get($payload, 'address_country_code');
        $this->nationalId = Values::array_get($payload, 'national_id');
        $this->dateOfBirth = Values::array_get($payload, 'date_of_birth');
    }

    public function toArray(): array
    {
        return $this->jsonSerialize();
    }

    public function jsonSerialize(): array
    {
        return [
            'first_name' => $this->firstName,
            'last_name' => $this->lastName,
            'address_line1' => $this->addressLine1,
            'address_line2' => $this->addressLine2,
            'city' => $this->city,
            'state' => $this->state,
            'postal_code' => $this->postalCode,
            'address_country_code' => $this->addressCountryCode,
            'national_id' => $this->nationalId,
            'date_of_birth' => $this->dateOfBirth
        ];
    }
}

class ReassignedNumberRequest implements \JsonSerializable
{
    /**
     * @property string $lastVerifiedDate
    */
        protected $lastVerifiedDate;
    public function __construct(array $payload = []) {
        $this->lastVerifiedDate = Values::array_get($payload, 'last_verified_date');
    }

    public function toArray(): array
    {
        return $this->jsonSerialize();
    }

    public function jsonSerialize(): array
    {
        return [
            'last_verified_date' => $this->lastVerifiedDate
        ];
    }
}

class SmsPumpingRiskParameters implements \JsonSerializable
{
    /**
     * @property string $partnerSubId
    */
        protected $partnerSubId;
    public function __construct(array $payload = []) {
        $this->partnerSubId = Values::array_get($payload, 'partner_sub_id');
    }

    public function toArray(): array
    {
        return $this->jsonSerialize();
    }

    public function jsonSerialize(): array
    {
        return [
            'partner_sub_id' => $this->partnerSubId
        ];
    }
}

class LookupRequestWithCorId implements \JsonSerializable
{
    /**
     * @property string $correlationId Unique identifier used to match request with response
     * @property string $phoneNumber
     * @property string[][] $fields
     * @property string $countryCode
     * @property IdentityMatchParameters $identityMatch
     * @property ReassignedNumberRequest $reassignedNumber
     * @property SmsPumpingRiskParameters $smsPumpingRisk
    */
        protected $correlationId;
        protected $phoneNumber;
        protected $fields;
        protected $countryCode;
        protected $identityMatch;
        protected $reassignedNumber;
        protected $smsPumpingRisk;
    public function __construct(array $payload = []) {
        $this->correlationId = Values::array_get($payload, 'correlation_id');
        $this->phoneNumber = Values::array_get($payload, 'phone_number');
        $this->fields = Values::array_get($payload, 'fields');
        $this->countryCode = Values::array_get($payload, 'country_code');
        $this->identityMatch = Values::array_get($payload, 'identity_match');
        $this->reassignedNumber = Values::array_get($payload, 'reassigned_number');
        $this->smsPumpingRisk = Values::array_get($payload, 'sms_pumping_risk');
    }

    public function toArray(): array
    {
        return $this->jsonSerialize();
    }

    public function jsonSerialize(): array
    {
        return [
            'correlation_id' => $this->correlationId,
            'phone_number' => $this->phoneNumber,
            'fields' => $this->fields,
            'country_code' => $this->countryCode,
            'identity_match' => $this->identityMatch,
            'reassigned_number' => $this->reassignedNumber,
            'sms_pumping_risk' => $this->smsPumpingRisk
        ];
    }
}

class LookupRequest1 implements \JsonSerializable
{
    /**
     * @property LookupRequestWithCorId[] $phoneNumbers
    */
        protected $phoneNumbers;
    public function __construct(array $payload = []) {
        $this->phoneNumbers = Values::array_get($payload, 'phone_numbers');
    }

    public function toArray(): array
    {
        return $this->jsonSerialize();
    }

    public function jsonSerialize(): array
    {
        return [
            'phone_numbers' => $this->phoneNumbers
        ];
    }
}

