Property | Type | Description | |
---|---|---|---|
$namespace | string | Endpoint namespace. | |
$rest_base | string | Route base. |
Method | Description | |
---|---|---|
get_collection_params ( ) : array | Get any query params needed. | |
get_gateway ( WP_REST_Request $request ) : WP_REST_Response | null | Get a gateway based on the current request object. | |
get_item ( WP_REST_Request $request ) : WP_REST_Response | WP_Error | Get a single payment gateway. | |
get_item_permissions_check ( WP_REST_Request $request ) : WP_Error | boolean | Check if a given request has access to read a payment gateway. | |
get_item_schema ( ) : array | Get the payment gateway schema, conforming to JSON Schema. | |
get_items ( WP_REST_Request $request ) : WP_Error | WP_REST_Response | Get payment gateways. | |
get_items_permissions_check ( WP_REST_Request $request ) : WP_Error | boolean | Check whether a given request has permission to view payment gateways. | |
get_settings ( $gateway ) | Return settings associated with this payment gateway. | |
prepare_item_for_response ( WC_Payment_Gateway $gateway, WP_REST_Request $request ) : WP_REST_Response | Prepare a payment gateway for response. | |
register_routes ( ) |
Register the route for /payment_gateways and /payment_gateways/ |
|
update_item ( WP_REST_Request $request ) : WP_REST_Response | WP_Error | Update A Single Shipping Zone Method. | |
update_items_permissions_check ( WP_REST_Request $request ) : WP_Error | boolean | Check whether a given request has permission to edit payment gateways. |
Method | Description | |
---|---|---|
prepare_links ( WC_Payment_Gateway $gateway, WP_REST_Request $request ) : array | Prepare links for the request. |
public get_collection_params ( ) : array | ||
return | array |
public get_gateway ( WP_REST_Request $request ) : WP_REST_Response | null | ||
$request | WP_REST_Request | |
return | WP_REST_Response | null |
public get_item ( WP_REST_Request $request ) : WP_REST_Response | WP_Error | ||
$request | WP_REST_Request | |
return | WP_REST_Response | WP_Error |
public get_item_permissions_check ( WP_REST_Request $request ) : WP_Error | boolean | ||
$request | WP_REST_Request | Full details about the request. |
return | WP_Error | boolean |
public get_item_schema ( ) : array | ||
return | array |
public get_items ( WP_REST_Request $request ) : WP_Error | WP_REST_Response | ||
$request | WP_REST_Request | Full details about the request. |
return | WP_Error | WP_REST_Response |
public get_items_permissions_check ( WP_REST_Request $request ) : WP_Error | boolean | ||
$request | WP_REST_Request | Full details about the request. |
return | WP_Error | boolean |
public get_settings ( $gateway ) |
public prepare_item_for_response ( WC_Payment_Gateway $gateway, WP_REST_Request $request ) : WP_REST_Response | ||
$gateway | WC_Payment_Gateway | Payment gateway object. |
$request | WP_REST_Request | Request object. |
return | WP_REST_Response | $response Response data. |
protected prepare_links ( WC_Payment_Gateway $gateway, WP_REST_Request $request ) : array | ||
$gateway | WC_Payment_Gateway | Payment gateway object. |
$request | WP_REST_Request | Request object. |
return | array |
public register_routes ( ) |
public update_item ( WP_REST_Request $request ) : WP_REST_Response | WP_Error | ||
$request | WP_REST_Request | |
return | WP_REST_Response | WP_Error |
public update_items_permissions_check ( WP_REST_Request $request ) : WP_Error | boolean | ||
$request | WP_REST_Request | Full details about the request. |
return | WP_Error | boolean |