Post

Creates a filter to be stored in the database.

URL:

https://<ServerIP>:<Port>/ccp-webapp/ccp/filter

HTTPS method:

POST

Parameters:

See Filter API Parameters.

Example XML request payload for Bayesian filter:

 
<Filter> 
   <name>Bayesian</name>
   <description>Bayesian</description> 
   <type>2</type>
</Filter>

Example XML request payload for author filter:


<Filter>
   <name>String</name>
   <description>String</description>
   <type>3</type>
   <keywords>
     <keyword>author name</keyword>
     <keyword>author userid</keyword>
   </keywords>
   <rule>1</rule>
</Filter>

Example XML request payload for script filter, showing the CDATA wrapper:


<Filter>
   <name>String</name>
   <description>String</description>
   <type>4</type>   
   <scriptFileName>me.groovy</scriptFileName>
   <scriptContent>
   <![CDATA[put the text of your filter here.]]>
   </scriptContent>
</Filter>

HTTPS response headers:

The response contains the URL for the newly created filter.


https/1.1 201 Created
Location: https://<ServerIP>:<Port>/ccp-webapp/ccp/
filter/1266345862276
Content-Type: text/plain
Content-Length: 0
Date: Tue, 16 Feb 2010 19:35:56 GMT