Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ PHP 8.1 and later.

### Composer

To install the bindings via [Composer](https://getcomposer.org/), add the following to `composer.json`:
To install the bindings via [Composer](https://getcomposer.org/):

```bash
composer require payjp/payjpv2-php
Expand Down
2 changes: 1 addition & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions lib/Model/BalanceListResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,10 @@ public function setObject(?string $object): self
*/
public function getUrl(): string
{
if ($this->container['url'] === null) {
throw new \LogicException('Property "url" is required but has not been set.');
}

return $this->container['url'];
}

Expand Down Expand Up @@ -414,6 +418,10 @@ public function setUrl(string $url): self
*/
public function getHasMore(): bool
{
if ($this->container['hasMore'] === null) {
throw new \LogicException('Property "hasMore" is required but has not been set.');
}

return $this->container['hasMore'];
}

Expand Down Expand Up @@ -441,6 +449,10 @@ public function setHasMore(bool $hasMore): self
*/
public function getData(): array
{
if ($this->container['data'] === null) {
throw new \LogicException('Property "data" is required but has not been set.');
}

return $this->container['data'];
}

Expand Down
32 changes: 32 additions & 0 deletions lib/Model/BalanceResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -467,6 +467,10 @@ public function setObject(?string $object): self
*/
public function getId(): string
{
if ($this->container['id'] === null) {
throw new \LogicException('Property "id" is required but has not been set.');
}

return $this->container['id'];
}

Expand Down Expand Up @@ -494,6 +498,10 @@ public function setId(string $id): self
*/
public function getLivemode(): bool
{
if ($this->container['livemode'] === null) {
throw new \LogicException('Property "livemode" is required but has not been set.');
}

return $this->container['livemode'];
}

Expand Down Expand Up @@ -521,6 +529,10 @@ public function setLivemode(bool $livemode): self
*/
public function getCreatedAt(): \DateTime
{
if ($this->container['createdAt'] === null) {
throw new \LogicException('Property "createdAt" is required but has not been set.');
}

return $this->container['createdAt'];
}

Expand Down Expand Up @@ -548,6 +560,10 @@ public function setCreatedAt(\DateTime $createdAt): self
*/
public function getUpdatedAt(): \DateTime
{
if ($this->container['updatedAt'] === null) {
throw new \LogicException('Property "updatedAt" is required but has not been set.');
}

return $this->container['updatedAt'];
}

Expand Down Expand Up @@ -575,6 +591,10 @@ public function setUpdatedAt(\DateTime $updatedAt): self
*/
public function getState(): \PAYJPV2\Model\BalanceState
{
if ($this->container['state'] === null) {
throw new \LogicException('Property "state" is required but has not been set.');
}

return $this->container['state'];
}

Expand Down Expand Up @@ -602,6 +622,10 @@ public function setState(\PAYJPV2\Model\BalanceState $state): self
*/
public function getStatements(): array
{
if ($this->container['statements'] === null) {
throw new \LogicException('Property "statements" is required but has not been set.');
}

return $this->container['statements'];
}

Expand Down Expand Up @@ -629,6 +653,10 @@ public function setStatements(array $statements): self
*/
public function getClosed(): bool
{
if ($this->container['closed'] === null) {
throw new \LogicException('Property "closed" is required but has not been set.');
}

return $this->container['closed'];
}

Expand Down Expand Up @@ -724,6 +752,10 @@ public function setDueDate(?\DateTime $dueDate): self
*/
public function getNet(): int
{
if ($this->container['net'] === null) {
throw new \LogicException('Property "net" is required but has not been set.');
}

return $this->container['net'];
}

Expand Down
21 changes: 6 additions & 15 deletions lib/Model/BalanceState.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,27 +38,18 @@
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class BalanceState
enum BalanceState: string
{
/**
* Possible values of this enum
*/
public const COLLECTING = 'collecting';

public const TRANSFER = 'transfer';

public const CLAIM = 'claim';
case COLLECTING = 'collecting';
case TRANSFER = 'transfer';
case CLAIM = 'claim';

/**
* Gets allowable values of the enum
* @return string[]
*/
public static function getAllowableEnumValues()
public static function getAllowableEnumValues(): array
{
return [
self::COLLECTING,
self::TRANSFER,
self::CLAIM,
];
return array_column(self::cases(), 'value');
}
}
8 changes: 8 additions & 0 deletions lib/Model/BalanceURLResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,10 @@ public function setObject(?string $object): self
*/
public function getUrl(): string
{
if ($this->container['url'] === null) {
throw new \LogicException('Property "url" is required but has not been set.');
}

return $this->container['url'];
}

Expand Down Expand Up @@ -404,6 +408,10 @@ public function setUrl(string $url): self
*/
public function getExpires(): \DateTime
{
if ($this->container['expires'] === null) {
throw new \LogicException('Property "expires" is required but has not been set.');
}

return $this->container['expires'];
}

Expand Down
24 changes: 24 additions & 0 deletions lib/Model/BankInfoResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,10 @@ public function valid()
*/
public function getBankCode(): string
{
if ($this->container['bankCode'] === null) {
throw new \LogicException('Property "bankCode" is required but has not been set.');
}

return $this->container['bankCode'];
}

Expand Down Expand Up @@ -378,6 +382,10 @@ public function setBankCode(string $bankCode): self
*/
public function getBankBranchCode(): string
{
if ($this->container['bankBranchCode'] === null) {
throw new \LogicException('Property "bankBranchCode" is required but has not been set.');
}

return $this->container['bankBranchCode'];
}

Expand Down Expand Up @@ -405,6 +413,10 @@ public function setBankBranchCode(string $bankBranchCode): self
*/
public function getBankAccountType(): string
{
if ($this->container['bankAccountType'] === null) {
throw new \LogicException('Property "bankAccountType" is required but has not been set.');
}

return $this->container['bankAccountType'];
}

Expand Down Expand Up @@ -432,6 +444,10 @@ public function setBankAccountType(string $bankAccountType): self
*/
public function getBankAccountNumber(): string
{
if ($this->container['bankAccountNumber'] === null) {
throw new \LogicException('Property "bankAccountNumber" is required but has not been set.');
}

return $this->container['bankAccountNumber'];
}

Expand Down Expand Up @@ -459,6 +475,10 @@ public function setBankAccountNumber(string $bankAccountNumber): self
*/
public function getBankAccountHolderName(): string
{
if ($this->container['bankAccountHolderName'] === null) {
throw new \LogicException('Property "bankAccountHolderName" is required but has not been set.');
}

return $this->container['bankAccountHolderName'];
}

Expand Down Expand Up @@ -486,6 +506,10 @@ public function setBankAccountHolderName(string $bankAccountHolderName): self
*/
public function getBankAccountStatus(): string
{
if ($this->container['bankAccountStatus'] === null) {
throw new \LogicException('Property "bankAccountStatus" is required but has not been set.');
}

return $this->container['bankAccountStatus'];
}

Expand Down
17 changes: 5 additions & 12 deletions lib/Model/CaptureMethod.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,24 +37,17 @@
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CaptureMethod
enum CaptureMethod: string
{
/**
* Possible values of this enum
*/
public const AUTOMATIC = 'automatic';

public const MANUAL = 'manual';
case AUTOMATIC = 'automatic';
case MANUAL = 'manual';

/**
* Gets allowable values of the enum
* @return string[]
*/
public static function getAllowableEnumValues()
public static function getAllowableEnumValues(): array
{
return [
self::AUTOMATIC,
self::MANUAL,
];
return array_column(self::cases(), 'value');
}
}
4 changes: 4 additions & 0 deletions lib/Model/CheckoutSessionCreateRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -563,6 +563,10 @@ public function setLineItems(?array $lineItems): self
*/
public function getMode(): \PAYJPV2\Model\CheckoutSessionMode
{
if ($this->container['mode'] === null) {
throw new \LogicException('Property "mode" is required but has not been set.');
}

return $this->container['mode'];
}

Expand Down
Loading