Skip to content

Commit b665baf

Browse files
feat(api): api update
1 parent 62c681d commit b665baf

File tree

7 files changed

+23
-58
lines changed

7 files changed

+23
-58
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 232
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-eee80cbe3a2fffb5dcd24ddddd45ee10e1e927251bceb71e136a1f948fbac1f3.yml
3-
openapi_spec_hash: 4edce356e3d758a5b084e97875bd18f2
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-6726a464abac2e26549c692dba99ba448d4e8c8761df6b395ad50b348aa25a26.yml
3+
openapi_spec_hash: 275356a13559aed985c8c5c67b819d7d
44
config_hash: 27e44ed36b9c5617b580ead7231a594a

src/CheckTransfers/CheckTransfer/Submission.php

Lines changed: 5 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
namespace Increase\CheckTransfers\CheckTransfer;
66

7-
use Increase\CheckTransfers\CheckTransfer\Submission\AddressCorrectionAction;
87
use Increase\CheckTransfers\CheckTransfer\Submission\SubmittedAddress;
98
use Increase\Core\Attributes\Required;
109
use Increase\Core\Concerns\SdkModel;
@@ -16,7 +15,6 @@
1615
* @phpstan-import-type SubmittedAddressShape from \Increase\CheckTransfers\CheckTransfer\Submission\SubmittedAddress
1716
*
1817
* @phpstan-type SubmissionShape = array{
19-
* addressCorrectionAction: AddressCorrectionAction|value-of<AddressCorrectionAction>,
2018
* submittedAddress: SubmittedAddress|SubmittedAddressShape,
2119
* submittedAt: \DateTimeInterface,
2220
* }
@@ -26,22 +24,14 @@ final class Submission implements BaseModel
2624
/** @use SdkModel<SubmissionShape> */
2725
use SdkModel;
2826

29-
/**
30-
* Per USPS requirements, Increase will standardize the address to USPS standards and check it against the USPS National Change of Address (NCOA) database before mailing it. This indicates what modifications, if any, were made to the address before printing and mailing the check.
31-
*
32-
* @var value-of<AddressCorrectionAction> $addressCorrectionAction
33-
*/
34-
#[Required('address_correction_action', enum: AddressCorrectionAction::class)]
35-
public string $addressCorrectionAction;
36-
3727
/**
3828
* The address we submitted to the printer. This is what is physically printed on the check.
3929
*/
4030
#[Required('submitted_address')]
4131
public SubmittedAddress $submittedAddress;
4232

4333
/**
44-
* When this check transfer was submitted to our check printer.
34+
* When this check was submitted to our check printer.
4535
*/
4636
#[Required('submitted_at')]
4737
public \DateTimeInterface $submittedAt;
@@ -51,18 +41,13 @@ final class Submission implements BaseModel
5141
*
5242
* To enforce required parameters use
5343
* ```
54-
* Submission::with(
55-
* addressCorrectionAction: ..., submittedAddress: ..., submittedAt: ...
56-
* )
44+
* Submission::with(submittedAddress: ..., submittedAt: ...)
5745
* ```
5846
*
5947
* Otherwise ensure the following setters are called
6048
*
6149
* ```
62-
* (new Submission)
63-
* ->withAddressCorrectionAction(...)
64-
* ->withSubmittedAddress(...)
65-
* ->withSubmittedAt(...)
50+
* (new Submission)->withSubmittedAddress(...)->withSubmittedAt(...)
6651
* ```
6752
*/
6853
public function __construct()
@@ -75,37 +60,20 @@ public function __construct()
7560
*
7661
* You must use named parameters to construct any parameters with a default value.
7762
*
78-
* @param AddressCorrectionAction|value-of<AddressCorrectionAction> $addressCorrectionAction
7963
* @param SubmittedAddress|SubmittedAddressShape $submittedAddress
8064
*/
8165
public static function with(
82-
AddressCorrectionAction|string $addressCorrectionAction,
8366
SubmittedAddress|array $submittedAddress,
84-
\DateTimeInterface $submittedAt,
67+
\DateTimeInterface $submittedAt
8568
): self {
8669
$self = new self;
8770

88-
$self['addressCorrectionAction'] = $addressCorrectionAction;
8971
$self['submittedAddress'] = $submittedAddress;
9072
$self['submittedAt'] = $submittedAt;
9173

9274
return $self;
9375
}
9476

