All user-specified searches in the API are done with RSQL. RSQL is a query language for parametrized filtering of entries in RESTful APIs. You can see more detailed information here, or see below for some quick tips and examples.
Logical Operators
- AND :
;
orand
;
must be URL-encoded as%3B
- see Searching for enabled accounts with a specific account number example below
- OR:
,
oror
Comparison Operators
- Equal to :
==
- Not equal to :
!=
- Less than :
=lt=
or < - Less than or equal to :
=le=
or<=
- Greater than operator :
=gt=
or>
- Greater than or equal to :
=ge=
or>=
- In :
=in=
- Not in :
=out=
- Is null:
=isnull=true
- Not null:
=notnull=true
Examples
- Search for accounts with recent new statements
utility/accounts?search=latestNewStatement=gt=2023-11-01
- To search with wildcards, use * on either end of the string.
utility/providers?search=providerName==Georgia*
- Searching for enabled accounts with a specific account number
utility/accounts?search=enabled==true%3BnormalizedAccountNumber==123
- Searching for meters within a specified list
utility/meters?search=meterNumber=in=(123,456,789)
- When Searching for a term with a space in it, use quotes around the string
utility/providers?search=providerName=="Georgia Power"
- Searching for meters with a null meter number
utility/meters?search=meterNumber=notnull=true
- Search for the sub accounts within a summary account
utility/accounts?search=summaryAccountNumber=="123-456"