Automattic\WooCommerce\StoreApi\Routes\V1\Agentic
CheckoutSessionsComplete::get_complete_params
Get the parameters for completing a checkout session.
Method of the class: CheckoutSessionsComplete{}
No Hooks.
Returns
Array. Parameters array.
Usage
// protected - for code of main (parent) or child class $result = $this->get_complete_params();
CheckoutSessionsComplete::get_complete_params() CheckoutSessionsComplete::get complete params code WC 10.7.0
protected function get_complete_params() {
$shared_params = AgenticCheckoutUtils::get_shared_params();
return [
'buyer' => $shared_params['buyer'],
'payment_data' => [
'description' => __( 'Payment data including token and provider.', 'woocommerce' ),
'type' => 'object',
'properties' => [
'token' => [
'description' => __( 'Payment token from the payment provider.', 'woocommerce' ),
'type' => 'string',
],
'provider' => [
'description' => __( 'Payment provider identifier.', 'woocommerce' ),
'type' => 'string',
'enum' => [ 'stripe' ],
],
'billing_address' => $shared_params['fulfillment_address'],
],
'required' => [ 'token', 'provider' ],
],
];
}