我想使用Fiddler将发布请求发送到API,以创建新客户。我的问题是我无法弄清楚如何在我的帖子请求中使用consumer_key和consumer_secret。我需要在Fiddler UI上以正确的格式放置consumer_key和consumer_secret来创建新客户方面的帮助。我还在下面的JSON代码中添加了新客户的ID。请建议是否为这样的新客户放置一个ID是否正确:
API链接: https://www.example.com/wp-json/wc/v2/
方法: POST
consumer_key: 123456789
consumer_secret: 123456789
我要在发布请求中传递的JSON代码在这里:
'{
"id": "323",
"email": "john.doe@example.com",
"first_name": "John",
"last_name": "Doe",
"username": "john.doe",
"billing": {
"first_name": "John",
"last_name": "Doe",
"company": "",
"address_1": "969 Market",
"address_2": "",
"city": "San Francisco",
"state": "CA",
"postcode": "94103",
"country": "US",
"email": "john.doe@example.com",
"phone": "(555) 555-5555"
},
"shipping": {
"first_name": "John",
"last_name": "Doe",
"company": "",
"address_1": "969 Market",
"address_2": "",
"city": "San Francisco",
"state": "CA",
"postcode": "94103",
"country": "US"
}
}'
我需要一个可以为我提供正确格式的人,以便在Fiddler UI中正确填写consumer_key和consumer_secret值。我对这种类型的操作还很陌生,将感谢您的帮助。