false
if the object exists in test mode.
- * @property null|\Stripe\StripeObject $metadata 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.
- * @property null|\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 null|string $product_type Financing product identifier.
- * @property null|string $replacement The ID of the financing offer that replaced this offer.
- * @property null|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 null|string $type See financing_type.
- */
-class FinancingOffer extends \Stripe\ApiResource
-{
- const OBJECT_NAME = 'capital.financing_offer';
-
- use \Stripe\ApiOperations\All;
- use \Stripe\ApiOperations\Retrieve;
-
- const FINANCING_TYPE_CASH_ADVANCE = 'cash_advance';
- const FINANCING_TYPE_FLEX_LOAN = 'flex_loan';
-
- const PRODUCT_TYPE_REFILL = 'refill';
- const PRODUCT_TYPE_STANDARD = 'standard';
-
- const STATUS_ACCEPTED = 'accepted';
- const STATUS_CANCELED = 'canceled';
- const STATUS_COMPLETED = 'completed';
- const STATUS_DELIVERED = 'delivered';
- const STATUS_EXPIRED = 'expired';
- 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';
- const TYPE_FLEX_LOAN = 'flex_loan';
-
- /**
- * @param null|array $params
- * @param null|array|string $opts
- *
- * @throws \Stripe\Exception\ApiErrorException if the request fails
- *
- * @return \Stripe\Capital\FinancingOffer the marked financing offer
- */
- public function markDelivered($params = null, $opts = null)
- {
- $url = $this->instanceUrl() . '/mark_delivered';
- list($response, $opts) = $this->_request('post', $url, $params, $opts);
- $this->refreshFrom($response, $opts);
-
- return $this;
- }
-}
diff --git a/lib/Capital/FinancingSummary.php b/lib/Capital/FinancingSummary.php
deleted file mode 100644
index dc72b61d6..000000000
--- a/lib/Capital/FinancingSummary.php
+++ /dev/null
@@ -1,25 +0,0 @@
-/v1/capital/financing_summary will only return details
for paid_out
financing.
- */
-class FinancingSummary extends \Stripe\SingletonApiResource
-{
- const OBJECT_NAME = 'capital.financing_summary';
-
- use \Stripe\ApiOperations\SingletonRetrieve;
-
- const STATUS_ACCEPTED = 'accepted';
- const STATUS_DELIVERED = 'delivered';
- const STATUS_NONE = 'none';
-}
diff --git a/lib/Event.php b/lib/Event.php
index b86be8dda..d7a8c1538 100644
--- a/lib/Event.php
+++ b/lib/Event.php
@@ -198,6 +198,7 @@ class Event extends ApiResource
const PAYOUT_CREATED = 'payout.created';
const PAYOUT_FAILED = 'payout.failed';
const PAYOUT_PAID = 'payout.paid';
+ const PAYOUT_RECONCILIATION_COMPLETED = 'payout.reconciliation_completed';
const PAYOUT_UPDATED = 'payout.updated';
const PERSON_CREATED = 'person.created';
const PERSON_DELETED = 'person.deleted';
diff --git a/lib/InvoiceLineItem.php b/lib/InvoiceLineItem.php
index 5a588c895..d70b18b10 100644
--- a/lib/InvoiceLineItem.php
+++ b/lib/InvoiceLineItem.php
@@ -9,7 +9,6 @@
* @property string $object String representing the object's type. Objects of the same type share the same value.
* @property int $amount The amount, in %s.
* @property null|int $amount_excluding_tax The integer amount in %s representing the amount for this line item, excluding all tax and discounts.
- * @property null|\Stripe\StripeObject $applies_to
* @property string $currency Three-letter ISO currency code, in lowercase. Must be a supported currency.
* @property null|string $description An arbitrary string attached to the object. Often useful for displaying to users.
* @property null|\Stripe\StripeObject[] $discount_amounts The amount of discount calculated per discount for this line item.
diff --git a/lib/PaymentLink.php b/lib/PaymentLink.php
index d8a1f3f68..316d5494f 100644
--- a/lib/PaymentLink.php
+++ b/lib/PaymentLink.php
@@ -14,8 +14,8 @@
* href="https://stripe.com/docs/api/events/types#event_types-checkout.session.completed">checkout
* session events to track payments through payment links.
*
- * Related guide: Payment Links API
+ * Related guide: Payment Links
+ * API
*
* @property string $id Unique identifier for the object.
* @property string $object String representing the object's type. Objects of the same type share the same value.
diff --git a/lib/Product.php b/lib/Product.php
index e7f71266a..8ec9ff485 100644
--- a/lib/Product.php
+++ b/lib/Product.php
@@ -13,9 +13,8 @@
*
* Related guides: Set up
- * a subscription, share a Payment
- * Link, , share a
+ * Payment Link, accept
* payments with Checkout, and more about Products and Prices
diff --git a/lib/Quote.php b/lib/Quote.php
index f54e65d31..ee8e51710 100644
--- a/lib/Quote.php
+++ b/lib/Quote.php
@@ -230,6 +230,7 @@ public function markStaleQuote($params = null, $opts = null)
/**
* @param string $id
+ * @param string $preview_invoice
* @param null|array $params
* @param null|array|string $opts
*
@@ -237,9 +238,9 @@ public function markStaleQuote($params = null, $opts = null)
*
* @return \Stripe\Collection<\Stripe\InvoiceLineItem> list of InvoiceLineItems
*/
- public static function previewInvoiceLines($id, $params = null, $opts = null)
+ public static function previewInvoiceLines($id, $preview_invoice, $params = null, $opts = null)
{
- $url = static::resourceUrl($id) . '/preview_invoice_lines';
+ $url = static::resourceUrl($id) . '/preview_invoices/' . $preview_invoice . '/lines';
list($response, $opts) = static::_staticRequest('get', $url, $params, $opts);
$obj = \Stripe\Util\Util::convertToStripeObject($response->json, $opts);
$obj->setLastResponse($response);
diff --git a/lib/Service/Capital/CapitalServiceFactory.php b/lib/Service/Capital/CapitalServiceFactory.php
index a213a3f04..94eae064c 100644
--- a/lib/Service/Capital/CapitalServiceFactory.php
+++ b/lib/Service/Capital/CapitalServiceFactory.php
@@ -7,8 +7,6 @@
/**
* Service factory class for API resources in the Capital namespace.
*
- * @property FinancingOfferService $financingOffers
- * @property FinancingSummaryService $financingSummary
* @property FinancingTransactionService $financingTransactions
*/
class CapitalServiceFactory extends \Stripe\Service\AbstractServiceFactory
@@ -17,8 +15,6 @@ class CapitalServiceFactory extends \Stripe\Service\AbstractServiceFactory
* @var arrayfalse
if the object exists in test mode.
+ * @property null|\Stripe\StripeObject $metadata 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.
+ * @property null|\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 null|string $product_type Financing product identifier.
+ * @property null|string $replacement The ID of the financing offer that replaced this offer.
+ * @property null|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 null|string $type See financing_type.
+ */
+class FinancingOffer extends \Stripe\ApiResource
+{
+ const OBJECT_NAME = 'capital.financing_offer';
+
+ use \Stripe\ApiOperations\All;
+ use \Stripe\ApiOperations\Retrieve;
+
+ const FINANCING_TYPE_CASH_ADVANCE = 'cash_advance';
+ const FINANCING_TYPE_FLEX_LOAN = 'flex_loan';
+
+ const PRODUCT_TYPE_REFILL = 'refill';
+ const PRODUCT_TYPE_STANDARD = 'standard';
+
+ const STATUS_ACCEPTED = 'accepted';
+ const STATUS_CANCELED = 'canceled';
+ const STATUS_COMPLETED = 'completed';
+ const STATUS_DELIVERED = 'delivered';
+ const STATUS_EXPIRED = 'expired';
+ 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';
+ const TYPE_FLEX_LOAN = 'flex_loan';
+
+ /**
+ * @param null|array $params
+ * @param null|array|string $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Capital\FinancingOffer the marked financing offer
+ */
+ public function markDelivered($params = null, $opts = null)
+ {
+ $url = $this->instanceUrl() . '/mark_delivered';
+ list($response, $opts) = $this->_request('post', $url, $params, $opts);
+ $this->refreshFrom($response, $opts);
+
+ return $this;
+ }
+}
diff --git a/lib/Capital/FinancingSummary.php b/lib/Capital/FinancingSummary.php
new file mode 100644
index 000000000..dc72b61d6
--- /dev/null
+++ b/lib/Capital/FinancingSummary.php
@@ -0,0 +1,25 @@
+/v1/capital/financing_summary will only return details
for paid_out
financing.
+ */
+class FinancingSummary extends \Stripe\SingletonApiResource
+{
+ const OBJECT_NAME = 'capital.financing_summary';
+
+ use \Stripe\ApiOperations\SingletonRetrieve;
+
+ const STATUS_ACCEPTED = 'accepted';
+ const STATUS_DELIVERED = 'delivered';
+ const STATUS_NONE = 'none';
+}
diff --git a/lib/Service/Capital/CapitalServiceFactory.php b/lib/Service/Capital/CapitalServiceFactory.php
index 94eae064c..a213a3f04 100644
--- a/lib/Service/Capital/CapitalServiceFactory.php
+++ b/lib/Service/Capital/CapitalServiceFactory.php
@@ -7,6 +7,8 @@
/**
* Service factory class for API resources in the Capital namespace.
*
+ * @property FinancingOfferService $financingOffers
+ * @property FinancingSummaryService $financingSummary
* @property FinancingTransactionService $financingTransactions
*/
class CapitalServiceFactory extends \Stripe\Service\AbstractServiceFactory
@@ -15,6 +17,8 @@ class CapitalServiceFactory extends \Stripe\Service\AbstractServiceFactory
* @var arrayFor bank accounts, possible values are new
, validated
, verified
, verification_failed
, or errored
. A bank account that hasn't had any activity or validation performed is new
. If Stripe can determine that the bank account exists, its status will be validated
. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be verified
. If the verification failed for any reason, such as microdeposit failure, the status will be verification_failed
. If a transfer sent to this bank account fails, we'll set the status to errored
and will not continue to send transfers until the bank details are updated.
For external accounts, possible values are new
and errored
. Validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply. If a transfer fails, the status is set to errored
and transfers are stopped until account details are updated.
Transaction
from a calculation.
+ *
+ * @param null|array $params
+ * @param null|array|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Tax\Transaction
+ */
+ public function createFromCalculation($params = null, $opts = null)
+ {
+ return $this->request('post', '/v1/tax/transactions/create_from_calculation', $params, $opts);
+ }
+
/**
* Partially or fully reverses a previously created Transaction
.
*
diff --git a/lib/Tax/Calculation.php b/lib/Tax/Calculation.php
index def80b97a..28155b25d 100644
--- a/lib/Tax/Calculation.php
+++ b/lib/Tax/Calculation.php
@@ -17,6 +17,7 @@
* @property null|int $expires_at Timestamp of date at which the tax calculation will expire. Empty if the calculation is an unsaved preview.
* @property null|\Stripe\Collection<\Stripe\LineItem> $line_items The list of items the customer is purchasing.
* @property bool $livemode Has the value true
if the object exists in live mode or the value false
if the object exists in test mode.
+ * @property null|\Stripe\StripeObject $shipping_cost The shipping cost details for the calculation.
* @property int $tax_amount_exclusive The amount of tax to be collected on top of the line item prices.
* @property int $tax_amount_inclusive The amount of tax already included in the line item prices.
* @property int $tax_date Timestamp of date at which the tax rules and rates in effect applies for the calculation.
diff --git a/lib/Tax/Transaction.php b/lib/Tax/Transaction.php
index f392b316f..536b9197f 100644
--- a/lib/Tax/Transaction.php
+++ b/lib/Tax/Transaction.php
@@ -19,6 +19,7 @@
* @property null|\Stripe\StripeObject $metadata 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.
* @property string $reference A custom unique identifier, such as 'myOrder_123'.
* @property null|\Stripe\StripeObject $reversal If type=reversal
, contains information about what was reversed.
+ * @property null|\Stripe\StripeObject $shipping_cost The shipping cost details for the transaction.
* @property int $tax_date Timestamp of date at which the tax rules and rates in effect applies for the calculation.
* @property string $type If reversal
, this transaction reverses an earlier transaction.
*/
@@ -32,6 +33,24 @@ class Transaction extends \Stripe\ApiResource
const TYPE_REVERSAL = 'reversal';
const TYPE_TRANSACTION = 'transaction';
+ /**
+ * @param null|array $params
+ * @param null|array|string $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Tax\Transaction the created transaction
+ */
+ public static function createFromCalculation($params = null, $opts = null)
+ {
+ $url = static::classUrl() . '/create_from_calculation';
+ list($response, $opts) = static::_staticRequest('post', $url, $params, $opts);
+ $obj = \Stripe\Util\Util::convertToStripeObject($response->json, $opts);
+ $obj->setLastResponse($response);
+
+ return $obj;
+ }
+
/**
* @param null|array $params
* @param null|array|string $opts
From 3ec605d8f82a0be58e51ce92d0f0a972c8d0cd68 Mon Sep 17 00:00:00 2001
From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Date: Thu, 16 Mar 2023 22:40:01 +0000
Subject: [PATCH 5/5] Update generated code for v264
---
OPENAPI_VERSION | 2 +-
lib/Tax/Calculation.php | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION
index 8c736d3f5..d077c8303 100644
--- a/OPENAPI_VERSION
+++ b/OPENAPI_VERSION
@@ -1 +1 @@
-v262
\ No newline at end of file
+v264
\ No newline at end of file
diff --git a/lib/Tax/Calculation.php b/lib/Tax/Calculation.php
index 28155b25d..392be6298 100644
--- a/lib/Tax/Calculation.php
+++ b/lib/Tax/Calculation.php
@@ -20,8 +20,8 @@
* @property null|\Stripe\StripeObject $shipping_cost The shipping cost details for the calculation.
* @property int $tax_amount_exclusive The amount of tax to be collected on top of the line item prices.
* @property int $tax_amount_inclusive The amount of tax already included in the line item prices.
+ * @property \Stripe\StripeObject[] $tax_breakdown Breakdown of individual tax amounts that add up to the total.
* @property int $tax_date Timestamp of date at which the tax rules and rates in effect applies for the calculation.
- * @property \Stripe\StripeObject[] $tax_summary Summary of individual tax amounts that add up to the total.
*/
class Calculation extends \Stripe\ApiResource
{