|
291 | 291 | ),
|
292 | 292 |
|
293 | 293 |
|
| 294 | + |
| 295 | + /** |
| 296 | + * createCollectionMetafield() method |
| 297 | + * |
| 298 | + * reference: https://help.shopify.com/api/reference/metafield |
| 299 | + */ |
| 300 | + "createCollectionMetafield" => array( |
| 301 | + "httpMethod" => "POST", |
| 302 | + "uri" => "/admin/collections/{id}/metafields.json", |
| 303 | + "summary" => "Create a new metafield for a collection", |
| 304 | + "responseModel" => "defaultJsonResponse", |
| 305 | + "parameters" => array( |
| 306 | + "id" => array( |
| 307 | + "type" => "number", |
| 308 | + "location" => "uri", |
| 309 | + "description" => "The ID of the Collection.", |
| 310 | + "required" => true |
| 311 | + ), |
| 312 | + "metafield" => array( |
| 313 | + "location" => "json", |
| 314 | + "parameters" => array( |
| 315 | + "namespace" => array( |
| 316 | + "type" => "string", |
| 317 | + "location" => "json", |
| 318 | + "description" => "The Namespace for the Metafield." |
| 319 | + ), |
| 320 | + "key" => array( |
| 321 | + "type" => "string", |
| 322 | + "location" => "json", |
| 323 | + "description" => "The Key for the Metafield." |
| 324 | + ), |
| 325 | + "value" => array( |
| 326 | + "type" => "string", |
| 327 | + "location" => "json", |
| 328 | + "description" => "The Value of the Metafield." |
| 329 | + ), |
| 330 | + "value_type" => array( |
| 331 | + "type" => "string", |
| 332 | + "location" => "json", |
| 333 | + "description" => "The Value Type of the Metafield." |
| 334 | + ) |
| 335 | + ) |
| 336 | + ) |
| 337 | + ) |
| 338 | + ), |
| 339 | + |
| 340 | + |
294 | 341 | /**
|
295 | 342 | * createProductMetafield() method
|
296 | 343 | *
|
|
424 | 471 | ),
|
425 | 472 |
|
426 | 473 |
|
| 474 | + |
| 475 | + /** |
| 476 | + * updateCollectionMetafield() method |
| 477 | + * |
| 478 | + * reference: https://help.shopify.com/api/reference/metafield |
| 479 | + */ |
| 480 | + "updateCollectionMetafield" => array( |
| 481 | + "httpMethod" => "PUT", |
| 482 | + "uri" => "/admin/collections/{id}/metafields/{metafield_id}.json", |
| 483 | + "summary" => "Update a Collection Metafield", |
| 484 | + "responseModel" => "defaultJsonResponse", |
| 485 | + "parameters" => array( |
| 486 | + "id" => array( |
| 487 | + "type" => "number", |
| 488 | + "location" => "uri", |
| 489 | + "description" => "The ID of the Collection.", |
| 490 | + "required" => true |
| 491 | + ), |
| 492 | + "metafield_id" => array( |
| 493 | + "type" => "number", |
| 494 | + "location" => "uri", |
| 495 | + "description" => "The ID of the Metafield.", |
| 496 | + "required" => true |
| 497 | + ), |
| 498 | + "metafield" => array( |
| 499 | + "location" => "json", |
| 500 | + "parameters" => array( |
| 501 | + "metafieldId" => array( |
| 502 | + "type" => "number", |
| 503 | + "location" => "json", |
| 504 | + "description" => "The ID for the Metafield." |
| 505 | + ), |
| 506 | + "value" => array( |
| 507 | + "type" => "string", |
| 508 | + "location" => "json", |
| 509 | + "description" => "The Value of the Metafield." |
| 510 | + ), |
| 511 | + "value_type" => array( |
| 512 | + "type" => "string", |
| 513 | + "location" => "json", |
| 514 | + "description" => "The Value Type of the Metafield." |
| 515 | + ) |
| 516 | + ) |
| 517 | + ) |
| 518 | + ) |
| 519 | + ), |
| 520 | + |
| 521 | + |
427 | 522 | /**
|
428 | 523 | * updateProductMetafield() method
|
429 | 524 | *
|
|
538 | 633 | )
|
539 | 634 | ),
|
540 | 635 |
|
| 636 | + /** |
| 637 | + * deleteCollectionMetafield() method |
| 638 | + * |
| 639 | + * reference: https://help.shopify.com/api/reference/metafield |
| 640 | + */ |
| 641 | + "deleteCollectionMetafield" => array( |
| 642 | + "httpMethod" => "DELETE", |
| 643 | + "uri" => "/admin/collections/{id}/metafields/{metafieldId}.json", |
| 644 | + "summary" => "Delete a Collection Metafield", |
| 645 | + "responseModel" => "defaultJsonResponse", |
| 646 | + "parameters" => array( |
| 647 | + "id" => array( |
| 648 | + "type" => "number", |
| 649 | + "location" => "uri", |
| 650 | + "description" => "The ID of the Product.", |
| 651 | + "required" => true |
| 652 | + ), |
| 653 | + "metafieldId" => array( |
| 654 | + "type" => "number", |
| 655 | + "location" => "uri", |
| 656 | + "description" => "The ID of the Metafield.", |
| 657 | + "required" => true |
| 658 | + ) |
| 659 | + ) |
| 660 | + ), |
541 | 661 |
|
542 | 662 | /**
|
543 | 663 | * deleteProductMetafield() method
|
|
0 commit comments