slug = $slug; $this->category = $category; $this->description = $description; $this->automation = $automation; $this->type = $type; } public function getSlug(): string { return $this->slug; } public function getName(): string { return $this->automation->getName(); } public function getCategory(): int { return $this->category; } public function getType(): string { return $this->type; } public function getDescription(): string { return $this->description; } public function getAutomation(): Automation { return $this->automation; } public function toArray(): array { return [ 'slug' => $this->getSlug(), 'name' => $this->getName(), 'category' => $this->getCategory(), 'type' => $this->getType(), 'description' => $this->getDescription(), 'automation' => $this->getAutomation()->toArray(), ]; } }