Skip to main content
Planview Customer Success Center

Filter Service

POST /filter

Description:

Create a basic filter string using filterable properties. This filter string can be used to execute fuzzy searches based on the properties provided.

Parameters (body)

  • params: (JSON array) An array of JSON objects that contain a filterBn key and an array of value BNs. If you want to allow any value in that filter, add the filterBn and leave the value array empty. Use the GET /entityproperties/{entityType} request to acquire the filterBns.
  • searchString: (String) Query the BN, name and description of the object in the collection. The matching object will be added to the filtered collection.

Headers:

  • Authorization: (Your Basic Auth String)
  • Accept: text/plain;charset=UTF-8
  • Content-Type: application/json;charset=UTF-8

Example:

Request:

https://[tenant-end-point]/api/filter
Authorization: Basic {your basic auth}
Accept: text/plain;charset=UTF-8
Content-Type: application/json;charset=UTF-8

{
  "params": [
  	{ "04460000013X": ["040M000001RB"] },
  	{ "0446000000OM": ["COMP"] }
  ],
  "searchString": null
}

Response:

%7B%22params%22%3A%5B%7B%2204460000013X%22%3A%5B%22040M000001RB%22%5D%7D%2C%7B%220446000000OM%22%3A%5B%22COMP%22%5D%7D%5D%2C%22searchString%22%3Anull%7D

 

POST /operablefilter

Description:

Create a filter string using filterable properties. The filter string can be used in filter down data in collection requests.

Parameters (body)

  • params: (JSON array) An array of JSON objects that contain a key BN, an operator, and a value BN. Use the GET /entityproperties/{entityType} request to acquire the keys, and values.
  • joiningOperator: (String) This operator describes how the params array should be joined. Only the AND, or the OR operators may be used here. The default is AND operator.
  • searchString: (String) Query the BN, name and description of the object in the collection. The matching object will be added to the filtered collection.

Headers:

  • Authorization: (Your Basic Auth String)
  • Accept: text/plain;charset=UTF-8
  • Content-Type: application/json;charset=UTF-8

Example:

Request:

https://[tenant-end-point]/api/operablefilter
Authorization: Basic {your basic auth}
Accept: text/plain;charset=UTF-8
Content-Type: application/json;charset=UTF-8

{
  "params": [
  	{"key":"044600000377", "operator": "IS", "value": "040M00001644"},
  	{"key":"0446000000LL", "operator": "IS", "value": "040M000002PR"}
  ],
  "joiningOperator": "OR",
  "searchString": null
}

Response:

%7B%22params%22%3A%5B%7B%22key%22%3A%220446000000LL%22%2C%22operator%22%3A%22IS%22%2C%22value%22%3A%22040M000002PR%22%7D%2C%7B%22key%22%3A%22044600000377%22%2C%22operator%22%3A%22IS%22%2C%22value%22%3A%22040M00001644%22%7D%5D%2C%22joiningOperator%22%3A%22OR%22%2C%22searchString%22%3Anull%7D

 

GET /operators

Description:

Get a list of operator that can be used in the POST /operablefilter request.

Headers:

  • Authorization: (Your Basic Auth String)
  • Accept: application/json;charset=UTF-8

Example:

Request:

https://[tenant-end-point]/api/operators
Authorization: Basic {your basic auth}
Accept: application/json;charset=UTF-8

Response:

[
    "AFTER",
    "AFTER_OR_EQUALS",
    "ALL",
    "AND",
    "BEFORE",
    "BEFORE_OR_EQUALS",
    "CONTAINS",
    "COUNT_IS_EQUAL_TO",
    "COUNT_IS_GREATER_THAN",
    "COUNT_IS_LESS_THAN",
    "DOES_NOT_CONTAIN",
    "DOES_NOT_EXIST",
    "EQUALS",
    "EXISTS",
    "GREATER_THAN",
    "GREATER_THAN_OR_EQUAL_TO",
    "IN",
    "IN_FIELD",
    "IN_SUBQUERY",
    "IN_SUBQUERY_FIELD",
    "IS",
    "IS_NOT",
    "IS_EXACT_MATCH",
    "IS_SOMETHING_LIKE",
    "LESS_THAN",
    "LESS_THAN_OR_EQUALS",
    "LIFESPAN_AFTER",
    "LIFESPAN_AFTER_OR_EQUALS",
    "LIFESPAN_EQUALS",
    "LIFESPAN_WITHIN",
    "LIFESPAN_WITHIN_LAST",
    "LIFESPAN_WITHIN_NEXT",
    "NOT",
    "NOT_IN",
    "NOT_IN_SUBQUERY",
    "NOT_EQUAL",
    "OR",
    "SIMPLE",
    "WITHIN",
    "WITHIN_LAST",
    "WITHIN_NEXT"
]