@clawpify/skills 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +73 -0
- package/clawpify/SKILL.md +134 -0
- package/clawpify/references/blogs.md +385 -0
- package/clawpify/references/bulk-operations.md +386 -0
- package/clawpify/references/collections.md +71 -0
- package/clawpify/references/customers.md +141 -0
- package/clawpify/references/discounts.md +431 -0
- package/clawpify/references/draft-orders.md +495 -0
- package/clawpify/references/files.md +355 -0
- package/clawpify/references/fulfillments.md +437 -0
- package/clawpify/references/gift-cards.md +453 -0
- package/clawpify/references/inventory.md +107 -0
- package/clawpify/references/locations.md +349 -0
- package/clawpify/references/marketing.md +352 -0
- package/clawpify/references/markets.md +346 -0
- package/clawpify/references/menus.md +313 -0
- package/clawpify/references/metafields.md +461 -0
- package/clawpify/references/orders.md +164 -0
- package/clawpify/references/pages.md +308 -0
- package/clawpify/references/products.md +277 -0
- package/clawpify/references/refunds.md +401 -0
- package/clawpify/references/segments.md +319 -0
- package/clawpify/references/shipping.md +406 -0
- package/clawpify/references/shop.md +307 -0
- package/clawpify/references/subscriptions.md +429 -0
- package/clawpify/references/translations.md +270 -0
- package/clawpify/references/webhooks.md +400 -0
- package/dist/agent.d.ts +18 -0
- package/dist/agent.d.ts.map +1 -0
- package/dist/agent.js +100 -0
- package/dist/auth.d.ts +34 -0
- package/dist/auth.d.ts.map +1 -0
- package/dist/auth.js +58 -0
- package/dist/index.d.ts +41 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +22 -0
- package/dist/mcp-server.d.ts +3 -0
- package/dist/mcp-server.d.ts.map +1 -0
- package/dist/mcp-server.js +236 -0
- package/dist/shopify.d.ts +29 -0
- package/dist/shopify.d.ts.map +1 -0
- package/dist/shopify.js +41 -0
- package/dist/skills.d.ts +8 -0
- package/dist/skills.d.ts.map +1 -0
- package/dist/skills.js +36 -0
- package/package.json +100 -0
- package/src/agent.ts +133 -0
- package/src/auth.ts +109 -0
- package/src/index.ts +55 -0
- package/src/mcp-server.ts +190 -0
- package/src/shopify.ts +63 -0
- package/src/skills.ts +42 -0
|
@@ -0,0 +1,453 @@
|
|
|
1
|
+
# Shopify Gift Cards
|
|
2
|
+
|
|
3
|
+
Create and manage gift cards via the GraphQL Admin API.
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
Gift cards are prepaid store credit that customers can use for purchases. They can be created by merchants or purchased by customers.
|
|
8
|
+
|
|
9
|
+
## List Gift Cards
|
|
10
|
+
|
|
11
|
+
```graphql
|
|
12
|
+
query ListGiftCards($first: Int!, $after: String, $query: String) {
|
|
13
|
+
giftCards(first: $first, after: $after, query: $query, sortKey: CREATED_AT, reverse: true) {
|
|
14
|
+
pageInfo {
|
|
15
|
+
hasNextPage
|
|
16
|
+
endCursor
|
|
17
|
+
}
|
|
18
|
+
nodes {
|
|
19
|
+
id
|
|
20
|
+
lastCharacters
|
|
21
|
+
initialValue {
|
|
22
|
+
amount
|
|
23
|
+
currencyCode
|
|
24
|
+
}
|
|
25
|
+
balance {
|
|
26
|
+
amount
|
|
27
|
+
currencyCode
|
|
28
|
+
}
|
|
29
|
+
enabled
|
|
30
|
+
expiresOn
|
|
31
|
+
createdAt
|
|
32
|
+
customer {
|
|
33
|
+
displayName
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
```
|
|
39
|
+
Variables: `{ "first": 20 }`
|
|
40
|
+
|
|
41
|
+
## Get Gift Card
|
|
42
|
+
|
|
43
|
+
```graphql
|
|
44
|
+
query GetGiftCard($id: ID!) {
|
|
45
|
+
giftCard(id: $id) {
|
|
46
|
+
id
|
|
47
|
+
lastCharacters
|
|
48
|
+
maskedCode
|
|
49
|
+
initialValue {
|
|
50
|
+
amount
|
|
51
|
+
currencyCode
|
|
52
|
+
}
|
|
53
|
+
balance {
|
|
54
|
+
amount
|
|
55
|
+
currencyCode
|
|
56
|
+
}
|
|
57
|
+
enabled
|
|
58
|
+
expiresOn
|
|
59
|
+
createdAt
|
|
60
|
+
disabledAt
|
|
61
|
+
note
|
|
62
|
+
customer {
|
|
63
|
+
id
|
|
64
|
+
displayName
|
|
65
|
+
defaultEmailAddress {
|
|
66
|
+
emailAddress
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
order {
|
|
70
|
+
id
|
|
71
|
+
name
|
|
72
|
+
}
|
|
73
|
+
transactions(first: 20) {
|
|
74
|
+
nodes {
|
|
75
|
+
id
|
|
76
|
+
amount {
|
|
77
|
+
amount
|
|
78
|
+
currencyCode
|
|
79
|
+
}
|
|
80
|
+
processedAt
|
|
81
|
+
note
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
```
|
|
87
|
+
Variables: `{ "id": "gid://shopify/GiftCard/123" }`
|
|
88
|
+
|
|
89
|
+
## Get Gift Cards Count
|
|
90
|
+
|
|
91
|
+
```graphql
|
|
92
|
+
query GetGiftCardsCount($query: String) {
|
|
93
|
+
giftCardsCount(query: $query) {
|
|
94
|
+
count
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
```
|
|
98
|
+
Variables: `{ "query": "enabled:true" }`
|
|
99
|
+
|
|
100
|
+
## Create Gift Card
|
|
101
|
+
|
|
102
|
+
```graphql
|
|
103
|
+
mutation CreateGiftCard($input: GiftCardCreateInput!) {
|
|
104
|
+
giftCardCreate(input: $input) {
|
|
105
|
+
giftCard {
|
|
106
|
+
id
|
|
107
|
+
lastCharacters
|
|
108
|
+
initialValue {
|
|
109
|
+
amount
|
|
110
|
+
}
|
|
111
|
+
balance {
|
|
112
|
+
amount
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
giftCardCode
|
|
116
|
+
userErrors {
|
|
117
|
+
field
|
|
118
|
+
message
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
```
|
|
123
|
+
Variables:
|
|
124
|
+
```json
|
|
125
|
+
{
|
|
126
|
+
"input": {
|
|
127
|
+
"initialValue": "50.00",
|
|
128
|
+
"customerId": "gid://shopify/Customer/123",
|
|
129
|
+
"note": "Birthday gift card"
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
## Create Gift Card with Custom Code
|
|
135
|
+
|
|
136
|
+
```graphql
|
|
137
|
+
mutation CreateGiftCardWithCode($input: GiftCardCreateInput!) {
|
|
138
|
+
giftCardCreate(input: $input) {
|
|
139
|
+
giftCard {
|
|
140
|
+
id
|
|
141
|
+
lastCharacters
|
|
142
|
+
}
|
|
143
|
+
giftCardCode
|
|
144
|
+
userErrors {
|
|
145
|
+
field
|
|
146
|
+
message
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
```
|
|
151
|
+
Variables:
|
|
152
|
+
```json
|
|
153
|
+
{
|
|
154
|
+
"input": {
|
|
155
|
+
"initialValue": "100.00",
|
|
156
|
+
"code": "HAPPY2025GIFT",
|
|
157
|
+
"note": "Promotional gift card"
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
## Create Gift Card with Expiration
|
|
163
|
+
|
|
164
|
+
```graphql
|
|
165
|
+
mutation CreateExpiringGiftCard($input: GiftCardCreateInput!) {
|
|
166
|
+
giftCardCreate(input: $input) {
|
|
167
|
+
giftCard {
|
|
168
|
+
id
|
|
169
|
+
expiresOn
|
|
170
|
+
}
|
|
171
|
+
giftCardCode
|
|
172
|
+
userErrors {
|
|
173
|
+
field
|
|
174
|
+
message
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
```
|
|
179
|
+
Variables:
|
|
180
|
+
```json
|
|
181
|
+
{
|
|
182
|
+
"input": {
|
|
183
|
+
"initialValue": "25.00",
|
|
184
|
+
"expiresOn": "2025-12-31",
|
|
185
|
+
"note": "Holiday promotional card"
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
## Create Gift Card with Recipient
|
|
191
|
+
|
|
192
|
+
```graphql
|
|
193
|
+
mutation CreateGiftCardForRecipient($input: GiftCardCreateInput!) {
|
|
194
|
+
giftCardCreate(input: $input) {
|
|
195
|
+
giftCard {
|
|
196
|
+
id
|
|
197
|
+
}
|
|
198
|
+
giftCardCode
|
|
199
|
+
userErrors {
|
|
200
|
+
field
|
|
201
|
+
message
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
```
|
|
206
|
+
Variables:
|
|
207
|
+
```json
|
|
208
|
+
{
|
|
209
|
+
"input": {
|
|
210
|
+
"initialValue": "75.00",
|
|
211
|
+
"recipientAttributes": {
|
|
212
|
+
"email": "recipient@example.com",
|
|
213
|
+
"message": "Happy Birthday! Enjoy shopping!",
|
|
214
|
+
"sendNotificationAt": "2025-03-15T09:00:00Z"
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
## Update Gift Card
|
|
221
|
+
|
|
222
|
+
```graphql
|
|
223
|
+
mutation UpdateGiftCard($id: ID!, $input: GiftCardUpdateInput!) {
|
|
224
|
+
giftCardUpdate(id: $id, input: $input) {
|
|
225
|
+
giftCard {
|
|
226
|
+
id
|
|
227
|
+
note
|
|
228
|
+
expiresOn
|
|
229
|
+
}
|
|
230
|
+
userErrors {
|
|
231
|
+
field
|
|
232
|
+
message
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
```
|
|
237
|
+
Variables:
|
|
238
|
+
```json
|
|
239
|
+
{
|
|
240
|
+
"id": "gid://shopify/GiftCard/123",
|
|
241
|
+
"input": {
|
|
242
|
+
"note": "Updated note for tracking",
|
|
243
|
+
"expiresOn": "2026-06-30"
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
## Credit Gift Card (Add Balance)
|
|
249
|
+
|
|
250
|
+
> REQUIRES PERMISSION: Adding balance to a gift card affects customer funds and creates a transaction record. Always ask the user for explicit confirmation before executing this operation.
|
|
251
|
+
|
|
252
|
+
```graphql
|
|
253
|
+
mutation CreditGiftCard($id: ID!, $creditInput: GiftCardCreditInput!) {
|
|
254
|
+
giftCardCredit(id: $id, creditInput: $creditInput) {
|
|
255
|
+
giftCard {
|
|
256
|
+
id
|
|
257
|
+
balance {
|
|
258
|
+
amount
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
giftCardCreditTransaction {
|
|
262
|
+
id
|
|
263
|
+
amount {
|
|
264
|
+
amount
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
userErrors {
|
|
268
|
+
field
|
|
269
|
+
message
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
```
|
|
274
|
+
Variables:
|
|
275
|
+
```json
|
|
276
|
+
{
|
|
277
|
+
"id": "gid://shopify/GiftCard/123",
|
|
278
|
+
"creditInput": {
|
|
279
|
+
"creditAmount": {
|
|
280
|
+
"amount": "25.00",
|
|
281
|
+
"currencyCode": "USD"
|
|
282
|
+
},
|
|
283
|
+
"note": "Bonus credit for loyalty"
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
## Debit Gift Card (Remove Balance)
|
|
289
|
+
|
|
290
|
+
> REQUIRES PERMISSION: Removing balance from a gift card affects customer funds and cannot be easily reversed. Always ask the user for explicit confirmation before executing this operation.
|
|
291
|
+
|
|
292
|
+
```graphql
|
|
293
|
+
mutation DebitGiftCard($id: ID!, $debitInput: GiftCardDebitInput!) {
|
|
294
|
+
giftCardDebit(id: $id, debitInput: $debitInput) {
|
|
295
|
+
giftCard {
|
|
296
|
+
id
|
|
297
|
+
balance {
|
|
298
|
+
amount
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
giftCardDebitTransaction {
|
|
302
|
+
id
|
|
303
|
+
amount {
|
|
304
|
+
amount
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
userErrors {
|
|
308
|
+
field
|
|
309
|
+
message
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
```
|
|
314
|
+
Variables:
|
|
315
|
+
```json
|
|
316
|
+
{
|
|
317
|
+
"id": "gid://shopify/GiftCard/123",
|
|
318
|
+
"debitInput": {
|
|
319
|
+
"debitAmount": {
|
|
320
|
+
"amount": "10.00",
|
|
321
|
+
"currencyCode": "USD"
|
|
322
|
+
},
|
|
323
|
+
"note": "Balance adjustment"
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
## Deactivate Gift Card
|
|
329
|
+
|
|
330
|
+
> REQUIRES PERMISSION: Deactivating a gift card is PERMANENT and IRREVERSIBLE. The gift card cannot be reactivated and any remaining balance will be lost. Always ask the user for explicit confirmation and show the current balance before executing this operation.
|
|
331
|
+
|
|
332
|
+
Permanently disable a gift card:
|
|
333
|
+
|
|
334
|
+
```graphql
|
|
335
|
+
mutation DeactivateGiftCard($id: ID!) {
|
|
336
|
+
giftCardDeactivate(id: $id) {
|
|
337
|
+
giftCard {
|
|
338
|
+
id
|
|
339
|
+
enabled
|
|
340
|
+
disabledAt
|
|
341
|
+
}
|
|
342
|
+
userErrors {
|
|
343
|
+
field
|
|
344
|
+
message
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
```
|
|
349
|
+
|
|
350
|
+
Note: Deactivation is permanent and cannot be reversed.
|
|
351
|
+
|
|
352
|
+
## Send Customer Notification
|
|
353
|
+
|
|
354
|
+
```graphql
|
|
355
|
+
mutation SendGiftCardNotification($id: ID!) {
|
|
356
|
+
giftCardSendNotificationToCustomer(id: $id) {
|
|
357
|
+
giftCard {
|
|
358
|
+
id
|
|
359
|
+
}
|
|
360
|
+
userErrors {
|
|
361
|
+
field
|
|
362
|
+
message
|
|
363
|
+
}
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
```
|
|
367
|
+
|
|
368
|
+
## Send Recipient Notification
|
|
369
|
+
|
|
370
|
+
```graphql
|
|
371
|
+
mutation SendRecipientNotification($id: ID!) {
|
|
372
|
+
giftCardSendNotificationToRecipient(id: $id) {
|
|
373
|
+
giftCard {
|
|
374
|
+
id
|
|
375
|
+
}
|
|
376
|
+
userErrors {
|
|
377
|
+
field
|
|
378
|
+
message
|
|
379
|
+
}
|
|
380
|
+
}
|
|
381
|
+
}
|
|
382
|
+
```
|
|
383
|
+
|
|
384
|
+
## Search Gift Cards
|
|
385
|
+
|
|
386
|
+
```graphql
|
|
387
|
+
query SearchGiftCards($query: String!) {
|
|
388
|
+
giftCards(first: 10, query: $query) {
|
|
389
|
+
nodes {
|
|
390
|
+
id
|
|
391
|
+
lastCharacters
|
|
392
|
+
balance {
|
|
393
|
+
amount
|
|
394
|
+
}
|
|
395
|
+
enabled
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
```
|
|
400
|
+
Variables: `{ "query": "last_characters:ABC1 AND enabled:true" }`
|
|
401
|
+
|
|
402
|
+
## Search Query Filters
|
|
403
|
+
|
|
404
|
+
| Filter | Example | Description |
|
|
405
|
+
|--------|---------|-------------|
|
|
406
|
+
| `last_characters` | `last_characters:ABC1` | Last 4 characters of code |
|
|
407
|
+
| `enabled` | `enabled:true` | Active/inactive status |
|
|
408
|
+
| `balance` | `balance:>0` | Balance amount |
|
|
409
|
+
| `initial_value` | `initial_value:>=50` | Initial value |
|
|
410
|
+
| `created_at` | `created_at:>2024-01-01` | Creation date |
|
|
411
|
+
|
|
412
|
+
## Gift Card Configuration
|
|
413
|
+
|
|
414
|
+
```graphql
|
|
415
|
+
query GetGiftCardConfiguration {
|
|
416
|
+
giftCardConfiguration {
|
|
417
|
+
expiresAfter {
|
|
418
|
+
months
|
|
419
|
+
years
|
|
420
|
+
}
|
|
421
|
+
isEnabled
|
|
422
|
+
}
|
|
423
|
+
}
|
|
424
|
+
```
|
|
425
|
+
|
|
426
|
+
## API Scopes Required
|
|
427
|
+
|
|
428
|
+
- `read_gift_cards` - Read gift cards
|
|
429
|
+
- `write_gift_cards` - Create, update, deactivate gift cards
|
|
430
|
+
|
|
431
|
+
## Notes
|
|
432
|
+
|
|
433
|
+
- Gift card codes are only shown once at creation
|
|
434
|
+
- `lastCharacters` shows last 4 digits for identification
|
|
435
|
+
- Deactivation is permanent
|
|
436
|
+
- Gift cards can be assigned to customers or remain unassigned
|
|
437
|
+
- Recipient notifications can be scheduled for future delivery
|
|
438
|
+
- Balance adjustments create transaction history
|
|
439
|
+
|
|
440
|
+
## Dangerous Operations in This Skill
|
|
441
|
+
|
|
442
|
+
The following operations require explicit user permission before execution:
|
|
443
|
+
|
|
444
|
+
| Operation | Impact | Reversible |
|
|
445
|
+
|-----------|--------|------------|
|
|
446
|
+
| `giftCardDeactivate` | Permanently disables gift card, making balance unrecoverable | No - IRREVERSIBLE |
|
|
447
|
+
| `giftCardCredit` | Adds balance to gift card (affects customer funds) | Partial (requires debit) |
|
|
448
|
+
| `giftCardDebit` | Removes balance from gift card (affects customer funds) | Partial (requires credit) |
|
|
449
|
+
|
|
450
|
+
Permission Protocol: Before executing any of these operations:
|
|
451
|
+
1. Show the gift card ID, masked code, and current balance
|
|
452
|
+
2. Describe the impact (especially for deactivation - warn about permanent loss)
|
|
453
|
+
3. Wait for explicit user confirmation with "yes", "confirm", or "proceed"
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
# Shopify Inventory & Locations
|
|
2
|
+
|
|
3
|
+
## Get Inventory Levels
|
|
4
|
+
|
|
5
|
+
```graphql
|
|
6
|
+
query GetInventoryLevels($inventoryItemId: ID!) {
|
|
7
|
+
inventoryItem(id: $inventoryItemId) {
|
|
8
|
+
id
|
|
9
|
+
sku
|
|
10
|
+
inventoryLevels(first: 10) {
|
|
11
|
+
nodes {
|
|
12
|
+
id
|
|
13
|
+
quantities(names: ["available", "incoming", "committed", "on_hand"]) {
|
|
14
|
+
name
|
|
15
|
+
quantity
|
|
16
|
+
}
|
|
17
|
+
location {
|
|
18
|
+
id
|
|
19
|
+
name
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
```
|
|
26
|
+
Variables: `{ "inventoryItemId": "gid://shopify/InventoryItem/123" }`
|
|
27
|
+
|
|
28
|
+
Quantity names:
|
|
29
|
+
- `available` - quantity available for sale
|
|
30
|
+
- `incoming` - quantity being transferred in
|
|
31
|
+
- `committed` - quantity committed to orders
|
|
32
|
+
- `on_hand` - total physical quantity
|
|
33
|
+
|
|
34
|
+
## List Locations
|
|
35
|
+
|
|
36
|
+
```graphql
|
|
37
|
+
query ListLocations {
|
|
38
|
+
locations(first: 10) {
|
|
39
|
+
nodes {
|
|
40
|
+
id
|
|
41
|
+
name
|
|
42
|
+
address {
|
|
43
|
+
address1
|
|
44
|
+
city
|
|
45
|
+
province
|
|
46
|
+
country
|
|
47
|
+
}
|
|
48
|
+
isActive
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
## Adjust Inventory
|
|
55
|
+
|
|
56
|
+
> REQUIRES PERMISSION: Adjusting inventory levels directly affects product availability and stock counts. This can result in overselling or incorrect stock levels. Always ask the user for explicit confirmation, show the current quantity, the delta, and the final quantity before executing this operation.
|
|
57
|
+
|
|
58
|
+
```graphql
|
|
59
|
+
mutation AdjustInventory($input: InventoryAdjustQuantitiesInput!) {
|
|
60
|
+
inventoryAdjustQuantities(input: $input) {
|
|
61
|
+
inventoryAdjustmentGroup {
|
|
62
|
+
reason
|
|
63
|
+
changes {
|
|
64
|
+
name
|
|
65
|
+
delta
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
userErrors {
|
|
69
|
+
field
|
|
70
|
+
message
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
```
|
|
75
|
+
Variables:
|
|
76
|
+
```json
|
|
77
|
+
{
|
|
78
|
+
"input": {
|
|
79
|
+
"reason": "correction",
|
|
80
|
+
"name": "available",
|
|
81
|
+
"changes": [
|
|
82
|
+
{
|
|
83
|
+
"inventoryItemId": "gid://shopify/InventoryItem/123",
|
|
84
|
+
"locationId": "gid://shopify/Location/456",
|
|
85
|
+
"delta": 10
|
|
86
|
+
}
|
|
87
|
+
]
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## Dangerous Operations in This Skill
|
|
93
|
+
|
|
94
|
+
The following operations require explicit user permission before execution:
|
|
95
|
+
|
|
96
|
+
| Operation | Impact | Reversible |
|
|
97
|
+
|-----------|--------|------------|
|
|
98
|
+
| `inventoryAdjustQuantities` | Directly modifies stock levels, affecting product availability | Partial - Can adjust again, but changes are immediate |
|
|
99
|
+
|
|
100
|
+
Permission Protocol: Before executing `inventoryAdjustQuantities`:
|
|
101
|
+
1. Show the inventory item ID and SKU
|
|
102
|
+
2. Display the current quantity at the location
|
|
103
|
+
3. Show the delta (change amount: positive or negative)
|
|
104
|
+
4. Calculate and show the resulting quantity
|
|
105
|
+
5. Indicate the reason for the adjustment
|
|
106
|
+
6. Wait for explicit user confirmation with "yes", "confirm", or "proceed"
|
|
107
|
+
7. Warn that changes are immediate and affect customer-facing availability
|