---
title: "Duplicate record"
method: POST
path: "/table/{tableId}/record/{recordId}/duplicate"
tags: ["record"]
---

# Duplicate record

`POST /table/{tableId}/record/{recordId}/duplicate`

Create a copy of an existing record with optional custom positioning in the view.

## Path parameters

- `tableId` string, required
- `recordId` string, required

## Request body

- object — Where this record to insert to (Optional)
  - `viewId` string, required — You can only specify order in one view when create record (will create a order index automatically)
  - `anchorId` string, required — The record id to anchor to
  - `position` 'before' | 'after', required

## Response `201`

Successful duplicate

- object
  - `records` object[], required — Array of record objects
    - `id` string, required — The record id.
    - `name` string — primary field value
    - `fields` object, required — Objects with a fields key mapping fieldId or field name to value for that field.
    - `autoNumber` number — Auto number, a unique identifier for each record
    - `createdTime` string — Created time, date ISO string (new Date().toISOString).
    - `lastModifiedTime` string — Last modified time, date ISO string (new Date().toISOString).
    - `createdBy` string — Created by, user name
    - `lastModifiedBy` string — Last modified by, user name
    - `permissions` object — Permissions for the record
    - `undeletable` boolean — Whether the record is undeletable

---

[API](https://skmtc.dev/teable/apis/teable-app.md) · [All operations](https://skmtc.dev/teable/apis/teable-app/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/teable/teable-app/revisions/7515f3b33d79/schema)
