我在Swagger Resp Api中有一个Curl,//To display the ACF custom field 'shpng' below the product title on cart page
function lh_cart_item_sub_title( $cart_item ) {
$shpng = get_field( 'shpng', $cart_item['product_id'] );
echo "<div class='small custom-cart-shipping-date'>My Custom Shipping Date: $shpng.</div>";
}
add_action( 'woocommerce_after_cart_item_name', 'lh_cart_item_sub_title', 10, 1 );
如何使用HttpClient()请求标头从c#代码传递curl -X POST "https://petstore.swagger.io/v2/pet/11" -H "accept: application/xml" -H "Content-Type: application/x-www-form-urlencoded" -H "Client-Id: example.demo.com" -d "name=James&status=K"