commercetools · Capability
commercetools Change History API — ChangeHistory
commercetools Change History API — ChangeHistory. 2 operations. Lead operation: Query change history records. Self-contained Naftiko capability covering one Commercetools business surface.
What You Can Do
GET
Listchanges
— Query change history records
/v1/{projectkey}
GET
Listchangesbyresourceid
— Query change history for a specific resource
/v1/{projectkey}/{resourcetype}/{id}
MCP Tools
query-change-history-records
Query change history records
read-only
idempotent
query-change-history-specific-resource
Query change history for a specific resource
read-only
idempotent
Capability Spec
naftiko: 1.0.0-alpha2
info:
label: commercetools Change History API — ChangeHistory
description: 'commercetools Change History API — ChangeHistory. 2 operations. Lead operation: Query change history records.
Self-contained Naftiko capability covering one Commercetools business surface.'
tags:
- Commercetools
- ChangeHistory
created: '2026-05-19'
modified: '2026-05-19'
binds:
- namespace: env
keys:
COMMERCETOOLS_API_KEY: COMMERCETOOLS_API_KEY
capability:
consumes:
- type: http
namespace: change-history-changehistory
baseUri: https://history.{region}.commercetools.com
description: commercetools Change History API — ChangeHistory business capability. Self-contained, no shared references.
resources:
- name: projectKey
path: /{projectKey}
operations:
- name: listchanges
method: GET
description: Query change history records
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: date.from
in: query
type: string
description: Start of the date range filter. Accepts ISO 8601 datetime strings or relative values like "24" (last
24 hours) or "now".
- name: date.to
in: query
type: string
description: End of the date range filter. Accepts ISO 8601 datetime strings or relative values like "now".
- name: limit
in: query
type: integer
description: Maximum number of records to return per page.
- name: offset
in: query
type: integer
description: Number of records to skip for pagination.
- name: resourceTypes
in: query
type: string
description: Comma-separated list of resource types to filter by (e.g., "order,product,customer").
- name: changes
in: query
type: string
description: Filter by specific change type name (e.g., "setCustomField", "changeOrderState").
- name: resourceId
in: query
type: string
description: Filter records to changes affecting a specific resource ID.
- name: userId
in: query
type: string
description: Filter records to changes made by a specific user ID.
- name: clientId
in: query
type: string
description: Filter records to changes made by a specific API client ID.
- name: projectKey-resourceType-id
path: /{projectKey}/{resourceType}/{id}
operations:
- name: listchangesbyresourceid
method: GET
description: Query change history for a specific resource
outputRawFormat: json
outputParameters:
- name: result
type: object
value: $.
inputParameters:
- name: resourceType
in: path
type: string
description: The resource type category to filter the change history query.
required: true
- name: id
in: path
type: string
description: The system-generated ID of the specific resource.
required: true
- name: date.from
in: query
type: string
description: Start of the date range filter.
- name: date.to
in: query
type: string
description: End of the date range filter.
- name: limit
in: query
type: integer
description: Maximum number of records to return.
- name: offset
in: query
type: integer
description: Number of records to skip for pagination.
authentication:
type: bearer
token: '{{env.COMMERCETOOLS_API_KEY}}'
exposes:
- type: rest
namespace: change-history-changehistory-rest
port: 8080
description: REST adapter for commercetools Change History API — ChangeHistory. One Spectral-compliant resource per consumed
operation, prefixed with /v1.
resources:
- path: /v1/{projectkey}
name: projectkey
description: REST surface for projectKey.
operations:
- method: GET
name: listchanges
description: Query change history records
call: change-history-changehistory.listchanges
with:
date.from: rest.date.from
date.to: rest.date.to
limit: rest.limit
offset: rest.offset
resourceTypes: rest.resourceTypes
changes: rest.changes
resourceId: rest.resourceId
userId: rest.userId
clientId: rest.clientId
outputParameters:
- type: object
mapping: $.
- path: /v1/{projectkey}/{resourcetype}/{id}
name: projectkey-resourcetype-id
description: REST surface for projectKey-resourceType-id.
operations:
- method: GET
name: listchangesbyresourceid
description: Query change history for a specific resource
call: change-history-changehistory.listchangesbyresourceid
with:
resourceType: rest.resourceType
id: rest.id
date.from: rest.date.from
date.to: rest.date.to
limit: rest.limit
offset: rest.offset
outputParameters:
- type: object
mapping: $.
- type: mcp
namespace: change-history-changehistory-mcp
port: 9090
transport: http
description: MCP adapter for commercetools Change History API — ChangeHistory. One tool per consumed operation, routed
inline through this capability's consumes block.
tools:
- name: query-change-history-records
description: Query change history records
hints:
readOnly: true
destructive: false
idempotent: true
call: change-history-changehistory.listchanges
with:
date.from: tools.date.from
date.to: tools.date.to
limit: tools.limit
offset: tools.offset
resourceTypes: tools.resourceTypes
changes: tools.changes
resourceId: tools.resourceId
userId: tools.userId
clientId: tools.clientId
outputParameters:
- type: object
mapping: $.
- name: query-change-history-specific-resource
description: Query change history for a specific resource
hints:
readOnly: true
destructive: false
idempotent: true
call: change-history-changehistory.listchangesbyresourceid
with:
resourceType: tools.resourceType
id: tools.id
date.from: tools.date.from
date.to: tools.date.to
limit: tools.limit
offset: tools.offset
outputParameters:
- type: object
mapping: $.