> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.amniscient.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.amniscient.com/_mcp/server.

# Get Detection Items

GET https://api.amniscient.com/model/{model_id}/detection-items

Get the detection items associated to an active model within your organization on AmniSphere.

Reference: https://docs.amniscient.com/api-reference/api-reference/get-detection-items

## Request

### Path parameters

- `model_id` (string, required) — The model ID of an active and trained AI model within your organization.

### Query parameters

- `organizationId` (string, required) — Your organization's unique identifier.

### Headers

- `x-api-key` (string, required) — Your organization's active API Key.

## Response

### 200

200 - Items retrieved successfully

- `list of GetItemsResponseItems`

## Errors

### 400 Bad Request Error

Invalid request

- `status` (string, optional) — A status code denoting success or failure.
- `message` (string, optional) — A message describing the successful action or error state.

### 401 Unauthorized Error

Unauthorized

- `status` (string, optional) — A status code denoting success or failure.
- `message` (string, optional) — A message describing the successful action or error state.

## Types

### GetItemsResponseItems

- `id` (string, optional) — The detection item id of an object associated to the model provided. This will match the detection item id in the library for this object.
- `label` (string, optional) — The object name of an object associated to the model provided. This will match the object name in the library for this object.
- `organizationId` (string, optional) — Your organization's unique identifier.
- `attributes` (map from string to string, optional) — A map of attributes associated with an object within the model provided. These attributes will match the attributes within the library for this object.
- `deleted_at` (datetime, optional, nullable) — The date and time at which this object was deleted within your organization's library. This value will always be null for active objects.
- `created_at` (datetime, optional) — The date and time at which this object was originally created within your organization's library.
- `updated_at` (datetime, optional) — The date and time at which this object was last updated within your organization's library.

## Examples

**Response**

```json
[
  {
    "id": "1f336329-4c38-4501-8af1-8661e9d7df25",
    "label": "Banana",
    "attributes": {
      "label": "banana"
    },
    "deleted_at": null,
    "created_at": "2024-09-30T20:38:29.254Z",
    "updated_at": "2025-12-02T18:52:14.476Z",
    "organization_id": "2a432e67-bf5d-4acb-ab26-a8f4e3b218c9"
  },
  {
    "id": "53802c00-a508-439b-aba8-9e108fff822b",
    "label": "Figurine",
    "attributes": {
      "test": "bob"
    },
    "deleted_at": null,
    "created_at": "2025-06-18T17:26:15.387Z",
    "updated_at": "2025-09-15T18:59:25.832Z",
    "organization_id": "2a432e67-bf5d-4acb-ab26-a8f4e3b218c9"
  },
  {
    "id": "178cfaaa-f227-4fcc-97b4-e991b7bd785b",
    "label": "Box",
    "attributes": {
      "test": "box"
    },
    "deleted_at": null,
    "created_at": "2025-06-18T17:26:15.391Z",
    "updated_at": "2025-12-31T15:42:15.400Z",
    "organization_id": "2a432e67-bf5d-4acb-ab26-a8f4e3b218c9"
  }
]
```

**SDK Code**

```python Successfully retrieved items
import requests

url = "https://api.amniscient.com/model/model_id/detection-items"

querystring = {"organizationId":"organizationId"}

headers = {"x-api-key": "x-api-key"}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
```

```javascript Successfully retrieved items
const url = 'https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId';
const options = {method: 'GET', headers: {'x-api-key': 'x-api-key'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Successfully retrieved items
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("x-api-key", "x-api-key")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Successfully retrieved items
require 'uri'
require 'net/http'

url = URI("https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-api-key"] = 'x-api-key'

response = http.request(request)
puts response.read_body
```

```java Successfully retrieved items
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId")
  .header("x-api-key", "x-api-key")
  .asString();
```

```php Successfully retrieved items
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId', [
  'headers' => [
    'x-api-key' => 'x-api-key',
  ],
]);

echo $response->getBody();
```

```csharp Successfully retrieved items
using RestSharp;

var client = new RestClient("https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId");
var request = new RestRequest(Method.GET);
request.AddHeader("x-api-key", "x-api-key");
IRestResponse response = client.Execute(request);
```

```swift Successfully retrieved items
import Foundation

let headers = ["x-api-key": "x-api-key"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.amniscient.com/model/model_id/detection-items?organizationId=organizationId")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```