Model/Search.php
public function jsonSerialize()
    {
        $json = [];

        if (null !== $this->offset) {
            $json['offset'] = $this->offset;
        }
        if (null !== $this->limit) {
            $json['limit'] = $this->limit;
        }
        if (null !== $this->freeText) {
            $json['freeText'] = $this->freeText;
        }
        if (null !== $this->objectIds && !empty($this->objectIds)) {
            $json['objectIds'] = $this->objectIds;
        }
        if (null !== $this->mediaIds && !empty($this->mediaIds)) {
            $json['mediaIds'] = $this->mediaIds;
        }
        if (null !== $this->createdByIds && !empty($this->createdByIds)) {
            $json['createdByIds'] = $this->createdByIds;
        }
        if (null !== $this->createdRange) {
            $json['createdRange'] = $this->createdRange;
        }
        if (null !== $this->updatedByIds && !empty($this->updatedByIds)) {
            $json['updatedByIds'] = $this->updatedByIds;
        }
        if (null !== $this->updatedRange) {
            $json['updatedRange'] = $this->updatedRange;
        }
        if (null !== $this->mediaStatusIds && !empty($this->mediaStatusIds)) {
            $json['mediaStatusIds'] = $this->mediaStatusIds;
        }
        if (null !== $this->folderIds && !empty($this->folderIds)) {
            $json['folderIds'] = $this->folderIds;
        }
        if (null !== $this->folderDepth) {
            $json['folderDepth'] = $this->folderDepth;
        }
        if (null !== $this->moodboardIds && !empty($this->moodboardIds)) {
            $json['moodboardIds'] = $this->moodboardIds;
        }
        if (null !== $this->categoryIds && !empty($this->categoryIds)) {
            $json['categoryIds'] = $this->categoryIds;
        }
        if (null !== $this->ignoreGrouping) {
            $json['ignoreGrouping'] = $this->ignoreGrouping;
        }
        if (null !== $this->includeChildren) {
            $json['includeChildren'] = $this->includeChildren;
        }
        if (null !== $this->parentId) {
            $json['parentId'] = $this->parentId;
        }
        if (null !== $this->deploymentSiteIds && !empty($this->deploymentSiteIds)) {
            $json['deploymentSiteIds'] = $this->deploymentSiteIds;
        }
        if (null !== $this->properties && !empty($this->properties)) {
            $json['properties'] = $this->properties;
        }
        if (null !== $this->fileSizeCriteria && !empty($this->fileSizeCriteria)) {
            $json['fileSizeCriteria'] = $this->fileSizeCriteria;
        }
        if (null !== $this->widthCriteria && !empty($this->widthCriteria)) {
            $json['widthCriteria'] = $this->widthCriteria;
        }
        if (null !== $this->heightCriteria && !empty($this->heightCriteria)) {
            $json['heightCriteria'] = $this->heightCriteria;
        }
        if (null !== $this->mimeTypes && !empty($this->mimeTypes)) {
            $json['mimeTypes'] = $this->mimeTypes;
        }
        if (null !== $this->fileName) {
            $json['fileName'] = $this->fileName;
        }
        if (null !== $this->name) {
            $json['name'] = $this->name;
        }
        if (null !== $this->deploymentDateRange) {
            $json['deploymentDateRange'] = $this->deploymentDateRange;
        }
        if (null !== $this->sortFields && !empty($this->sortFields)) {
            $json['sortFields'] = $this->sortFields;
        }
        if (null !== $this->duplicates) {
            $json['duplicates'] = $this->duplicates;
        }

        return $json;
    }
public function jsonSerialize()
    {
        $json = [];

        if (null !== $this->offset) {
            $json['offset'] = $this->offset;
        }
        if (null !== $this->limit) {
            $json['limit'] = $this->limit;
        }
        if (null !== $this->freeText) {
            $json['freeText'] = $this->freeText;
        }
        if (null !== $this->objectIds && !empty($this->objectIds)) {
            $json['objectIds'] = $this->objectIds;
        }
        if (null !== $this->mediaIds && !empty($this->mediaIds)) {
            $json['mediaIds'] = $this->mediaIds;
        }
        if (null !== $this->createdByIds && !empty($this->createdByIds)) {
            $json['createdByIds'] = $this->createdByIds;
        }
        if (null !== $this->createdRange) {
            $json['createdRange'] = $this->createdRange;
        }
        if (null !== $this->updatedByIds && !empty($this->updatedByIds)) {
            $json['updatedByIds'] = $this->updatedByIds;
        }
        if (null !== $this->updatedRange) {
            $json['updatedRange'] = $this->updatedRange;
        }
        if (null !== $this->mediaStatusIds && !empty($this->mediaStatusIds)) {
            $json['mediaStatusIds'] = $this->mediaStatusIds;
        }
        if (null !== $this->folderIds && !empty($this->folderIds)) {
            $json['folderIds'] = $this->folderIds;
        }
        if (null !== $this->folderDepth) {
            $json['folderDepth'] = $this->folderDepth;
        }
        if (null !== $this->moodboardIds && !empty($this->moodboardIds)) {
            $json['moodboardIds'] = $this->moodboardIds;
        }
        if (null !== $this->categoryIds && !empty($this->categoryIds)) {
            $json['categoryIds'] = $this->categoryIds;
        }
        if (null !== $this->ignoreGrouping) {
            $json['ignoreGrouping'] = $this->ignoreGrouping;
        }
        if (null !== $this->includeChildren) {
            $json['includeChildren'] = $this->includeChildren;
        }
        if (null !== $this->parentId) {
            $json['parentId'] = $this->parentId;
        }
        if (null !== $this->deploymentSiteIds && !empty($this->deploymentSiteIds)) {
            $json['deploymentSiteIds'] = $this->deploymentSiteIds;
        }
        if (null !== $this->properties && !empty($this->properties)) {
            $json['properties'] = $this->properties;
        }
        if (null !== $this->fileSizeCriteria && !empty($this->fileSizeCriteria)) {
            $json['fileSizeCriteria'] = $this->fileSizeCriteria;
        }
        if (null !== $this->widthCriteria && !empty($this->widthCriteria)) {
            $json['widthCriteria'] = $this->widthCriteria;
        }
        if (null !== $this->heightCriteria && !empty($this->heightCriteria)) {
            $json['heightCriteria'] = $this->heightCriteria;
        }
        if (null !== $this->mimeTypes && !empty($this->mimeTypes)) {
            $json['mimeTypes'] = $this->mimeTypes;
        }
        if (null !== $this->fileName) {
            $json['fileName'] = $this->fileName;
        }
        if (null !== $this->name) {
            $json['name'] = $this->name;
        }
        if (null !== $this->deploymentDateRange) {
            $json['deploymentDateRange'] = $this->deploymentDateRange;
        }
        if (null !== $this->sortFields && !empty($this->sortFields)) {
            $json['sortFields'] = $this->sortFields;
        }
        if (null !== $this->duplicates) {
            $json['duplicates'] = $this->duplicates;
        }

        return $json;
    }
Gets all data that should be available in a json representation.

@return array an associative array of the available variables