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

Multiple API changes #897

Merged
merged 1 commit into from
May 20, 2020
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
1 change: 1 addition & 0 deletions types/2020-03-02/Accounts.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2159,6 +2159,7 @@ declare module 'stripe' {

/**
* Updates the metadata, account holder name, and account holder type of a bank account belonging to a [Custom account](https://stripe.com/docs/connect/custom-accounts), and optionally sets it as the default for its currency. Other bank account details are not editable by design.
*
* You can re-enable a disabled bank account by performing an update call without providing any arguments or changes.
*/
updateExternalAccount(
Expand Down
5 changes: 3 additions & 2 deletions types/2020-03-02/BalanceTransactions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ declare module 'stripe' {
status: string;

/**
* Transaction type: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead.
* Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead.
*/
type: BalanceTransaction.Type;
}
Expand Down Expand Up @@ -129,6 +129,7 @@ declare module 'stripe' {
| 'adjustment'
| 'advance'
| 'advance_funding'
| 'anticipation_repayment'
| 'application_fee'
| 'application_fee_refund'
| 'charge'
Expand Down Expand Up @@ -191,7 +192,7 @@ declare module 'stripe' {
source?: string;

/**
* Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
* Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
*/
type?: string;
}
Expand Down
2 changes: 1 addition & 1 deletion types/2020-03-02/BillingPortal/Sessions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ declare module 'stripe' {

class SessionsResource {
/**
* Creates a session of the self-serve Portal.
* Creates a session of the self-serve portal.
*/
create(
params: SessionCreateParams,
Expand Down
118 changes: 118 additions & 0 deletions types/2020-03-02/Charges.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,8 @@ declare module 'stripe' {

ideal?: PaymentMethodDetails.Ideal;

interac_present?: PaymentMethodDetails.InteracPresent;

klarna?: PaymentMethodDetails.Klarna;

multibanco?: PaymentMethodDetails.Multibanco;
Expand Down Expand Up @@ -1067,6 +1069,122 @@ declare module 'stripe' {
| 'TRIONL2U';
}

interface InteracPresent {
/**
* Card brand. Can be `interac`, `mastercard` or `visa`.
*/
brand: string | null;

/**
* The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`).
*/
cardholder_name: string | null;

/**
* Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.
*/
country: string | null;

/**
* Authorization response cryptogram.
*/
emv_auth_data: string | null;

/**
* Two-digit number representing the card's expiration month.
*/
exp_month: number | null;

/**
* Four-digit number representing the card's expiration year.
*/
exp_year: number | null;

/**
* Uniquely identifies this particular card number. You can use this attribute to check whether two customers who've signed up with you are using the same card number,for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
*/
fingerprint: string | null;

/**
* Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
*/
funding: string | null;

/**
* ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
*/
generated_card: string | null;

/**
* The last four digits of the card.
*/
last4: string | null;

/**
* Identifies which network this charge was processed on. Can be `amex`, `diners`, `discover`, `interac`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.
*/
network: string | null;

/**
* How were card details read in this transaction. Can be contact_emv, contactless_emv, magnetic_stripe_fallback, magnetic_stripe_track2, or contactless_magstripe_mode
*/
read_method: string | null;

/**
* A collection of fields required to be displayed on receipts. Only required for EMV transactions.
*/
receipt: InteracPresent.Receipt | null;
}

namespace InteracPresent {
interface Receipt {
/**
* For Interac transactions - the source account type of the funds
*/
account_type?: string;

/**
* EMV tag 9F26, cryptogram generated by the integrated circuit chip.
*/
application_cryptogram: string | null;

/**
* Mnenomic of the Application Identifier.
*/
application_preferred_name: string | null;

/**
* Identifier for this transaction.
*/
authorization_code: string | null;

/**
* EMV tag 8A. A code returned by the card issuer.
*/
authorization_response_code: string | null;

/**
* How the cardholder verified ownership of the card.
*/
cardholder_verification_method: string | null;

/**
* EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
*/
dedicated_file_name: string | null;

/**
* The outcome of a series of EMV functions performed by the card reader.
*/
terminal_verification_results: string | null;

/**
* An indication of various EMV functions performed during the transaction.
*/
transaction_status_information: string | null;
}
}

interface Klarna {}

interface Multibanco {
Expand Down
8 changes: 4 additions & 4 deletions types/2020-03-02/Checkout/Sessions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ declare module 'stripe' {
display_items?: Array<Session.DisplayItem>;

/**
* The line items purchased by the customer. [Expand](https://stripe.com/docs/api/expanding_objects) this field to include it in the response.
* The line items purchased by the customer.
*/
line_items?: ApiList<Stripe.LineItem> | null;
line_items?: ApiList<Stripe.LineItem>;
cjavilla-stripe marked this conversation as resolved.
Show resolved Hide resolved

/**
* Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
Expand Down Expand Up @@ -150,7 +150,7 @@ declare module 'stripe' {
*
* For example, you might have a single "gold" product that has plans for $10/month, $100/year, €9/month, and €90/year.
*
* Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/billing/subscriptions/products-and-prices).
* Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/billing/prices-guide).
*/
plan?: Stripe.Plan;

Expand Down Expand Up @@ -509,7 +509,7 @@ declare module 'stripe' {
* is complete.
* If you'd like access to the Checkout Session for the successful
* payment, read more about it in our guide on [fulfilling your payments
* with webhooks](https://stripe.com/docs/payments/checkout/fulfillment#webhooks).
* with webhooks](https://stripe.com/docs/payments/checkout/accept-a-payment#payment-success).
*/
success_url: string;

Expand Down
6 changes: 3 additions & 3 deletions types/2020-03-02/CreditNotes.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -434,9 +434,9 @@ declare module 'stripe' {
* in any combination of the following:
*
*
* Refund: create a new refund (using refund_amount) or link an existing refund (using refund).
* Customer balance credit: credit the customer's balance (using credit_amount) which will be automatically applied to their next invoice when it's finalized.
* Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
* Refund: create a new refund (using refund_amount) or link an existing refund (using refund).
* Customer balance credit: credit the customer's balance (using credit_amount) which will be automatically applied to their next invoice when it's finalized.
* Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
*
*
* For post-payment credit notes the sum of the refund, credit and outside of Stripe amounts must equal the credit note total.
Expand Down
4 changes: 2 additions & 2 deletions types/2020-03-02/Issuing/Transactions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ declare module 'stripe' {
namespace Flight {
interface Segment {
/**
* The flight's destination airport code.
* The three-letter IATA airport code of the flight's destination.
*/
arrival_airport_code: string | null;

Expand All @@ -189,7 +189,7 @@ declare module 'stripe' {
carrier: string | null;

/**
* The airport code that the flight departed from.
* The three-letter IATA airport code that the flight departed from.
*/
departure_airport_code: string | null;

Expand Down
11 changes: 11 additions & 0 deletions types/2020-03-02/PaymentMethods.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ declare module 'stripe' {

ideal?: PaymentMethod.Ideal;

interac_present?: PaymentMethod.InteracPresent;

/**
* Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
*/
Expand Down Expand Up @@ -355,6 +357,8 @@ declare module 'stripe' {
| 'TRIONL2U';
}

interface InteracPresent {}

interface SepaDebit {
/**
* Bank code of bank associated with the bank account.
Expand Down Expand Up @@ -427,6 +431,11 @@ declare module 'stripe' {
*/
ideal?: PaymentMethodCreateParams.Ideal;

/**
* If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
*/
interac_present?: PaymentMethodCreateParams.InteracPresent;

/**
* Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
*/
Expand Down Expand Up @@ -604,6 +613,8 @@ declare module 'stripe' {
| 'van_lanschot';
}

interface InteracPresent {}

interface SepaDebit {
/**
* IBAN of the bank account.
Expand Down
2 changes: 1 addition & 1 deletion types/2020-03-02/Prices.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ declare module 'stripe' {
/**
* Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
*/
tiers: Array<Price.Tier> | null;
tiers?: Array<Price.Tier>;

/**
* Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.
Expand Down
1 change: 1 addition & 0 deletions types/2020-03-02/Reporting/ReportRuns.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ declare module 'stripe' {
type ReportingCategory =
| 'advance'
| 'advance_funding'
| 'anticipation_repayment'
| 'charge'
| 'charge_failure'
| 'connect_collection_transfer'
Expand Down
2 changes: 1 addition & 1 deletion types/2020-03-02/SubscriptionItems.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ declare module 'stripe' {
*
* For example, you might have a single "gold" product that has plans for $10/month, $100/year, €9/month, and €90/year.
*
* Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/billing/subscriptions/products-and-prices).
* Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/billing/prices-guide).
*/
plan: Stripe.Plan;

Expand Down
Loading