Compile an interaction filter.

To learn how to use the endpoints together take a look at our PYLON API step-by-step page.

An HTTPS POST request sent to:

A successful call to this endpoint returns: 200 OK plus a JSON object.


Parameter Description

The CSDL code to compile. Must be less than 1MB.


Sample request

curl -X POST 
  -d '{"csdl":"fb.type == \"story\" and fb.content contains \"DataSift\""}' 
  -H "Content-type: application/json" 
  -H 'Authorization: username:api_key'


HTTP/1.1 200 OK
Content-type: application/json

    "hash": "1a4268c9b924d2c48ed1946d6a7e6272",
    "created_at": 1424280706,
    "operator_grouping": {
        "return": {
            "keywords": 0,
            "complex": 0,
            "medium": 5
        "tag": {
            "keywords": 0,
            "complex": 0,
            "medium": 1
        "tokenizer_info": {
            "language": [],
            "punctuation": []

Output Fields

Property Type Description
hash string The hash for this interaction filter.
created_at int Unix timestamp.
error string A description of the error if the call fails.


Response code Description
Status 200 OK See above for example of the JSON output.
Status 400 Bad Request

The CSDL is invalid or was not provided:

    "error":"<validation information>"


  1. All calls to the API must be properly authenticated with a DataSift username and API key.
  2. All calls to the API must be versioned. The current version is v1.3.
  3. Note that the username is the one you use to log in to and to make calls to any of the REST endpoints but the API key is the one that was returned by your call to the  POST /account/identity endpoint. That is, it is an identity-based API key.
  4. Take a look at our Changelog page to review the changes we've made to the DataSift API over time.

Resource information

Rate limit cost: 5

Requires authentication: Yes

Response formats: JSON, JSONP