curl --request GET \
--url https://api.example.com/{collection}/{id}/diff/{v1}/{v2}{
"400": {},
"401": {},
"403": {},
"404": {},
"500": {},
"501": {},
"from_version": 123,
"to_version": 123,
"changes": [
{
"field": "<string>",
"from": "<any>",
"to": "<any>"
}
]
}Compare two versions and get the changes between them
curl --request GET \
--url https://api.example.com/{collection}/{id}/diff/{v1}/{v2}{
"400": {},
"401": {},
"403": {},
"404": {},
"500": {},
"501": {},
"from_version": 123,
"to_version": 123,
"changes": [
{
"field": "<string>",
"from": "<any>",
"to": "<any>"
}
]
}Compares two versions of a document and returns a detailed list of field-level changes between them.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/KTS-o7/permission-mongo/llms.txt
Use this file to discover all available pages before exploring further.
GET /{collection}/{id}/diff/{v1}/{v2}
read permission on the collection and access to the specific document.
curl -X GET "https://api.example.com/employees/emp_12345/diff/1/3" \
-H "Authorization: Bearer <token>"
{
"from_version": 1,
"to_version": 3,
"changes": [
{
"field": "department",
"from": "Engineering",
"to": "Marketing"
},
{
"field": "salary",
"from": 70000,
"to": 85000
},
{
"field": "manager_id",
"from": "mgr_001",
"to": "mgr_002"
},
{
"field": "skills",
"from": ["JavaScript", "React"],
"to": ["JavaScript", "React", "Node.js"]
}
]
}
{
"field": "phone",
"from": null,
"to": "+1-555-0123"
}
{
"field": "temporary_access",
"from": true,
"to": null
}
{
"field": "status",
"from": "active",
"to": "inactive"
}
{
"field": "address.city",
"from": "San Francisco",
"to": "New York"
}
{
"field": "tags",
"from": ["developer", "frontend"],
"to": ["developer", "frontend", "lead"]
}
[
{
"field": "address.street",
"from": "123 Main St",
"to": "456 Oak Ave"
},
{
"field": "address.city",
"from": "Boston",
"to": "Seattle"
}
]
from: null)to: null){
"error": {
"code": "BAD_REQUEST",
"message": "v1 must be less than v2",
"details": {
"v1": 5,
"v2": 3
}
}
}
{
"error": {
"code": "VERSION_NOT_FOUND",
"message": "One or both versions not found",
"details": {
"collection": "employees",
"id": "emp_12345",
"v1": 1,
"v2": 99
}
}
}