php - Is it possible to set items as available for pickup in Square API? -


i creating items using square api. in square dashboard > item library, in "online store settings" section, there "available pickup" , "available shipping". there way can have 'available pickup' checked default when create item api?

i know documentation says "you cannot manage pickup orders connect api." want has managing items, not orders.

yes. when creating item, set available_for_pickup field true in request body, so:

{   "name": "milkshake",   "visibility": "public",   "variations": [     {       "name": "small",       "pricing_type": "fixed_pricing",       "price_money": {         "currency_code": "usd",         "amount": 400       },     }   ],   "available_for_pickup": true } 

a couple of clarifications:

  • an item's visibility must set public appear in online store.
  • the available_online field (not shown in above example) controls whether item can added shipping orders. need set available_for_pickup , visibility fields pickup-only items.

Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -