Skip to content

Commit

Permalink
chore: update SDK from api-definitions (#691)
Browse files Browse the repository at this point in the history
Co-authored-by: rebilly-machine-user <[email protected]>
  • Loading branch information
1 parent 43e850f commit 3a770b0
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 52 deletions.
5 changes: 5 additions & 0 deletions .changeset/healthy-squids-shake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@rebilly/client-php": patch
---

Update MobilePay credentials Rebilly/api-definitions#1883
5 changes: 5 additions & 0 deletions .changeset/violet-shirts-yawn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@rebilly/client-php": patch
---

remove isBot riskfactor field Rebilly/api-definitions#1882
32 changes: 16 additions & 16 deletions src/Model/MobilePayCredentials.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ class MobilePayCredentials implements JsonSerializable

public function __construct(array $data = [])
{
if (array_key_exists('providerId', $data)) {
$this->setProviderId($data['providerId']);
if (array_key_exists('merchantSerialNumber', $data)) {
$this->setMerchantSerialNumber($data['merchantSerialNumber']);
}
if (array_key_exists('merchantVat', $data)) {
$this->setMerchantVat($data['merchantVat']);
if (array_key_exists('subscriptionKey', $data)) {
$this->setSubscriptionKey($data['subscriptionKey']);
}
if (array_key_exists('clientId', $data)) {
$this->setClientId($data['clientId']);
Expand All @@ -40,26 +40,26 @@ public static function from(array $data = []): self
return new self($data);
}

public function getProviderId(): string
public function getMerchantSerialNumber(): string
{
return $this->fields['providerId'];
return $this->fields['merchantSerialNumber'];
}

public function setProviderId(string $providerId): static
public function setMerchantSerialNumber(string $merchantSerialNumber): static
{
$this->fields['providerId'] = $providerId;
$this->fields['merchantSerialNumber'] = $merchantSerialNumber;

return $this;
}

public function getMerchantVat(): string
public function getSubscriptionKey(): string
{
return $this->fields['merchantVat'];
return $this->fields['subscriptionKey'];
}

public function setMerchantVat(string $merchantVat): static
public function setSubscriptionKey(string $subscriptionKey): static
{
$this->fields['merchantVat'] = $merchantVat;
$this->fields['subscriptionKey'] = $subscriptionKey;

return $this;
}
Expand Down Expand Up @@ -91,11 +91,11 @@ public function setClientSecret(string $clientSecret): static
public function jsonSerialize(): array
{
$data = [];
if (array_key_exists('providerId', $this->fields)) {
$data['providerId'] = $this->fields['providerId'];
if (array_key_exists('merchantSerialNumber', $this->fields)) {
$data['merchantSerialNumber'] = $this->fields['merchantSerialNumber'];
}
if (array_key_exists('merchantVat', $this->fields)) {
$data['merchantVat'] = $this->fields['merchantVat'];
if (array_key_exists('subscriptionKey', $this->fields)) {
$data['subscriptionKey'] = $this->fields['subscriptionKey'];
}
if (array_key_exists('clientId', $this->fields)) {
$data['clientId'] = $this->fields['clientId'];
Expand Down
18 changes: 0 additions & 18 deletions src/Model/RiskMetadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,6 @@ public function __construct(array $data = [])
if (array_key_exists('declinedPaymentInstrumentVelocity', $data)) {
$this->setDeclinedPaymentInstrumentVelocity($data['declinedPaymentInstrumentVelocity']);
}
if (array_key_exists('isBot', $data)) {
$this->setIsBot($data['isBot']);
}
if (array_key_exists('deviceVelocity', $data)) {
$this->setDeviceVelocity($data['deviceVelocity']);
}
Expand Down Expand Up @@ -322,11 +319,6 @@ public function getDeclinedPaymentInstrumentVelocity(): ?int
return $this->fields['declinedPaymentInstrumentVelocity'] ?? null;
}

public function getIsBot(): ?bool
{
return $this->fields['isBot'] ?? null;
}

public function getDeviceVelocity(): ?int
{
return $this->fields['deviceVelocity'] ?? null;
Expand Down Expand Up @@ -444,9 +436,6 @@ public function jsonSerialize(): array
if (array_key_exists('declinedPaymentInstrumentVelocity', $this->fields)) {
$data['declinedPaymentInstrumentVelocity'] = $this->fields['declinedPaymentInstrumentVelocity'];
}
if (array_key_exists('isBot', $this->fields)) {
$data['isBot'] = $this->fields['isBot'];
}
if (array_key_exists('deviceVelocity', $this->fields)) {
$data['deviceVelocity'] = $this->fields['deviceVelocity'];
}
Expand Down Expand Up @@ -638,13 +627,6 @@ private function setDeclinedPaymentInstrumentVelocity(null|int $declinedPaymentI
return $this;
}

private function setIsBot(null|bool $isBot): static
{
$this->fields['isBot'] = $isBot;

return $this;
}

private function setDeviceVelocity(null|int $deviceVelocity): static
{
$this->fields['deviceVelocity'] = $deviceVelocity;
Expand Down
18 changes: 0 additions & 18 deletions src/Model/RiskMetadataExtraData.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,6 @@ public function __construct(array $data = [])
if (array_key_exists('threatMetrixSessionId', $data)) {
$this->setThreatMetrixSessionId($data['threatMetrixSessionId']);
}
if (array_key_exists('fingerprintJsRequestId', $data)) {
$this->setFingerprintJsRequestId($data['fingerprintJsRequestId']);
}
}

public static function from(array $data = []): self
Expand Down Expand Up @@ -76,18 +73,6 @@ public function setThreatMetrixSessionId(null|string $threatMetrixSessionId): st
return $this;
}

public function getFingerprintJsRequestId(): ?string
{
return $this->fields['fingerprintJsRequestId'] ?? null;
}

public function setFingerprintJsRequestId(null|string $fingerprintJsRequestId): static
{
$this->fields['fingerprintJsRequestId'] = $fingerprintJsRequestId;

return $this;
}

public function jsonSerialize(): array
{
$data = [];
Expand All @@ -100,9 +85,6 @@ public function jsonSerialize(): array
if (array_key_exists('threatMetrixSessionId', $this->fields)) {
$data['threatMetrixSessionId'] = $this->fields['threatMetrixSessionId'];
}
if (array_key_exists('fingerprintJsRequestId', $this->fields)) {
$data['fingerprintJsRequestId'] = $this->fields['fingerprintJsRequestId'];
}

return $data;
}
Expand Down

0 comments on commit 3a770b0

Please sign in to comment.