Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save somewherewarm-snippets/43aa7df3a39aed9abba6312a8f7428f6 to your computer and use it in GitHub Desktop.
Save somewherewarm-snippets/43aa7df3a39aed9abba6312a8f7428f6 to your computer and use it in GitHub Desktop.
curl -X POST 'https://example.com/wp-json/wc/v3/gift-cards/batch' \
-u consumer_key:consumer_secret \
-H 'Content-Type: application/json' \
--data-raw '{
"create": [
{
"recipient": "recipient@somewherewarm.local",
"sender": "sender@somewherewarm.local",
"balance": 100
},
{
"recipient": "recipient@somewherewarm.local",
"sender": "sender@somewherewarm.local",
"balance": 200
}
],
"update": [
{
"id": 177,
"meta_data": [
{
"key": "sample key 1",
"value": "this is the new updated value"
}
]
},
{
"id": 176,
"message": "176 message"
}
],
"delete": [
15,
16,
17
]
}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment