Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API Updates for beta branch #1390

Merged
merged 9 commits into from
Nov 2, 2022
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 .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ jobs:

- name: Coveralls
run: vendor/bin/php-coveralls -v --coverage_clover='clover.xml' --json_path='coveralls-upload.json'
if: matrix.php-version == '8.1' && matrix.env == 'AUTOLOAD=1'
if: env.COVERALLS_REPO_TOKEN && matrix.php-version == '8.1' && matrix.env == 'AUTOLOAD=1'
env:
COVERALLS_RUN_LOCALLY: 1
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v203
v205
8 changes: 4 additions & 4 deletions lib/AccountSession.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,19 @@

/**
* An AccountSession allows a Connect platform to grant access to a connected
* account in Connect Elements.
* account in Connect embedded UIs.
*
* We recommend that you create an AccountSession each time you need to display an
* embedded UI to your user. Do not save AccountSessions to your database as they
* expire relatively quickly, and cannot be used more than once.
*
* Related guide: <a
* href="https://stripe.com/docs/connect/get-started-connect-elements">Connect
* Elements</a>.
* href="https://stripe.com/docs/connect/get-started-connect-embedded-uis">Connect
* embedded UIs</a>.
*
* @property string $object String representing the object's type. Objects of the same type share the same value.
* @property string $account The ID of the account the AccountSession was created for
* @property string $client_secret <p>The client secret of this AccountSession. Used on the client to set up secure access to the given <code>account</code>.</p><p>The client secret can be used to provide access to <code>account</code> from your frontend. It should not be stored, logged, or exposed to anyone other than the connected account. Make sure that you have TLS enabled on any page that includes the client secret.</p><p>Refer to our docs to <a href="https://stripe.com/docs/connect/get-started-connect-elements">setup Connect Elements</a> and learn about how <code>client_secret</code> should be handled.</p>
* @property string $client_secret <p>The client secret of this AccountSession. Used on the client to set up secure access to the given <code>account</code>.</p><p>The client secret can be used to provide access to <code>account</code> from your frontend. It should not be stored, logged, or exposed to anyone other than the connected account. Make sure that you have TLS enabled on any page that includes the client secret.</p><p>Refer to our docs to <a href="https://stripe.com/docs/connect/get-started-connect-embedded-uis">setup Connect embedded UIs</a> and learn about how <code>client_secret</code> should be handled.</p>
* @property int $expires_at The timestamp at which this AccountSession will expire.
* @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.
*/
Expand Down
3 changes: 3 additions & 0 deletions lib/Capital/FinancingOffer.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
* @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
* @property \Stripe\StripeObject $offered_terms This is an object representing the terms of an offer of financing from Stripe Capital to a Connected account. This resource represents both the terms offered to the Connected account.
* @property string $product_type Financing product identifier.
* @property string $replacement The ID of the financing offer that replaced this offer.
* @property string $replacement_for The ID of the financing offer that this offer is a replacement for.
* @property string $status The current status of the offer.
* @property string $type See <a href="https://stripe.com/docs/api/capital/connect_financing_object#financing_offer_object-financing_type">financing_type</a>.
*/
Expand All @@ -43,6 +45,7 @@ class FinancingOffer extends \Stripe\ApiResource
const STATUS_FULLY_REPAID = 'fully_repaid';
const STATUS_PAID_OUT = 'paid_out';
const STATUS_REJECTED = 'rejected';
const STATUS_REPLACED = 'replaced';
const STATUS_UNDELIVERED = 'undelivered';

