Flatfile · Capability
API Reference — subpackage_data-retention-policies
API Reference — subpackage_data-retention-policies. 5 operations. Lead operation: List data retention policies. Self-contained Naftiko capability covering one Flatfile business surface.
What You Can Do
GET
List
— List data retention policies
/v1/data-retention-policies
POST
Create
— Create a data retention policy
/v1/data-retention-policies
GET
Get
— Get a data retention policy
/v1/data-retention-policies/{id}
PATCH
Update
— Update a data retention policy
/v1/data-retention-policies/{id}
DELETE
Delete
— Delete a data retention policy
/v1/data-retention-policies/{id}
MCP Tools
list-data-retention-policies
List data retention policies
read-only
idempotent
create-data-retention-policy
Create a data retention policy
get-data-retention-policy
Get a data retention policy
read-only
idempotent
update-data-retention-policy
Update a data retention policy
idempotent
delete-data-retention-policy
Delete a data retention policy
idempotent
Capability Spec
naftiko: 1.0.0-alpha2
info:
label: API Reference — subpackage_data-retention-policies
description: 'API Reference — subpackage_data-retention-policies. 5 operations. Lead operation: List data retention policies.
Self-contained Naftiko capability covering one Flatfile business surface.'
tags:
- Flatfile
- subpackage_data-retention-policies
created: '2026-05-19'
modified: '2026-05-19'
binds:
- namespace: env
keys:
FLATFILE_API_KEY: FLATFILE_API_KEY
capability:
consumes:
- type: http
namespace: flatfile-subpackage-data-retention-policies
baseUri: https://api.x.flatfile.com/v1
description: API Reference — subpackage_data-retention-policies business capability. Self-contained, no shared references.
resources:
- name: data-retention-policies
path: /data-retention-policies
operations:
- name: list
method: GET
description: List data retention policies
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: environmentId
in: query
type: string
description: The associated Environment ID of the policy.
- name: Authorization
in: header
type: string
description: Bearer authentication
required: true
- name: X-Disable-Hooks
in: header
type: string
required: true
- name: create
method: POST
description: Create a data retention policy
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: Authorization
in: header
type: string
description: Bearer authentication
required: true
- name: X-Disable-Hooks
in: header
type: string
required: true
- name: body
in: body
type: object
description: Request body (JSON).
required: false
- name: data-retention-policies-id
path: /data-retention-policies/{id}
operations:
- name: get
method: GET
description: Get a data retention policy
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: id
in: path
type: string
description: ID of data retention policy to return
required: true
- name: Authorization
in: header
type: string
description: Bearer authentication
required: true
- name: X-Disable-Hooks
in: header
type: string
required: true
- name: update
method: PATCH
description: Update a data retention policy
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: id
in: path
type: string
description: ID of data retention policy to update
required: true
- name: Authorization
in: header
type: string
description: Bearer authentication
required: true
- name: X-Disable-Hooks
in: header
type: string
required: true
- name: body
in: body
type: object
description: Request body (JSON).
required: false
- name: delete
method: DELETE
description: Delete a data retention policy
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: id
in: path
type: string
description: ID of data retention policy to delete
required: true
- name: Authorization
in: header
type: string
description: Bearer authentication
required: true
- name: X-Disable-Hooks
in: header
type: string
required: true
authentication:
type: bearer
token: '{{env.FLATFILE_API_KEY}}'
exposes:
- type: rest
namespace: flatfile-subpackage-data-retention-policies-rest
port: 8080
description: REST adapter for API Reference — subpackage_data-retention-policies. One Spectral-compliant resource per
consumed operation, prefixed with /v1.
resources:
- path: /v1/data-retention-policies
name: data-retention-policies
description: REST surface for data-retention-policies.
operations:
- method: GET
name: list
description: List data retention policies
call: flatfile-subpackage-data-retention-policies.list
with:
environmentId: rest.environmentId
Authorization: rest.Authorization
X-Disable-Hooks: rest.X-Disable-Hooks
outputParameters:
- type: object
mapping: $.
- method: POST
name: create
description: Create a data retention policy
call: flatfile-subpackage-data-retention-policies.create
with:
Authorization: rest.Authorization
X-Disable-Hooks: rest.X-Disable-Hooks
body: rest.body
outputParameters:
- type: object
mapping: $.
- path: /v1/data-retention-policies/{id}
name: data-retention-policies-id
description: REST surface for data-retention-policies-id.
operations:
- method: GET
name: get
description: Get a data retention policy
call: flatfile-subpackage-data-retention-policies.get
with:
id: rest.id
Authorization: rest.Authorization
X-Disable-Hooks: rest.X-Disable-Hooks
outputParameters:
- type: object
mapping: $.
- method: PATCH
name: update
description: Update a data retention policy
call: flatfile-subpackage-data-retention-policies.update
with:
id: rest.id
Authorization: rest.Authorization
X-Disable-Hooks: rest.X-Disable-Hooks
body: rest.body
outputParameters:
- type: object
mapping: $.
- method: DELETE
name: delete
description: Delete a data retention policy
call: flatfile-subpackage-data-retention-policies.delete
with:
id: rest.id
Authorization: rest.Authorization
X-Disable-Hooks: rest.X-Disable-Hooks
outputParameters:
- type: object
mapping: $.
- type: mcp
namespace: flatfile-subpackage-data-retention-policies-mcp
port: 9090
transport: http
description: MCP adapter for API Reference — subpackage_data-retention-policies. One tool per consumed operation, routed
inline through this capability's consumes block.
tools:
- name: list-data-retention-policies
description: List data retention policies
hints:
readOnly: true
destructive: false
idempotent: true
call: flatfile-subpackage-data-retention-policies.list
with:
environmentId: tools.environmentId
Authorization: tools.Authorization
X-Disable-Hooks: tools.X-Disable-Hooks
outputParameters:
- type: object
mapping: $.
- name: create-data-retention-policy
description: Create a data retention policy
hints:
readOnly: false
destructive: false
idempotent: false
call: flatfile-subpackage-data-retention-policies.create
with:
Authorization: tools.Authorization
X-Disable-Hooks: tools.X-Disable-Hooks
body: tools.body
outputParameters:
- type: object
mapping: $.
- name: get-data-retention-policy
description: Get a data retention policy
hints:
readOnly: true
destructive: false
idempotent: true
call: flatfile-subpackage-data-retention-policies.get
with:
id: tools.id
Authorization: tools.Authorization
X-Disable-Hooks: tools.X-Disable-Hooks
outputParameters:
- type: object
mapping: $.
- name: update-data-retention-policy
description: Update a data retention policy
hints:
readOnly: false
destructive: false
idempotent: true
call: flatfile-subpackage-data-retention-policies.update
with:
id: tools.id
Authorization: tools.Authorization
X-Disable-Hooks: tools.X-Disable-Hooks
body: tools.body
outputParameters:
- type: object
mapping: $.
- name: delete-data-retention-policy
description: Delete a data retention policy
hints:
readOnly: false
destructive: true
idempotent: true
call: flatfile-subpackage-data-retention-policies.delete
with:
id: tools.id
Authorization: tools.Authorization
X-Disable-Hooks: tools.X-Disable-Hooks
outputParameters:
- type: object
mapping: $.