public function create(MarketingEvent &$marketingEvent)
    {
        $data = $marketingEvent->exportData();
        $endpoint = '/admin/marketing_events.json';
        $response = $this->request(
            $endpoint, 'POST', array(
            'marketing_event' => $data
            )
        );
        $marketingEvent->setData($response['marketing_event']);
    }
public function create(MarketingEvent &$marketingEvent)
    {
        $data = $marketingEvent->exportData();
        $endpoint = '/admin/marketing_events.json';
        $response = $this->request(
            $endpoint, 'POST', array(
            'marketing_event' => $data
            )
        );
        $marketingEvent->setData($response['marketing_event']);
    }
public function create ( MarketingEvent & $ marketingEvent ) { $ data = $ marketingEvent -> exportData ( ) ; $ endpoint = '/admin/marketing_events.json' ; $ response = $ this -> request ( $ endpoint , 'POST' , array ( 'marketing_event' => $ data ) ) ; $ marketingEvent -> setData ( $ response [ 'marketing_event' ] ) ; }
Create a marketing event

@link   https://help.shopify.com/api/reference/marketing_event#create
@param  MarketingEvent $marketingEvent
@return void
Create a marketing event