const TYPE_CASH_ADVANCE = 'cash_advance';
Expand Down
2 changes: 2 additions & 0 deletions lib/PaymentMethod.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
* @property \Stripe\StripeObject $boleto
* @property \Stripe\StripeObject $card
* @property \Stripe\StripeObject $card_present
* @property \Stripe\StripeObject $cashapp
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
* @property null|string|\Stripe\Customer $customer The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.
* @property \Stripe\StripeObject $customer_balance
Expand All @@ -56,6 +57,7 @@
* @property string $type The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
* @property \Stripe\StripeObject $us_bank_account
* @property \Stripe\StripeObject $wechat_pay
* @property \Stripe\StripeObject $zip
*/
class PaymentMethod extends ApiResource
{
Expand Down
5 changes: 5 additions & 0 deletions lib/Refund.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@
* been created but not yet refunded. Funds will be refunded to the credit or debit
* card that was originally charged.
*
* Stripe Tax users with recurring payments and invoices can create <a
* href="https://stripe.com/docs/api/credit_notes">Credit Notes</a>, which reduce
* overall tax liability because tax is correctly recalculated and apportioned to
* the related invoice.
*
* Related guide: <a href="https://stripe.com/docs/refunds">Refunds</a>.
*
* @property string $id Unique identifier for the object.
Expand Down
8 changes: 6 additions & 2 deletions lib/Service/Issuing/AuthorizationService.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ public function all($params = null, $opts = null)
* Approves a pending Issuing <code>Authorization</code> object. This request
* should be made within the timeout window of the <a
* href="/docs/issuing/controls/real-time-authorizations">real-time
* authorization</a> flow.
* authorization</a> flow. You can also respond directly to the webhook request to
* approve an authorization (preferred). More details can be found <a
* href="https://site-admin.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">here</a>.
*
* @param string $id
* @param null|array $params
Expand All @@ -46,7 +48,9 @@ public function approve($id, $params = null, $opts = null)
* Declines a pending Issuing <code>Authorization</code> object. This request
* should be made within the timeout window of the <a
* href="/docs/issuing/controls/real-time-authorizations">real time
* authorization</a> flow.
* authorization</a> flow. You can also respond directly to the webhook request to
* decline an authorization (preferred). More details can be found <a
* href="https://site-admin.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">here</a>.
*
* @param string $id
* @param null|array $params
Expand Down
1 change: 1 addition & 0 deletions lib/Subscription.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
* @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 \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
* @property null|int $next_pending_invoice_item_invoice Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at <code>pending_invoice_item_interval</code>.
* @property null|string|\Stripe\Account $on_behalf_of The account (if any) the charge was made on behalf of for charges associated with this subscription. See the Connect documentation for details.
* @property null|\Stripe\StripeObject $pause_collection If specified, payment collection for this subscription will be paused.
* @property null|\Stripe\StripeObject $payment_settings Payment settings passed on to invoices created by the subscription.
* @property null|\Stripe\StripeObject $pending_invoice_item_interval Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling <a href="https://stripe.com/docs/api#create_invoice">Create an invoice</a> for the given subscription at the specified interval.
Expand Down
5 changes: 4 additions & 1 deletion lib/TaxId.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
* @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 string $type Type of the tax ID, one of <code>ae_trn</code>, <code>au_abn</code>, <code>au_arn</code>, <code>bg_uic</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>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>li_uid</code>, <code>mx_rfc</code>, <code>my_frp</code>, <code>my_itn</code>, <code>my_sst</code>, <code>no_vat</code>, <code>nz_gst</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>th_vat</code>, <code>tw_vat</code>, <code>ua_vat</code>, <code>us_ein</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>ae_trn</code>, <code>au_abn</code>, <code>au_arn</code>, <code>bg_uic</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>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>li_uid</code>, <code>mx_rfc</code>, <code>my_frp</code>, <code>my_itn</code>, <code>my_sst</code>, <code>no_vat</code>, <code>nz_gst</code>, <code>ph_tin</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>th_vat</code>, <code>tr_tin</code>, <code>tw_vat</code>, <code>ua_vat</code>, <code>us_ein</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 @@ -42,6 +42,7 @@ class TaxId extends ApiResource
const TYPE_CA_QST = 'ca_qst';
const TYPE_CH_VAT = 'ch_vat';
const TYPE_CL_TIN = 'cl_tin';
const TYPE_EG_TIN = 'eg_tin';
const TYPE_ES_CIF = 'es_cif';
const TYPE_EU_OSS_VAT = 'eu_oss_vat';
const TYPE_EU_VAT = 'eu_vat';
Expand All @@ -65,13 +66,15 @@ class TaxId extends ApiResource
const TYPE_MY_SST = 'my_sst';
const TYPE_NO_VAT = 'no_vat';
const TYPE_NZ_GST = 'nz_gst';
const TYPE_PH_TIN = 'ph_tin';
const TYPE_RU_INN = 'ru_inn';
const TYPE_RU_KPP = 'ru_kpp';
const TYPE_SA_VAT = 'sa_vat';
const TYPE_SG_GST = 'sg_gst';
const TYPE_SG_UEN = 'sg_uen';
const TYPE_SI_TIN = 'si_tin';
const TYPE_TH_VAT = 'th_vat';
const TYPE_TR_TIN = 'tr_tin';
const TYPE_TW_VAT = 'tw_vat';
const TYPE_UA_VAT = 'ua_vat';
const TYPE_UNKNOWN = 'unknown';
Expand Down