/** * Creates a Company with the HubSpotApi * * @return \SevenShores\Hubspot\Http\Response */ private function createCompany() { $companyName = 'A company name'; $companyDescription = 'A company description'; $properties = [['name' => 'name', 'value' => $companyName], ['name' => 'description', 'value' => $companyDescription], ['name' => 'domain', 'value' => 'example.com']]; $response = $this->companies->create($properties); sleep(1); return $response; }
/** * @return int */ private function createCompany() { $companies = new Companies(new Client(['key' => 'demo'])); return $companies->create(['name' => 'name', 'value' => 'dl_test_company' . uniqid()])->companyId; }