Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Excerpt

Public content search

 

Endpoint ID:

9005

Method:

Image Added

URL:

POST /data/content/search

Request body:

JSON data with information about the content to be created.

Required fields:
 

tags:

JSON array of Tags. At least one Tag must be present in the array. Tags must be url-safe, with Regular Expression

: [a-zA-Z]+[a-zA-Z0-9-_]*

 

content:

The content text of base64 encoded type.

Optional fields:
 contenttype:Defined the type of content. If nothing is passed then default value is set to "text/html".
 value:Optional value
 activeFrom:

Optional date value defining content active start date. The date must be in UTC, for example "2014-01-01T01:00Z".

 activeTo:

Optional date value defining content active till date. The date must be in UTC, for example "2014-03-25T23:00Z".

Code Block
titleExample
{
   "tags": [ "tag1", "tag2" ],
   "fromDate": "2014-01-01T01:00Z",            // optional - ISO UTC date
   "limit": 2,                                 // optional - default to 1
   "offset": 10,                               // optional - default to 0
   "compare": "between",                       // optional ["=", "<", ">", "<=", ">=",
                                               //    "between", "empty", "notempty"]
   "compareValue1": 5.1,                       // required for "compare":
                                               //    ["=", "<", ">", "<=", ">=", "between"]
   "compareValue2": 5.9                        // required for "compare": "between"
}

Response body:

JSON data with information about the content created.

Code Block
titleExample
{
   "content": [
      {
         "tags": [ "tag1", "tag2" ],
         "contentType": "text/html",
         "content": "base64 encoded content string",
         "created": "2014-02-10T12:53Z",
         "value": 19.5
      },
      {
         "tags": [ "tag1", "tag2" ],
         "contentType": "text/html",
         "content": "base64 encoded content string",
         "created": "2014-02-02T15:02Z"
      }
   ],
   "paging": {
      "offset": 10,
      "count": 2,
      "more": true
   }
}

Status codes:

200

OK