---
title: "Index a new document"
method: POST
path: "/v3/index/{name}/documents"
tags: ["Search & Match"]
---

# Index a new document

`POST /v3/index/{name}/documents`

Create an indexed document for the search tool

## Path parameters

- `name` string, required — Unique index name

## Request body

- object
  - `document` string

## Response `201`

Returns the created indexed document

- object
  - `document` string — Unique identifier for the document.

## Other responses

- `400` — Bad request. If it is a validation error will contain a list of each invalid field
- `401` — Authorisation error
- `default` — UnexpectedError

---

[API](https://skmtc.net/affinda/apis/affinda-api-2.md) · [All operations](https://skmtc.net/affinda/apis/affinda-api-2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/affinda/affinda-api-2/versions/6772e50cb58e/schema)
