curl --request GET \
--url https://davinci-app.com/api/v2/projects/{projectId}/objects/{objectId}/history \
--header 'Authorization: Bearer <token>'import os
from davinci_sdk import DavinciClient
with DavinciClient(api_key=os.environ["DAVINCI_API_KEY"]) as client:
result = client.branches.get_object_history(project_id, object_id)
for entry in result.history:
print(entry.commit.short_hash, entry.change_type)
import { DavinciClient } from '@celedon/davinci-sdk';
const client = new DavinciClient({
apiKey: process.env.DAVINCI_API_KEY!,
});
const { history } = await client.branches.getObjectHistory(projectId, objectId);
for (const entry of history) {
console.log(entry.commit.shortHash, entry.changeType);
}
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://davinci-app.com/api/v2/projects/{projectId}/objects/{objectId}/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"objectId": "<string>",
"found": true,
"totalChanges": 1,
"history": [
{
"commit": {
"hash": "<string>",
"shortHash": "<string>",
"message": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"author": {
"name": "<string>",
"email": "<string>"
}
},
"changeType": "created",
"state": {},
"changes": {}
}
]
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}Read an object's commit history
Returns the commits on a branch that changed one object, newest first, each with the object’s state at that commit and the fields that changed.
Commits that did not touch the object are omitted, so this is not a slice of the project history — it is the object’s own.
curl --request GET \
--url https://davinci-app.com/api/v2/projects/{projectId}/objects/{objectId}/history \
--header 'Authorization: Bearer <token>'import os
from davinci_sdk import DavinciClient
with DavinciClient(api_key=os.environ["DAVINCI_API_KEY"]) as client:
result = client.branches.get_object_history(project_id, object_id)
for entry in result.history:
print(entry.commit.short_hash, entry.change_type)
import { DavinciClient } from '@celedon/davinci-sdk';
const client = new DavinciClient({
apiKey: process.env.DAVINCI_API_KEY!,
});
const { history } = await client.branches.getObjectHistory(projectId, objectId);
for (const entry of history) {
console.log(entry.commit.shortHash, entry.changeType);
}
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://davinci-app.com/api/v2/projects/{projectId}/objects/{objectId}/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"objectId": "<string>",
"found": true,
"totalChanges": 1,
"history": [
{
"commit": {
"hash": "<string>",
"shortHash": "<string>",
"message": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"author": {
"name": "<string>",
"email": "<string>"
}
},
"changeType": "created",
"state": {},
"changes": {}
}
]
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>",
"details": {}
}
}Authorizations
Personal access token. The scopes granted at issuance determine both which
operations the key may call and the ceiling on the resource permissions it
can exercise. Each scope family is a ladder: projects:manage implies
projects:write and projects:read; cards:manage implies cards:write
and cards:read; and teams:manage implies teams:write and teams:read.
These are named API capability bundles, not blanket domain roles:
manage exposes only the permissions enumerated for that scope and never
bypasses the acting user's current role-based access.
Path Parameters
Project id. May be compound in the form {projectId}--{branchName}.
1Id of an object in the project.
1Response
The object's history on this branch.
False when no commit on this branch ever touched the object.
x >= 0Newest first. Commits that did not change the object are omitted.
Hide child attributes
Hide child attributes
created, modified, deleted The object as of this commit. Null when the commit deleted it.
Field-level difference from the previous commit.