Commit 509e3f8d authored by mattwire's avatar mattwire Committed by mattwire

Update stripe-php library

parent 113517f0
......@@ -8,16 +8,16 @@
"packages": [
{
"name": "stripe/stripe-php",
"version": "v6.30.4",
"version": "v6.40.0",
"source": {
"type": "git",
"url": "https://github.com/stripe/stripe-php.git",
"reference": "0d9e2773b1df27d4f0c590b15bed3a1433e0414c"
"reference": "9c22ffab790ef4dae0f371929de50e8b53c9ec8d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/stripe/stripe-php/zipball/0d9e2773b1df27d4f0c590b15bed3a1433e0414c",
"reference": "0d9e2773b1df27d4f0c590b15bed3a1433e0414c",
"url": "https://api.github.com/repos/stripe/stripe-php/zipball/9c22ffab790ef4dae0f371929de50e8b53c9ec8d",
"reference": "9c22ffab790ef4dae0f371929de50e8b53c9ec8d",
"shasum": ""
},
"require": {
......@@ -60,7 +60,7 @@
"payment processing",
"stripe"
],
"time": "2019-02-27T18:07:30+00:00"
"time": "2019-06-27T23:24:51+00:00"
}
],
"packages-dev": [],
......
......@@ -279,7 +279,7 @@ class ClassLoader
*/
public function setApcuPrefix($apcuPrefix)
{
$this->apcuPrefix = function_exists('apcu_fetch') && ini_get('apc.enabled') ? $apcuPrefix : null;
$this->apcuPrefix = function_exists('apcu_fetch') && filter_var(ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? $apcuPrefix : null;
}
/**
......@@ -377,7 +377,7 @@ class ClassLoader
$subPath = $class;
while (false !== $lastPos = strrpos($subPath, '\\')) {
$subPath = substr($subPath, 0, $lastPos);
$search = $subPath.'\\';
$search = $subPath . '\\';
if (isset($this->prefixDirsPsr4[$search])) {
$pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1);
foreach ($this->prefixDirsPsr4[$search] as $dir) {
......
[
{
"name": "stripe/stripe-php",
"version": "v6.30.4",
"version_normalized": "6.30.4.0",
"version": "v6.40.0",
"version_normalized": "6.40.0.0",
"source": {
"type": "git",
"url": "https://github.com/stripe/stripe-php.git",
"reference": "0d9e2773b1df27d4f0c590b15bed3a1433e0414c"
"reference": "9c22ffab790ef4dae0f371929de50e8b53c9ec8d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/stripe/stripe-php/zipball/0d9e2773b1df27d4f0c590b15bed3a1433e0414c",
"reference": "0d9e2773b1df27d4f0c590b15bed3a1433e0414c",
"url": "https://api.github.com/repos/stripe/stripe-php/zipball/9c22ffab790ef4dae0f371929de50e8b53c9ec8d",
"reference": "9c22ffab790ef4dae0f371929de50e8b53c9ec8d",
"shasum": ""
},
"require": {
......@@ -26,7 +26,7 @@
"squizlabs/php_codesniffer": "~2.0",
"symfony/process": "~2.8"
},
"time": "2019-02-27T18:07:30+00:00",
"time": "2019-06-27T23:24:51+00:00",
"type": "library",
"extra": {
"branch-alias": {
......
# Changelog
## 6.40.0 - 2019-06-27
* [#675](https://github.com/stripe/stripe-php/pull/675) Add support for `SetupIntent` resource and APIs
## 6.39.2 - 2019-06-26
* [#676](https://github.com/stripe/stripe-php/pull/676) Fix exception message in `CustomerBalanceTransaction::update()`
## 6.39.1 - 2019-06-25
* [#674](https://github.com/stripe/stripe-php/pull/674) Add new constants for `collection_method` on `Invoice`
## 6.39.0 - 2019-06-24
* [#673](https://github.com/stripe/stripe-php/pull/673) Enable request latency telemetry by default
## 6.38.0 - 2019-06-17
* [#649](https://github.com/stripe/stripe-php/pull/649) Add support for `CustomerBalanceTransaction` resource and APIs
## 6.37.2 - 2019-06-17
* [#671](https://github.com/stripe/stripe-php/pull/671) Add new PHPDoc
* [#672](https://github.com/stripe/stripe-php/pull/672) Add constants for `submit_type` on Checkout `Session`
## 6.37.1 - 2019-06-14
* [#670](https://github.com/stripe/stripe-php/pull/670) Add new PHPDoc
## 6.37.0 - 2019-05-23
* [#663](https://github.com/stripe/stripe-php/pull/663) Add support for `radar.early_fraud_warning` resource
## 6.36.0 - 2019-05-22
* [#661](https://github.com/stripe/stripe-php/pull/661) Add constants for new TaxId types
* [#662](https://github.com/stripe/stripe-php/pull/662) Add constants for BalanceTransaction types
## 6.35.2 - 2019-05-20
* [#655](https://github.com/stripe/stripe-php/pull/655) Add constants for payment intent statuses
* [#659](https://github.com/stripe/stripe-php/pull/659) Fix PHPDoc for various nested Account actions
* [#660](https://github.com/stripe/stripe-php/pull/660) Fix various PHPDoc
## 6.35.1 - 2019-05-20
* [#658](https://github.com/stripe/stripe-php/pull/658) Use absolute value when checking timestamp tolerance
## 6.35.0 - 2019-05-14
* [#651](https://github.com/stripe/stripe-php/pull/651) Add support for the Capability resource and APIs
## 6.34.6 - 2019-05-13
* [#654](https://github.com/stripe/stripe-php/pull/654) Fix typo in definition of `Event::PAYMENT_METHOD_ATTACHED` constant
## 6.34.5 - 2019-05-06
* [#647](https://github.com/stripe/stripe-php/pull/647) Set the return type to static for more operations
## 6.34.4 - 2019-05-06
* [#650](https://github.com/stripe/stripe-php/pull/650) Add missing constants for Event types
## 6.34.3 - 2019-05-01
* [#644](https://github.com/stripe/stripe-php/pull/644) Update return type to `static` to improve static analysis
* [#645](https://github.com/stripe/stripe-php/pull/645) Fix constant for `payment_intent.payment_failed`
## 6.34.2 - 2019-04-26
* [#642](https://github.com/stripe/stripe-php/pull/642) Fix an issue where existing idempotency keys would be overwritten when using automatic retries
## 6.34.1 - 2019-04-25
* [#640](https://github.com/stripe/stripe-php/pull/640) Add missing phpdocs
## 6.34.0 - 2019-04-24
* [#626](https://github.com/stripe/stripe-php/pull/626) Add support for the `TaxRate` resource and APIs
* [#639](https://github.com/stripe/stripe-php/pull/639) Fix multiple phpdoc issues
## 6.33.0 - 2019-04-22
* [#630](https://github.com/stripe/stripe-php/pull/630) Add support for the `TaxId` resource and APIs
## 6.32.1 - 2019-04-19
* [#636](https://github.com/stripe/stripe-php/pull/636) Correct type of `$personId` in PHPDoc
## 6.32.0 - 2019-04-18
* [#621](https://github.com/stripe/stripe-php/pull/621) Add support for `CreditNote`
## 6.31.5 - 2019-04-12
* [#628](https://github.com/stripe/stripe-php/pull/628) Add constants for `person.*` event types
* [#628](https://github.com/stripe/stripe-php/pull/628) Add missing constants for `Account` and `Person`
## 6.31.4 - 2019-04-05
* [#624](https://github.com/stripe/stripe-php/pull/624) Fix encoding of nested parameters in multipart requests
## 6.31.3 - 2019-04-02
* [#623](https://github.com/stripe/stripe-php/pull/623) Only use HTTP/2 with curl >= 7.60.0
## 6.31.2 - 2019-03-25
* [#619](https://github.com/stripe/stripe-php/pull/619) Fix PHPDoc return types for list methods for nested resources
## 6.31.1 - 2019-03-22
* [#612](https://github.com/stripe/stripe-php/pull/612) Add a lot of constants
* [#614](https://github.com/stripe/stripe-php/pull/614) Add missing subscription status constants
## 6.31.0 - 2019-03-18
* [#600](https://github.com/stripe/stripe-php/pull/600) Add support for the `PaymentMethod` resource and APIs
* [#606](https://github.com/stripe/stripe-php/pull/606) Add support for retrieving a Checkout `Session`
* [#611](https://github.com/stripe/stripe-php/pull/611) Add support for deleting a Terminal `Location` and `Reader`
## 6.30.5 - 2019-03-11
* [#607](https://github.com/stripe/stripe-php/pull/607) Correctly handle case where a metadata key is called `metadata`
## 6.30.4 - 2019-02-27
* [#602](https://github.com/stripe/stripe-php/pull/602) Add `subscription_schedule` to `Subscription` for PHPDoc.
......
......@@ -6,7 +6,11 @@
[![License](https://poser.pugx.org/stripe/stripe-php/license.svg)](https://packagist.org/packages/stripe/stripe-php)
[![Code Coverage](https://coveralls.io/repos/stripe/stripe-php/badge.svg?branch=master)](https://coveralls.io/r/stripe/stripe-php?branch=master)
You can sign up for a Stripe account at https://stripe.com.
The Stripe PHP library provides convenient access to the Stripe API from
applications written in the PHP language. It includes a pre-defined set of
classes for API resources that initialize themselves dynamically from API
responses which makes it compatible with a wide range of versions of the Stripe
API.
## Requirements
......@@ -56,7 +60,7 @@ echo $charge;
## Documentation
Please see https://stripe.com/docs/api for up-to-date documentation.
See the [PHP API docs](https://stripe.com/docs/api/php#intro).
## Legacy Version Support
......@@ -179,6 +183,17 @@ an intermittent network problem:
[Idempotency keys][idempotency-keys] are added to requests to guarantee that
retries are safe.
### Request latency telemetry
By default, the library sends request latency telemetry to Stripe. These
numbers help Stripe improve the overall latency of its API for all users.
You can disable this behavior if you prefer:
```php
\Stripe\Stripe::setEnableTelemetry(false);
```
## Development
Get [Composer][composer]. For example, on Mac OS:
......
......@@ -67,13 +67,16 @@ require(dirname(__FILE__) . '/lib/BalanceTransaction.php');
require(dirname(__FILE__) . '/lib/BankAccount.php');
require(dirname(__FILE__) . '/lib/BitcoinReceiver.php');
require(dirname(__FILE__) . '/lib/BitcoinTransaction.php');
require(dirname(__FILE__) . '/lib/Capability.php');
require(dirname(__FILE__) . '/lib/Card.php');
require(dirname(__FILE__) . '/lib/Charge.php');
require(dirname(__FILE__) . '/lib/Checkout/Session.php');
require(dirname(__FILE__) . '/lib/Collection.php');
require(dirname(__FILE__) . '/lib/CountrySpec.php');
require(dirname(__FILE__) . '/lib/Coupon.php');
require(dirname(__FILE__) . '/lib/CreditNote.php');
require(dirname(__FILE__) . '/lib/Customer.php');
require(dirname(__FILE__) . '/lib/CustomerBalanceTransaction.php');
require(dirname(__FILE__) . '/lib/Discount.php');
require(dirname(__FILE__) . '/lib/Dispute.php');
require(dirname(__FILE__) . '/lib/EphemeralKey.php');
......@@ -97,10 +100,12 @@ require(dirname(__FILE__) . '/lib/Order.php');
require(dirname(__FILE__) . '/lib/OrderItem.php');
require(dirname(__FILE__) . '/lib/OrderReturn.php');
require(dirname(__FILE__) . '/lib/PaymentIntent.php');
require(dirname(__FILE__) . '/lib/PaymentMethod.php');
require(dirname(__FILE__) . '/lib/Payout.php');
require(dirname(__FILE__) . '/lib/Person.php');
require(dirname(__FILE__) . '/lib/Plan.php');
require(dirname(__FILE__) . '/lib/Product.php');
require(dirname(__FILE__) . '/lib/Radar/EarlyFraudWarning.php');
require(dirname(__FILE__) . '/lib/Radar/ValueList.php');
require(dirname(__FILE__) . '/lib/Radar/ValueListItem.php');
require(dirname(__FILE__) . '/lib/Recipient.php');
......@@ -109,6 +114,7 @@ require(dirname(__FILE__) . '/lib/Refund.php');
require(dirname(__FILE__) . '/lib/Reporting/ReportRun.php');
require(dirname(__FILE__) . '/lib/Reporting/ReportType.php');
require(dirname(__FILE__) . '/lib/Review.php');
require(dirname(__FILE__) . '/lib/SetupIntent.php');
require(dirname(__FILE__) . '/lib/SKU.php');
require(dirname(__FILE__) . '/lib/Sigma/ScheduledQueryRun.php');
require(dirname(__FILE__) . '/lib/Source.php');
......@@ -117,6 +123,8 @@ require(dirname(__FILE__) . '/lib/Subscription.php');
require(dirname(__FILE__) . '/lib/SubscriptionItem.php');
require(dirname(__FILE__) . '/lib/SubscriptionSchedule.php');
require(dirname(__FILE__) . '/lib/SubscriptionScheduleRevision.php');
require(dirname(__FILE__) . '/lib/TaxId.php');
require(dirname(__FILE__) . '/lib/TaxRate.php');
require(dirname(__FILE__) . '/lib/Terminal/ConnectionToken.php');
require(dirname(__FILE__) . '/lib/Terminal/Location.php');
require(dirname(__FILE__) . '/lib/Terminal/Reader.php');
......
......@@ -42,6 +42,37 @@ class Account extends ApiResource
}
use ApiOperations\Update;
/**
* Possible string representations of an account's business type.
* @link https://stripe.com/docs/api/accounts/object#account_object-business_type
*/
const BUSINESS_TYPE_COMPANY = 'company';
const BUSINESS_TYPE_INDIVIDUAL = 'individual';
/**
* Possible string representations of an account's capabilities.
* @link https://stripe.com/docs/api/accounts/object#account_object-capabilities
*/
const CAPABILITY_CARD_PAYMENTS = 'card_payments';
const CAPABILITY_LEGACY_PAYMENTS = 'legacy_payments';
const CAPABILITY_PLATFORM_PAYMENTS = 'platform_payments';
/**
* Possible string representations of an account's capability status.
* @link https://stripe.com/docs/api/accounts/object#account_object-capabilities
*/
const CAPABILITY_STATUS_ACTIVE = 'active';
const CAPABILITY_STATUS_INACTIVE = 'inactive';
const CAPABILITY_STATUS_PENDING = 'pending';
/**
* Possible string representations of an account's type.
* @link https://stripe.com/docs/api/accounts/object#account_object-type
*/
const TYPE_CUSTOM = 'custom';
const TYPE_EXPRESS = 'express';
const TYPE_STANDARD = 'standard';
public static function getSavedNestedResources()
{
static $savedNestedResources = null;
......@@ -54,6 +85,7 @@ class Account extends ApiResource
return $savedNestedResources;
}
const PATH_CAPABILITIES = '/capabilities';
const PATH_EXTERNAL_ACCOUNTS = '/external_accounts';
const PATH_LOGIN_LINKS = '/login_links';
const PATH_PERSONS = '/persons';
......@@ -97,21 +129,6 @@ class Account extends ApiResource
return $this;
}
/**
* @param array|null $params
* @param array|string|null $options
*
* @return Collection The list of persons.
*/
public function persons($params = null, $options = null)
{
$url = $this->instanceUrl() . '/persons';
list($response, $opts) = $this->_request('get', $url, $params, $options);
$obj = Util\Util::convertToStripeObject($response, $opts);
$obj->setLastResponse($response);
return $obj;
}
/**
* @param array|null $clientId
* @param array|string|null $opts
......@@ -127,8 +144,53 @@ class Account extends ApiResource
return OAuth::deauthorize($params, $opts);
}
/*
* Capabilities methods
* We can not add the capabilities() method today as the Account object already has a
* capabilities property which is a hash and not the sub-list of capabilities.
*/
/**
* @param string $id The ID of the account to which the capability belongs.
* @param string $capabilityId The ID of the capability to retrieve.
* @param array|null $params
* @param array|string|null $opts
*
* @return Capability
*/
public static function retrieveCapability($id, $capabilityId, $params = null, $opts = null)
{
return self::_retrieveNestedResource($id, static::PATH_CAPABILITIES, $capabilityId, $params, $opts);
}
/**
* @param string $id The ID of the account to which the capability belongs.
* @param string $capabilityId The ID of the capability to update.
* @param array|null $params
* @param array|string|null $opts
*
* @return Capability
*/
public static function updateCapability($id, $capabilityId, $params = null, $opts = null)
{
return self::_updateNestedResource($id, static::PATH_CAPABILITIES, $capabilityId, $params, $opts);
}
/**
* @param string $id The ID of the account on which to retrieve the capabilities.
* @param array|null $params
* @param array|string|null $opts
*
* @return Collection The list of capabilities.
*/
public static function allCapabilities($id, $params = null, $opts = null)
{
return self::_allNestedResources($id, static::PATH_CAPABILITIES, $params, $opts);
}
/**
* @param string|null $id The ID of the account on which to create the external account.
* @param string $id The ID of the account on which to create the external account.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -140,8 +202,8 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account to which the external account belongs.
* @param array|null $externalAccountId The ID of the external account to retrieve.
* @param string $id The ID of the account to which the external account belongs.
* @param string $externalAccountId The ID of the external account to retrieve.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -153,8 +215,8 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account to which the external account belongs.
* @param array|null $externalAccountId The ID of the external account to update.
* @param string $id The ID of the account to which the external account belongs.
* @param string $externalAccountId The ID of the external account to update.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -166,8 +228,8 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account to which the external account belongs.
* @param array|null $externalAccountId The ID of the external account to delete.
* @param string $id The ID of the account to which the external account belongs.
* @param string $externalAccountId The ID of the external account to delete.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -179,11 +241,11 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account on which to retrieve the external accounts.
* @param string $id The ID of the account on which to retrieve the external accounts.
* @param array|null $params
* @param array|string|null $opts
*
* @return BankAccount|Card
* @return Collection The list of external accounts (BankAccount or Card).
*/
public static function allExternalAccounts($id, $params = null, $opts = null)
{
......@@ -191,7 +253,7 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account on which to create the login link.
* @param string $id The ID of the account on which to create the login link.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -203,7 +265,22 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account on which to create the person.
* @param array|null $params
* @param array|string|null $options
*
* @return Collection The list of persons.
*/
public function persons($params = null, $options = null)
{
$url = $this->instanceUrl() . '/persons';
list($response, $opts) = $this->_request('get', $url, $params, $options);
$obj = Util\Util::convertToStripeObject($response, $opts);
$obj->setLastResponse($response);
return $obj;
}
/**
* @param string $id The ID of the account on which to create the person.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -215,8 +292,8 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account to which the person belongs.
* @param array|null $personId The ID of the person to retrieve.
* @param string $id The ID of the account to which the person belongs.
* @param string $personId The ID of the person to retrieve.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -228,8 +305,8 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account to which the person belongs.
* @param array|null $personId The ID of the person to update.
* @param string $id The ID of the account to which the person belongs.
* @param string $personId The ID of the person to update.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -241,8 +318,8 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account to which the person belongs.
* @param array|null $personId The ID of the person to delete.
* @param string $id The ID of the account to which the person belongs.
* @param string $personId The ID of the person to delete.
* @param array|null $params
* @param array|string|null $opts
*
......@@ -254,11 +331,11 @@ class Account extends ApiResource
}
/**
* @param string|null $id The ID of the account on which to retrieve the persons.
* @param string $id The ID of the account on which to retrieve the persons.
* @param array|null $params
* @param array|string|null $opts
*
* @return Person
* @return Collection The list of persons.
*/
public static function allPersons($id, $params = null, $opts = null)
{
......
......@@ -13,7 +13,7 @@ trait Create
* @param array|null $params
* @param array|string|null $options
*
* @return \Stripe\ApiResource The created resource.
* @return static The created resource.
*/
public static function create($params = null, $options = null)
{
......
......@@ -13,7 +13,7 @@ trait Delete
* @param array|null $params
* @param array|string|null $opts
*
* @return \Stripe\ApiResource The deleted resource.
* @return static The deleted resource.
*/
public function delete($params = null, $opts = null)
{
......
......@@ -15,7 +15,7 @@ trait Retrieve
* or an options array containing an `id` key.
* @param array|string|null $opts
*
* @return \Stripe\StripeObject
* @return static
*/
public static function retrieve($id, $opts = null)
{
......
......@@ -15,7 +15,7 @@ trait Update
* @param array|null $params
* @param array|string|null $opts
*
* @return \Stripe\ApiResource The updated resource.
* @return static The updated resource.
*/
public static function update($id, $params = null, $opts = null)
{
......@@ -31,7 +31,7 @@ trait Update
/**
* @param array|string|null $opts
*
* @return \Stripe\ApiResource The saved resource.
* @return static The saved resource.
*/
public function save($opts = null)
{
......
......@@ -89,7 +89,7 @@ class ApplicationFee extends ApiResource
* @param array|null $params
* @param array|string|null $opts
*
* @return ApplicationFeeRefund
* @return Collection The list of refunds.
*/
public static function allRefunds($id, $params = null, $opts = null)
{
......
......@@ -30,6 +30,40 @@ class BalanceTransaction extends ApiResource
use ApiOperations\All;
use ApiOperations\Retrieve;
/**
* Possible string representations of the type of balance transaction.
* @link https://stripe.com/docs/api/balance/balance_transaction#balance_transaction_object-type
*/
const TYPE_ADJUSTMENT = 'adjustment';
const TYPE_ADVANCE = 'advance';
const TYPE_ADVANCE_FUNDING = 'advance_funding';
const TYPE_APPLICATION_FEE = 'application_fee';
const TYPE_APPLICATION_FEE_REFUND = 'application_fee_refund';
const TYPE_CHARGE = 'charge';
const TYPE_CONNECT_COLLECTION_TRANSFER = 'connect_collection_transfer';
const TYPE_ISSUING_AUTHORIZATION_HOLD = 'issuing_authorization_hold';
const TYPE_ISSUING_AUTHORIZATION_RELEASE = 'issuing_authorization_release';
const TYPE_ISSUING_TRANSACTION = 'issuing_transaction';
const TYPE_PAYMENT = 'payment';
const TYPE_PAYMENT_FAILURE_REFUND = 'payment_failure_refund';
const TYPE_PAYMENT_REFUND = 'payment_refund';
const TYPE_PAYOUT = 'payout';
const TYPE_PAYOUT_CANCEL = 'payout_cancel';
const TYPE_PAYOUT_FAILURE = 'payout_failure';
const TYPE_REFUND = 'refund';
const TYPE_REFUND_FAILURE = 'refund_failure';
const TYPE_RESERVE_TRANSACTION = 'reserve_transaction';
const TYPE_RESERVED_FUNDS = 'reserved_funds';
const TYPE_STRIPE_FEE = 'stripe_fee';
const TYPE_STRIPE_FX_FEE = 'stripe_fx_fee';
const TYPE_TAX_FEE = 'tax_fee';
const TYPE_TOPUP = 'topup';
const TYPE_TOPUP_REVERSAL = 'topup_reversal';
const TYPE_TRANSFER = 'transfer';
const TYPE_TRANSFER_CANCEL = 'transfer_cancel';
const TYPE_TRANSFER_FAILURE = 'transfer_failure';
const TYPE_TRANSFER_REFUND = 'transfer_refund';
/**
* @return string The class URL for this resource. It needs to be special
* cased because it doesn't fit into the standard resource pattern.
......
......@@ -31,6 +31,16 @@ class BankAccount extends ApiResource
use ApiOperations\Delete;
use ApiOperations\Update;
/**
* Possible string representations of the bank verification status.
* @link https://stripe.com/docs/api/external_account_bank_accounts/object#account_bank_account_object-status
*/
const STATUS_NEW = 'new';
const STATUS_VALIDATED = 'validated';
const STATUS_VERIFIED = 'verified';
const STATUS_VERIFICATION_FAILED = 'verification_failed';
const STATUS_ERRORED = 'errored';
/**
* @return string The instance URL for this resource. It needs to be special
* cased because it doesn't fit into the standard resource pattern.
......
<?php
namespace Stripe;
/**
* Class Capability
*
* @package Stripe
*
* @property string $id
* @property string $object
* @property string $account
* @property bool $requested
* @property int $requested_at
* @property mixed $requirements
* @property string $status
*/
class Capability extends ApiResource
{
const OBJECT_NAME = "capability";
use ApiOperations\Update;
/**
* Possible string representations of a capability's status.
* @link https://stripe.com/docs/api/capabilities/object#capability_object-status
*/
const STATUS_ACTIVE = 'active';
const STATUS_INACTIVE = 'inactive';
const STATUS_PENDING = 'pending';
const STATUS_UNREQUESTED = 'unrequested';