Skip to content

Commit

Permalink
Update generated code (#1714)
Browse files Browse the repository at this point in the history
* Update generated code for v1087

* Update generated code for v1088

* Update generated code for v1092

* Update generated code for v1093

* Update generated code for v1094

* Update generated code for v1095

---------

Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Co-authored-by: Ramya Rao <100975018+ramya-stripe@users.noreply.github.com>
  • Loading branch information
stripe-openapi[bot] and ramya-stripe authored Jun 24, 2024
1 parent dbef429 commit 4958817
Show file tree
Hide file tree
Showing 19 changed files with 31 additions and 35 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v1079
v1095
1 change: 0 additions & 1 deletion init.php
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,6 @@
require __DIR__ . '/lib/Payout.php';
require __DIR__ . '/lib/Person.php';
require __DIR__ . '/lib/Plan.php';
require __DIR__ . '/lib/PlatformTaxFee.php';
require __DIR__ . '/lib/Price.php';
require __DIR__ . '/lib/Product.php';
require __DIR__ . '/lib/ProductFeature.php';
Expand Down
2 changes: 1 addition & 1 deletion lib/BalanceTransaction.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
* @property \Stripe\StripeObject[] $fee_details Detailed breakdown of fees (in cents (or local equivalent)) paid for this transaction.
* @property int $net Net impact to a Stripe balance (in cents (or local equivalent)). A positive value represents incrementing a Stripe balance, and a negative value decrementing a Stripe balance. You can calculate the net impact of a transaction on a balance by <code>amount</code> - <code>fee</code>
* @property string $reporting_category Learn more about how <a href="https://stripe.com/docs/reports/reporting-categories">reporting categories</a> can help you understand balance transactions from an accounting perspective.
* @property null|string|\Stripe\ApplicationFee|\Stripe\ApplicationFeeRefund|\Stripe\Charge|\Stripe\ConnectCollectionTransfer|\Stripe\CustomerCashBalanceTransaction|\Stripe\Dispute|\Stripe\Issuing\Authorization|\Stripe\Issuing\Dispute|\Stripe\Issuing\Transaction|\Stripe\Payout|\Stripe\PlatformTaxFee|\Stripe\Refund|\Stripe\ReserveTransaction|\Stripe\TaxDeductedAtSource|\Stripe\Topup|\Stripe\Transfer|\Stripe\TransferReversal $source This transaction relates to the Stripe object.
* @property null|string|\Stripe\ApplicationFee|\Stripe\ApplicationFeeRefund|\Stripe\Charge|\Stripe\ConnectCollectionTransfer|\Stripe\CustomerCashBalanceTransaction|\Stripe\Dispute|\Stripe\Issuing\Authorization|\Stripe\Issuing\Dispute|\Stripe\Issuing\Transaction|\Stripe\Payout|\Stripe\Refund|\Stripe\ReserveTransaction|\Stripe\TaxDeductedAtSource|\Stripe\Topup|\Stripe\Transfer|\Stripe\TransferReversal $source This transaction relates to the Stripe object.
* @property string $status The transaction's net funds status in the Stripe balance, which are either <code>available</code> or <code>pending</code>.
* @property string $type Transaction type: <code>adjustment</code>, <code>advance</code>, <code>advance_funding</code>, <code>anticipation_repayment</code>, <code>application_fee</code>, <code>application_fee_refund</code>, <code>charge</code>, <code>climate_order_purchase</code>, <code>climate_order_refund</code>, <code>connect_collection_transfer</code>, <code>contribution</code>, <code>issuing_authorization_hold</code>, <code>issuing_authorization_release</code>, <code>issuing_dispute</code>, <code>issuing_transaction</code>, <code>obligation_outbound</code>, <code>obligation_reversal_inbound</code>, <code>payment</code>, <code>payment_failure_refund</code>, <code>payment_network_reserve_hold</code>, <code>payment_network_reserve_release</code>, <code>payment_refund</code>, <code>payment_reversal</code>, <code>payment_unreconciled</code>, <code>payout</code>, <code>payout_cancel</code>, <code>payout_failure</code>, <code>refund</code>, <code>refund_failure</code>, <code>reserve_transaction</code>, <code>reserved_funds</code>, <code>stripe_fee</code>, <code>stripe_fx_fee</code>, <code>tax_fee</code>, <code>topup</code>, <code>topup_reversal</code>, <code>transfer</code>, <code>transfer_cancel</code>, <code>transfer_failure</code>, or <code>transfer_refund</code>. Learn more about <a href="https://stripe.com/docs/reports/balance-transaction-types">balance transaction types and what they represent</a>. To classify transactions for accounting purposes, consider <code>reporting_category</code> instead.
*/
Expand Down
1 change: 0 additions & 1 deletion lib/Charge.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ class Charge extends ApiResource
const OBJECT_NAME = 'charge';

use ApiOperations\NestedResource;
use ApiOperations\Search;
use ApiOperations\Update;

const STATUS_FAILED = 'failed';
Expand Down
1 change: 0 additions & 1 deletion lib/Customer.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ class Customer extends ApiResource
const OBJECT_NAME = 'customer';

use ApiOperations\NestedResource;
use ApiOperations\Search;
use ApiOperations\Update;

const TAX_EXEMPT_EXEMPT = 'exempt';
Expand Down
1 change: 0 additions & 1 deletion lib/Invoice.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,6 @@ class Invoice extends ApiResource
const OBJECT_NAME = 'invoice';

use ApiOperations\NestedResource;
use ApiOperations\Search;
use ApiOperations\Update;

const BILLING_REASON_AUTOMATIC_PENDING_INVOICE_ITEM_INVOICE = 'automatic_pending_invoice_item_invoice';
Expand Down
2 changes: 2 additions & 0 deletions lib/Issuing/Authorization.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
* @property null|string|\Stripe\Issuing\Cardholder $cardholder The cardholder to whom this authorization belongs.
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
* @property string $currency The currency of the cardholder. This currency can be different from the currency presented at authorization and the <code>merchant_currency</code> field on this authorization. Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
* @property null|\Stripe\StripeObject $fleet Fleet-specific information for authorizations using Fleet cards.
* @property null|\Stripe\StripeObject $fuel Information about fuel that was purchased with this transaction. Typically this information is received from the merchant after the authorization has been approved and the fuel dispensed.
* @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
* @property int $merchant_amount The total amount that was authorized or rejected. This amount is in the <code>merchant_currency</code> and in the <a href="https://stripe.com/docs/currencies#zero-decimal">smallest currency unit</a>. <code>merchant_amount</code> should be the same as <code>amount</code>, unless <code>merchant_currency</code> and <code>currency</code> are different.
* @property string $merchant_currency The local currency that was presented to the cardholder for the authorization. This currency can be different from the cardholder currency and the <code>currency</code> field on this authorization. Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
Expand Down
1 change: 0 additions & 1 deletion lib/PaymentIntent.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ class PaymentIntent extends ApiResource
{
const OBJECT_NAME = 'payment_intent';

use ApiOperations\Search;
use ApiOperations\Update;

const CANCELLATION_REASON_ABANDONED = 'abandoned';
Expand Down
17 changes: 0 additions & 17 deletions lib/PlatformTaxFee.php

This file was deleted.

1 change: 0 additions & 1 deletion lib/Price.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ class Price extends ApiResource
{
const OBJECT_NAME = 'price';

use ApiOperations\Search;
use ApiOperations\Update;

const BILLING_SCHEME_PER_UNIT = 'per_unit';
Expand Down
1 change: 0 additions & 1 deletion lib/Product.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ class Product extends ApiResource
const OBJECT_NAME = 'product';

use ApiOperations\NestedResource;
use ApiOperations\Search;
use ApiOperations\Update;

const TYPE_GOOD = 'good';
Expand Down
3 changes: 2 additions & 1 deletion lib/Service/Tax/CalculationService.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ public function allLineItems($id, $params = null, $opts = null)
}

/**
* Calculates tax based on input and returns a Tax <code>Calculation</code> object.
* Calculates tax based on the input and returns a Tax <code>Calculation</code>
* object.
*
* @param null|array $params
* @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
Expand Down
17 changes: 17 additions & 0 deletions lib/Service/TestHelpers/Issuing/AuthorizationService.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,23 @@ public function expire($id, $params = null, $opts = null)
return $this->request('post', $this->buildPath('/v1/test_helpers/issuing/authorizations/%s/expire', $id), $params, $opts);
}

/**
* Finalize the amount on an Authorization prior to capture, when the initial
* authorization was for an estimated amount.
*
* @param string $id
* @param null|array $params
* @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
*
* @throws \Stripe\Exception\ApiErrorException if the request fails
*
* @return \Stripe\Issuing\Authorization
*/
public function finalizeAmount($id, $params = null, $opts = null)
{
return $this->request('post', $this->buildPath('/v1/test_helpers/issuing/authorizations/%s/finalize_amount', $id), $params, $opts);
}

/**
* Increment a test-mode Authorization.
*
Expand Down
1 change: 0 additions & 1 deletion lib/Subscription.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ class Subscription extends ApiResource
{
const OBJECT_NAME = 'subscription';

use ApiOperations\Search;
use ApiOperations\Update;

const COLLECTION_METHOD_CHARGE_AUTOMATICALLY = 'charge_automatically';
Expand Down
3 changes: 2 additions & 1 deletion lib/Tax/Calculation.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ class Calculation extends \Stripe\ApiResource
const OBJECT_NAME = 'tax.calculation';

/**
* Calculates tax based on input and returns a Tax <code>Calculation</code> object.
* Calculates tax based on the input and returns a Tax <code>Calculation</code>
* object.
*
* @param null|array $params
* @param null|array|string $options
Expand Down
3 changes: 2 additions & 1 deletion lib/TaxId.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* @property null|string|\Stripe\Customer $customer ID of the customer.
* @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
* @property null|\Stripe\StripeObject $owner The account or customer the tax ID belongs to.
* @property string $type Type of the tax ID, one of <code>ad_nrt</code>, <code>ae_trn</code>, <code>ar_cuit</code>, <code>au_abn</code>, <code>au_arn</code>, <code>bg_uic</code>, <code>bh_vat</code>, <code>bo_tin</code>, <code>br_cnpj</code>, <code>br_cpf</code>, <code>ca_bn</code>, <code>ca_gst_hst</code>, <code>ca_pst_bc</code>, <code>ca_pst_mb</code>, <code>ca_pst_sk</code>, <code>ca_qst</code>, <code>ch_vat</code>, <code>cl_tin</code>, <code>cn_tin</code>, <code>co_nit</code>, <code>cr_tin</code>, <code>de_stn</code>, <code>do_rcn</code>, <code>ec_ruc</code>, <code>eg_tin</code>, <code>es_cif</code>, <code>eu_oss_vat</code>, <code>eu_vat</code>, <code>gb_vat</code>, <code>ge_vat</code>, <code>hk_br</code>, <code>hu_tin</code>, <code>id_npwp</code>, <code>il_vat</code>, <code>in_gst</code>, <code>is_vat</code>, <code>jp_cn</code>, <code>jp_rn</code>, <code>jp_trn</code>, <code>ke_pin</code>, <code>kr_brn</code>, <code>kz_bin</code>, <code>li_uid</code>, <code>mx_rfc</code>, <code>my_frp</code>, <code>my_itn</code>, <code>my_sst</code>, <code>ng_tin</code>, <code>no_vat</code>, <code>no_voec</code>, <code>nz_gst</code>, <code>om_vat</code>, <code>pe_ruc</code>, <code>ph_tin</code>, <code>ro_tin</code>, <code>rs_pib</code>, <code>ru_inn</code>, <code>ru_kpp</code>, <code>sa_vat</code>, <code>sg_gst</code>, <code>sg_uen</code>, <code>si_tin</code>, <code>sv_nit</code>, <code>th_vat</code>, <code>tr_tin</code>, <code>tw_vat</code>, <code>ua_vat</code>, <code>us_ein</code>, <code>uy_ruc</code>, <code>ve_rif</code>, <code>vn_tin</code>, or <code>za_vat</code>. Note that some legacy tax IDs have type <code>unknown</code>
* @property string $type Type of the tax ID, one of <code>ad_nrt</code>, <code>ae_trn</code>, <code>ar_cuit</code>, <code>au_abn</code>, <code>au_arn</code>, <code>bg_uic</code>, <code>bh_vat</code>, <code>bo_tin</code>, <code>br_cnpj</code>, <code>br_cpf</code>, <code>ca_bn</code>, <code>ca_gst_hst</code>, <code>ca_pst_bc</code>, <code>ca_pst_mb</code>, <code>ca_pst_sk</code>, <code>ca_qst</code>, <code>ch_uid</code>, <code>ch_vat</code>, <code>cl_tin</code>, <code>cn_tin</code>, <code>co_nit</code>, <code>cr_tin</code>, <code>de_stn</code>, <code>do_rcn</code>, <code>ec_ruc</code>, <code>eg_tin</code>, <code>es_cif</code>, <code>eu_oss_vat</code>, <code>eu_vat</code>, <code>gb_vat</code>, <code>ge_vat</code>, <code>hk_br</code>, <code>hu_tin</code>, <code>id_npwp</code>, <code>il_vat</code>, <code>in_gst</code>, <code>is_vat</code>, <code>jp_cn</code>, <code>jp_rn</code>, <code>jp_trn</code>, <code>ke_pin</code>, <code>kr_brn</code>, <code>kz_bin</code>, <code>li_uid</code>, <code>mx_rfc</code>, <code>my_frp</code>, <code>my_itn</code>, <code>my_sst</code>, <code>ng_tin</code>, <code>no_vat</code>, <code>no_voec</code>, <code>nz_gst</code>, <code>om_vat</code>, <code>pe_ruc</code>, <code>ph_tin</code>, <code>ro_tin</code>, <code>rs_pib</code>, <code>ru_inn</code>, <code>ru_kpp</code>, <code>sa_vat</code>, <code>sg_gst</code>, <code>sg_uen</code>, <code>si_tin</code>, <code>sv_nit</code>, <code>th_vat</code>, <code>tr_tin</code>, <code>tw_vat</code>, <code>ua_vat</code>, <code>us_ein</code>, <code>uy_ruc</code>, <code>ve_rif</code>, <code>vn_tin</code>, or <code>za_vat</code>. Note that some legacy tax IDs have type <code>unknown</code>
* @property string $value Value of the tax ID.
* @property null|\Stripe\StripeObject $verification Tax ID verification information.
*/
Expand All @@ -41,6 +41,7 @@ class TaxId extends ApiResource
const TYPE_CA_PST_MB = 'ca_pst_mb';
const TYPE_CA_PST_SK = 'ca_pst_sk';
const TYPE_CA_QST = 'ca_qst';
const TYPE_CH_UID = 'ch_uid';
const TYPE_CH_VAT = 'ch_vat';
const TYPE_CL_TIN = 'cl_tin';
const TYPE_CN_TIN = 'cn_tin';
Expand Down
2 changes: 1 addition & 1 deletion lib/Util/ApiVersion.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@

class ApiVersion
{
const CURRENT = '2024-04-10';
const CURRENT = '2024-06-20';
}
1 change: 0 additions & 1 deletion lib/Util/ObjectTypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ class ObjectTypes
\Stripe\Payout::OBJECT_NAME => \Stripe\Payout::class,
\Stripe\Person::OBJECT_NAME => \Stripe\Person::class,
\Stripe\Plan::OBJECT_NAME => \Stripe\Plan::class,
\Stripe\PlatformTaxFee::OBJECT_NAME => \Stripe\PlatformTaxFee::class,
\Stripe\Price::OBJECT_NAME => \Stripe\Price::class,
\Stripe\Product::OBJECT_NAME => \Stripe\Product::class,
\Stripe\ProductFeature::OBJECT_NAME => \Stripe\ProductFeature::class,
Expand Down
6 changes: 3 additions & 3 deletions tests/Stripe/GeneratedExamplesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3645,7 +3645,7 @@ public function testTestHelpersIssuingAuthorizationsCapturePost()
'type' => 'diesel',
'unit' => 'liter',
'unit_cost_decimal' => '3.5',
'volume_decimal' => '10',
'quantity_decimal' => '10',
],
'lodging' => [
'check_in_at' => 1633651200,
Expand Down Expand Up @@ -3878,7 +3878,7 @@ public function testTestHelpersIssuingTransactionsCreateForceCapturePost()
'type' => 'diesel',
'unit' => 'liter',
'unit_cost_decimal' => '3.5',
'volume_decimal' => '10',
'quantity_decimal' => '10',
],
'lodging' => [
'check_in_at' => 1533651200,
Expand Down Expand Up @@ -3939,7 +3939,7 @@ public function testTestHelpersIssuingTransactionsCreateUnlinkedRefundPost()
'type' => 'diesel',
'unit' => 'liter',
'unit_cost_decimal' => '3.5',
'volume_decimal' => '10',
'quantity_decimal' => '10',
],
'lodging' => [
'check_in_at' => 1533651200,
Expand Down

0 comments on commit 4958817

Please sign in to comment.