public function add($name, $tags= '', $isDynamic = 0, $filterMediaName = '', $filterMediaTags = '')
    {
        $hydratedWidgets = [];
        $this->name = $name;
        $this->tags = $tags;
        $this->isDynamic = $isDynamic;
        $this->filterMediaName = $filterMediaName;
        $this->filterMediaTags = $filterMediaTags;

        $this->getLogger()->info('Creating Playlist ' . $this->name);
        $response = $this->doPost('/playlist', $this->toArray());

        /** @var XiboPlaylist $playlist */
        $playlist = new XiboPlaylist($this->getEntityProvider());
        $playlist->hydrate($response);
        if (isset($playlist->widgets)) {
            foreach ($playlist->widgets as $widget) {
                /** @var XiboWidget $widgetObject */
                $widgetObject = new XiboWidget($this->getEntityProvider());
                $widgetObject->hydrate($widget);
                $hydratedWidgets[] = $widgetObject;
            }
            $playlist->widgets = $hydratedWidgets;
        }

        return $playlist;
    }