Skip to main content
POST
/
v1
/
search
/
cases
Search cases
curl --request POST \
  --url https://api1.irisagent.com/v1/search/cases \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "query": "<string>",
  "conversationId": "<string>",
  "productId": "<string>",
  "formId": "<string>",
  "sourceBrandId": "<string>",
  "filterUrls": [
    "<string>"
  ],
  "numResults": 4,
  "offset": 0,
  "limit": 25
}
'
{
  "results": [
    {
      "id": "<string>",
      "subject": "<string>",
      "url": "<string>",
      "timeOfCreation": 17437722600,
      "productId": "<string>",
      "score": 123
    }
  ]
}

Authorizations

Authorization
string
header
required

The Authorization header is required to authenticate API requests. It should contain a bearer token obtained through the IrisAgent portal.

Body

application/json
query
string

The search query string. Optional if conversationId is provided.

conversationId
string

Unique ticket or case ID to load the full ticket content (subject, description, and comments) for searching. Optional if query is provided. The ticket content will be loaded from the database and used as the search query. Note: The case with this conversationId will be excluded from the search results.

productId
string

The product ID to filter cases.

formId
string

The form ID to filter cases.

sourceBrandId
string

The source brand ID to filter cases.

filterUrls
string<uri>[]

Array of case URLs to exclude from the search results. Cases with URLs matching any of these URLs will be filtered out.

numResults
integer
default:4

(Legacy) Maximum number of results to return. Defaults to 4 if not specified. Prefer using offset and limit parameters for pagination.

Required range: 1 <= x <= 100
offset
integer<uint>
default:0

Number of results to skip for pagination. Used with limit parameter. If offset or limit is provided, pagination mode is used and numResults is ignored.

Required range: x >= 0
limit
integer<uint>
default:25

Maximum number of results to return per page. Defaults to 25 in pagination mode. If offset or limit is provided, pagination mode is used and numResults is ignored. Note: offset + limit cannot exceed 200 due to external API constraints.

Required range: 1 <= x <= 100

Response

Search results

results
object[]
required