pt Describes the customer's tax exemption status. One of none, exempt, or reverse. When set to reverse, invoice and receipt PDFs include the text "Reverse charge". * @property \Stripe\Collection $tax_ids The customer's tax IDs. */ class Customer extends ApiResource { const OBJECT_NAME = 'customer'; use ApiOperations\All; use ApiOperations\Create; use ApiOperations\Delete; use ApiOperations\NestedResource; use ApiOperations\Retrieve; use ApiOperations\Update; const TAX_EXEMPT_EXEMPT = 'exempt'; const TAX_EXEMPT_NONE = 'none'; const TAX_EXEMPT_REVERSE = 'reverse'; public static function getSavedNestedResources() { static $savedNestedResources = null; if (null === $savedNestedResources) { $savedNestedResources = new Util\Set([ 'source', ]); } return $savedNestedResources; } /** * @param null|array $params * @param null|array|string $opts * * @return \Stripe\Customer the updated customer */ public function deleteDiscount($params = null, $opts = null) { $url = $this->instanceUrl() . '/discount'; list($response, $opts) = $this->_request('delete', $url, $params, $opts); $this->refreshFrom(['discount' => null], $opts, true); } /** * @param null|array $params * @param null|array|string $opts * @param mixed $id * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\Collection list of PaymentMethods */ public static function allPaymentMethods($id, $params = null, $opts = null) { $url = static::resourceUrl($id) . '/payment_methods'; list($response, $opts) = static::_staticRequest('get', $url, $params, $opts); $obj = \Stripe\Util\Util::convertToStripeObject($response->json, $opts); $obj->setLastResponse($response); return $obj; } const PATH_BALANCE_TRANSACTIONS = '/balance_transactions'; /** * @param string $id the ID of the customer on which to retrieve the customer balance transactions * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\Collection the list of customer balance transactions */ public static function allBalanceTransactions($id, $params = null, $opts = null) { return self::_allNestedResources($id, static::PATH_BALANCE_TRANSACTIONS, $params, $opts); } /** * @param string $id the ID of the customer on which to create the customer balance transaction * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\CustomerBalanceTransaction */ public static function createBalanceTransaction($id, $params = null, $opts = null) { return self::_createNestedResource($id, static::PATH_BALANCE_TRANSACTIONS, $params, $opts); } /** * @param string $id the ID of the customer to which the customer balance transaction belongs * @param string $balanceTransactionId the ID of the customer balance transaction to retrieve * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\CustomerBalanceTransaction */ public static function retrieveBalanceTransaction($id, $balanceTransactionId, $params = null, $opts = null) { return self::_retrieveNestedResource($id, static::PATH_BALANCE_TRANSACTIONS, $balanceTransactionId, $params, $opts); } /** * @param string $id the ID of the customer to which the customer balance transaction belongs * @param string $balanceTransactionId the ID of the customer balance transaction to update * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\CustomerBalanceTransaction */ public static function updateBalanceTransaction($id, $balanceTransactionId, $params = null, $opts = null) { return self::_updateNestedResource($id, static::PATH_BALANCE_TRANSACTIONS, $balanceTransactionId, $params, $opts); } const PATH_SOURCES = '/sources'; /** * @param string $id the ID of the customer on which to retrieve the payment sources * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\Collection the list of payment sources (AlipayAccount, BankAccount, BitcoinReceiver, Card or Source) */ public static function allSources($id, $params = null, $opts = null) { return self::_allNestedResources($id, static::PATH_SOURCES, $params, $opts); } /** * @param string $id the ID of the customer on which to create the payment source * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source */ public static function createSource($id, $params = null, $opts = null) { return self::_createNestedResource($id, static::PATH_SOURCES, $params, $opts); } /** * @param string $id the ID of the customer to which the payment source belongs * @param string $sourceId the ID of the payment source to delete * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source */ public static function deleteSource($id, $sourceId, $params = null, $opts = null) { return self::_deleteNestedResource($id, static::PATH_SOURCES, $sourceId, $params, $opts); } /** * @param string $id the ID of the customer to which the payment source belongs * @param string $sourceId the ID of the payment source to retrieve * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source */ public static function retrieveSource($id, $sourceId, $params = null, $opts = null) { return self::_retrieveNestedResource($id, static::PATH_SOURCES, $sourceId, $params, $opts); } /** * @param string $id the ID of the customer to which the payment source belongs * @param string $sourceId the ID of the payment source to update * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source */ public static function updateSource($id, $sourceId, $params = null, $opts = null) { return self::_updateNestedResource($id, static::PATH_SOURCES, $sourceId, $params, $opts); } const PATH_TAX_IDS = '/tax_ids'; /** * @param string $id the ID of the customer on which to retrieve the tax ids * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\Collection the list of tax ids */ public static function allTaxIds($id, $params = null, $opts = null) { return self::_allNestedResources($id, static::PATH_TAX_IDS, $params, $opts); } /** * @param string $id the ID of the customer on which to create the tax id * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\TaxId */ public static function createTaxId($id, $params = null, $opts = null) { return self::_createNestedResource($id, static::PATH_TAX_IDS, $params, $opts); } /** * @param string $id the ID of the customer to which the tax id belongs * @param string $taxIdId the ID of the tax id to delete * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\TaxId */ public static function deleteTaxId($id, $taxIdId, $params = null, $opts = null) { return self::_deleteNestedResource($id, static::PATH_TAX_IDS, $taxIdId, $params, $opts); } /** * @param string $id the ID of the customer to which the tax id belongs * @param string $taxIdId the ID of the tax id to retrieve * @param null|array $params * @param null|array|string $opts * * @throws \Stripe\Exception\ApiErrorException if the request fails * * @return \Stripe\TaxId */ public static function retrieveTaxId($id, $taxIdId, $params = null, $opts = null) { return self::_retrieveNestedResource($id, static::PATH_TAX_IDS, $taxIdId, $params, $opts); } }
Warning: Cannot modify header information - headers already sent by (output started at /htdocs/wp-content/plugins/checkout-plugins-stripe-woo/lib/stripe-php/lib/Customer.php:1) in /htdocs/wp-includes/pluggable.php on line 1435

Warning: Cannot modify header information - headers already sent by (output started at /htdocs/wp-content/plugins/checkout-plugins-stripe-woo/lib/stripe-php/lib/Customer.php:1) in /htdocs/wp-includes/pluggable.php on line 1438