Have your say in Community Polls: What was/is your greatest motivation to start your own business?
Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Creating a draft on an instance on a specific market

Creating a draft on an instance on a specific market

Piotrek
Shopify Partner
3 0 1

Hello,

I have a question.

I have an instance where I have 10 different markets. The main market is PL

I want to create a draft on this instance on the DE market how to do it?

I am sending this data

 

I have something like this:

 

        $order = [
            "email" => $data['email'],
            "line_items" =>
                $product
            ,
            "shipping_address" => [
                "first_name"    => $data['customer']['first_name'],
                "last_name"     => $data['customer']['last_name'],
                "address1"      => $data['customer']['address1'],
                "phone"         => $data['customer']['phone'],
                "city"          => $data['customer']['city'],
                "zip"           => $data['customer']['zip'],
                'country'       => self::getNameCountryForCode(strtoupper($data['customer']['country_code'])),
           ],
           "shipping_line" => [
                'title'     => $data['delivery'],
                'price'     => $data['price_delivery']
            ]
        ];

how to add the id of the market so that the draft is assigned there.

on this particular market there is a different currency than on the main one.

 

Piotr

Replies 0 (0)