---
title: "POST /targets/"
method: POST
path: "/targets/"
---

# POST /targets/

`POST /targets/`

Creates a new Target entity reflecting content submitted for scanning.

## Request body

- object
  - `title` string
  - `description` string
  - `views` number
  - `creator` Creator
    - `ip_address` union
      - string, ipv4
      - string, ipv6
      - string, hostname
  - `client_context` string — An opaque string that will be associated with the entity throughout the pipeline.
  - `content_type` 'IMAGE' | 'TEXT', required
  - `content_bytes` string, byte, required — The target content, encoded as a base64 string.

## Response `201`

The target was successfully created.

- Target
  - `id` string, required
  - `create_time` string, date-time, required
  - `title` string
  - `description` string
  - `views` number
  - `content_bytes` string, byte — The target content, encoded as a base64 string.
  - `creator` Creator
    - `ip_address` union
      - string, ipv4
      - string, ipv6
      - string, hostname
  - `client_context` string — An opaque string that will be associated with the entity throughout the pipeline.
  - `safe_search_scores` object
    - `adult` 'UNKNOWN' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY'
    - `spoof` 'UNKNOWN' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY'
    - `medical` 'UNKNOWN' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY'
    - `violence` 'UNKNOWN' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY'
    - `racy` 'UNKNOWN' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY'

## Other responses

- `400` — An invalid request was provided.
- `500` — An internal error occurred.

---

[API](https://skmtc.dev/google/apis/altitude-api.md) · [All operations](https://skmtc.dev/google/apis/altitude-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/google/altitude-api/revisions/5f70f11404d8/schema)
