Skip to main content

SCIM filter language

SCIM filtering

SCIM protocol provides a language to search and filter resources.

Please browse the standard specifications in this link: https://tools.ietf.org/html/rfc7644#section-3.4.2.2

Example

To search all users having "John" as name:

http://<domain>/webservice/scim/User/?filter=userName eq "John"

Use

This feature can be used with the Search by filter operation.

After the URL resource. the filter parameter with the language expression to apply must be added: <URL>?filter=<expression>

Remember that in this case the HTTP method is GET.

The result always is a SCIM response list.

Syntax

Attribute operators

Operator

Description

eq

equal

ne

not equal

co

contains

sw

starts with

ew

ends with

pr

present (has value)

gt

greater than

ge

greater than or equal to

lt

less than

le

less than or equal to

Logical operators

Operator

Description

and

Logical "and"

or

Logical "or"

not

"Not" function

Grouping operators

Operator

Description

( )

Precedence grouping

[ ]

Complex attribute filter group

Data values

Data type

Value

NumbersUse the value without ", for example 1234
TextUse the value within ", for example "John"
Date

Use the value within " with an ISO format, for example "2011-05-13T04:42:34Z"

BooleanUse [ true | false ] (without ")
NullUse [ null ] (without ")

Filter examples

filter=userName eq "admin"
filter=userName ne "admin"
filter=userName co "ad"
filter=userName sw "a"
filter=userName ew "n"
filter=userName pr
filter=id gt 1
filter=id ge 60
filter=id lt 1000
filter=id le 1188
filter=consoleProperties.id eq 229
filter=createdDate gt "2011-05-13T04:42:34Z"
filter=id eq 60 and id eq 1188
filter=id eq 60 or id eq 1188
filter=firstName eq "Admin" and id eq 60
filter=firstName eq "Admin" or id eq 61
filter=primaryGroup eq "world" and (firstName co "John” or lastName co "Smith")
filter=userName co "i" and (userName co "a" or userName co "s")
filter=id eq 60 and (userName co "a" and consoleProperties.id eq 229)