---
updatedAt: 2026-09-28T14:14:08.000Z
agentTools:
  projectIndex: https://developer.searchblox.com/v10.2/llms.txt
---

# Collection API

The SearchBlox Collections API enables the user to get a list of collection names/ids as well as individual collection id from SearchBlox using simple HTTP POST and GET actions. SearchBlox Collection API provides methods for working with few aspects of the collection and indexed documents using REST requests with JSON payloads.

\#**Listing the Collections**
\##Index URL
<https://localhost:8443/rest/collection/list>

\##Method
POST

\##Media Type
application/json

\##Headers
content-type : application/json
accept: application/json

\##Headers
SB-PKEY
LmfxTTDSeYxHTntJMHuhwRrGVICMaVN/wl/zPuQ3LtQDNRMnng5GpKIkgt0q1rCC/h6wDA==

\##Document Syntax

[block:code]
{
  "codes": [
    {
      "code": "{\n\"apikey\":\"C6D418861BAD66A46A7CC96B70CEADF9\"\n}",
      "language": "json"
    }
  ]
}
[/block]

\##Document Description

[block:parameters]
{
  "data": {
    "h-0": "JSON Fields",
    "h-1": "Value",
    "h-2": "Value",
    "0-0": "apikey",
    "0-1": "API key accessible in the Dashboard->Administration->License. It is also present in the config.xml file.",
    "0-2": "License value from license.xml file"
  },
  "cols": 2,
  "rows": 1
}
[/block]

\#**Get the individual Collection Id**
\##Index URL
<https://localhost:8443/rest/collection/list>

\##Method
POST

\##Media Type
application/json

\##Headers
content-type : application/json
accept: application/json

\##Headers
SB-PKEY
LmfxTTDSeYxHTntJMHuhwRrGVICMaVN/wl/zPuQ3LtQDNRMnng5GpKIkgt0q1rCC/h6wDA==

\##Document Syntax

[block:code]
{
  "codes": [
    {
      "code": "{\n\"apikey\":\"C6D418861BAD66A46A7CC96B70CEADF9\",\n\"name\": \"site\"\n}",
      "language": "json",
      "name": "JSON"
    }
  ]
}
[/block]

\##Document Description

[block:parameters]
{
  "data": {
    "h-0": "JSON Fields",
    "h-1": "Value",
    "h-2": "Value",
    "0-0": "apikey",
    "0-1": "API key accessible in the SearchBlox Admin Console. It is also present in the config.xml file.",
    "0-2": "License value from license.xml file",
    "1-0": "Name",
    "1-1": "Name of the collection for which the id has to be identified"
  },
  "cols": 2,
  "rows": 2
}
[/block]