95-
/**
96-
* Per USPS requirements, Increase will standardize the address to USPS standards and check it against the USPS National Change of Address (NCOA) database before mailing it. This indicates what modifications, if any, were made to the address before printing and mailing the check.
97-
*
98-
* @param AddressCorrectionAction|value-of<AddressCorrectionAction> $addressCorrectionAction
99-
*/
100-
public function withAddressCorrectionAction(
101-
AddressCorrectionAction|string $addressCorrectionAction
102-
): self {
103-
$self = clone $this;
104-
$self['addressCorrectionAction'] = $addressCorrectionAction;
105-
106-
return $self;
107-
}
108-
10977
/**
11078
* The address we submitted to the printer. This is what is physically printed on the check.
11179
*
@@ -121,7 +89,7 @@ public function withSubmittedAddress(
12189
}
12290

12391
/**
124-
* When this check transfer was submitted to our check printer.
92+
* When this check was submitted to our check printer.
12593
*/
12694
public function withSubmittedAt(\DateTimeInterface $submittedAt): self
12795
{

src/CheckTransfers/CheckTransfer/Submission/AddressCorrectionAction.php

Lines changed: 0 additions & 19 deletions
This file was deleted.

src/EventSubscriptions/EventSubscription/SelectedEventCategory.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,10 @@ enum SelectedEventCategory: string
169169

170170
case PHYSICAL_CARD_PROFILE_UPDATED = 'physical_card_profile.updated';
171171

172+
case PHYSICAL_CHECK_CREATED = 'physical_check.created';
173+
174+
case PHYSICAL_CHECK_UPDATED = 'physical_check.updated';
175+
172176
case PROGRAM_CREATED = 'program.created';
173177

174178
case PROGRAM_UPDATED = 'program.updated';

src/EventSubscriptions/EventSubscriptionCreateParams/SelectedEventCategory.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,10 @@ enum SelectedEventCategory: string
169169

170170
case PHYSICAL_CARD_PROFILE_UPDATED = 'physical_card_profile.updated';
171171

172+
case PHYSICAL_CHECK_CREATED = 'physical_check.created';
173+
174+
case PHYSICAL_CHECK_UPDATED = 'physical_check.updated';
175+
172176
case PROGRAM_CREATED = 'program.created';
173177

174178
case PROGRAM_UPDATED = 'program.updated';

src/Events/Event/Category.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,10 @@ enum Category: string
169169

170170
case PHYSICAL_CARD_PROFILE_UPDATED = 'physical_card_profile.updated';
171171

172+
case PHYSICAL_CHECK_CREATED = 'physical_check.created';
173+
174+
case PHYSICAL_CHECK_UPDATED = 'physical_check.updated';
175+
172176
case PROGRAM_CREATED = 'program.created';
173177

174178
case PROGRAM_UPDATED = 'program.updated';

src/Events/EventListParams/Category/In.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,10 @@ enum In: string
166166

167167
case PHYSICAL_CARD_PROFILE_UPDATED = 'physical_card_profile.updated';
168168

169+
case PHYSICAL_CHECK_CREATED = 'physical_check.created';
170+
171+
case PHYSICAL_CHECK_UPDATED = 'physical_check.updated';
172+
169173
case PROGRAM_CREATED = 'program.created';
170174

171175
case PROGRAM_UPDATED = 'program.updated';

0 commit comments

Comments
 (0)