Constants

SCHEME_PATH

SCHEME_PATH = 'weixin://wxpay/bizpayurl'

Scheme base path.

Properties

Methods

scheme()

scheme(string  $productId) : string

Build payment scheme for product.

Parameters

string $productId

Returns

string

configForPayment()

configForPayment(string  $prepayId, boolean  $json = true) : string|array

[WeixinJSBridge] Generate js config for payment.

WeixinJSBridge.invoke(
 'getBrandWCPayRequest',
 ...
);

Parameters

string $prepayId
boolean $json

Returns

string|array

configForJSSDKPayment()

configForJSSDKPayment(string  $prepayId) : array|string

[JSSDK] Generate js config for payment.

wx.chooseWXPay({...});

Parameters

string $prepayId

Returns

array|string

configForAppPayment()

configForAppPayment(string  $prepayId) : array

Generate app payment parameters.

Parameters

string $prepayId

Returns

array

configForShareAddress()

configForShareAddress(string|\Overtrue\Socialite\AccessTokenInterface  $accessToken, boolean  $json = true) : string|array

Generate js config for share user address.

Parameters

string|\Overtrue\Socialite\AccessTokenInterface $accessToken
boolean $json

Returns

string|array

__call()

__call(string  $method, array  $args) : mixed

Magic call.

Parameters

string $method
array $args

Returns

mixed