StripeAPI
in package

Tags
since
1.5.0

Table of Contents

API_VERSION  = '2022-11-15'
PARTNER_ID  = 'pp_partner_Fs0jSMbknaJwVC'
TRANSIENT_KEY_ACCOUNT_COUNTRY  = 'mpa_stripe_account_country'
$secretKey  : string
__construct()  : mixed
checkMinimumAmount()  : bool
Checks Stripe minimum amount value authorized per currency.
convertToSmallestUnit()  : int
createPaymentIntent()  : PaymentIntent|WP_Error
getAccountCountry()  : string
getMinimumAmount()  : float
getPaymentIntent()  : PaymentIntent|WP_Error
getPaymentMethod()  : PaymentMethod|WP_Error
registerApp()  : mixed
updatePaymentIntentDescription()  : true|WP_Error

Constants

API_VERSION

public mixed API_VERSION = '2022-11-15'
Tags
since
1.16.0

PARTNER_ID

public mixed PARTNER_ID = 'pp_partner_Fs0jSMbknaJwVC'
Tags
since
1.16.0

TRANSIENT_KEY_ACCOUNT_COUNTRY

public mixed TRANSIENT_KEY_ACCOUNT_COUNTRY = 'mpa_stripe_account_country'
Tags
since
1.16.0

Properties

$secretKey

public string $secretKey = ''
Tags
since
1.5.0

Methods

__construct()

public __construct(string $secretKey) : mixed
Parameters
$secretKey : string
Tags
since
1.5.0
Return values
mixed

checkMinimumAmount()

Checks Stripe minimum amount value authorized per currency.

public checkMinimumAmount(float $amount, string $currency) : bool
Parameters
$amount : float
$currency : string
Tags
since
1.5.0
Return values
bool

convertToSmallestUnit()

public convertToSmallestUnit(float $amount[, string $currency = null ]) : int
Parameters
$amount : float
$currency : string = null

Optional.

Tags
since
1.5.0
Return values
int

createPaymentIntent()

public createPaymentIntent(array<string|int, mixed> $requestArgs) : PaymentIntent|WP_Error
Parameters
$requestArgs : array<string|int, mixed>
Tags
since
1.14.0
Return values
PaymentIntent|WP_Error

Payment Intent or WP_Error.

getAccountCountry()

public getAccountCountry() : string
Tags
since
1.16.0
Return values
string

two-letter account country code

getMinimumAmount()

public getMinimumAmount(string $currency) : float
Parameters
$currency : string
Tags
since
1.5.0
Return values
float

getPaymentIntent()

public getPaymentIntent(string $paymentIntentId) : PaymentIntent|WP_Error
Parameters
$paymentIntentId : string
Tags
since
1.5.0
Return values
PaymentIntent|WP_Error

getPaymentMethod()

public getPaymentMethod(string $paymentMethodId) : PaymentMethod|WP_Error
Parameters
$paymentMethodId : string
Tags
since
1.14.0
Return values
PaymentMethod|WP_Error

registerApp()

public registerApp() : mixed
Tags
since
1.5.0
Return values
mixed

updatePaymentIntentDescription()

public updatePaymentIntentDescription(PaymentIntent $paymentIntent, string $description) : true|WP_Error
Parameters
$paymentIntent : PaymentIntent
$description : string
Tags
since
1.5.0
Return values
true|WP_Error

Search results