Closed sumathi3399 closed 1 year ago
jira ticket:- https://jira.newfold.com/browse/PRESS4-329
offline payments api is not working after updating the woocommerce version. earlier we were using the /wc-admin/options api(which is failing one)
/wc-admin/options
now we are using the existing api which is wp/v2/settings api. here need to add the options for getting/updating the property values.
wp/v2/settings
'woocommerce_bacs_settings' 'woocommerce_cod_settings' 'woocommerce_cheque_settings'
With these three options, we can get the response of offline payments status (whether it is enabled or not)
And also we can send the post request for the same endpoint for updating the options
Request Body (POST):
{ "woocommerce_cheque_settings":{ "gateway_id":"cheque", "enabled": "yes", "action":"woocommerce_toggle_gateway_enabled", "security":"ccca7ecd89" } }
Response (GET):
After getting enabled the offline payments in the bluehost ecommerce, All the three options will be enabled in the woocommerce->settings->payments. cod,cheque,bank transfer:
cod,cheque,bank transfer
jira ticket:- https://jira.newfold.com/browse/PRESS4-329
problem:-
offline payments api is not working after updating the woocommerce version. earlier we were using the
/wc-admin/options
api(which is failing one)issue:-
now we are using the existing api which is
wp/v2/settings
api. here need to add the options for getting/updating the property values.With these three options, we can get the response of offline payments status (whether it is enabled or not)
And also we can send the post request for the same endpoint for updating the options
Request Body (POST):
Response (GET):
After getting enabled the offline payments in the bluehost ecommerce, All the three options will be enabled in the woocommerce->settings->payments.
cod,cheque,bank transfer
: