renakre
renakre

Reputation: 8291

How to track user activity data on google docs

I wonder if it is possible to track user activity data on google docs. My goal is to know what changes the users did (e.g., adding a new paragraph) and when. At the end, I want to visualize the changes made by each user on a document per each day. I could not find a google drive api method. I found Drive Activity API, but not sure if this is what I am looking.

As a backup plan, I am thinking to include the google doc inside an iframe within my web application to store the key strokes. I appreciate any suggestions.

Upvotes: 1

Views: 267

Answers (1)

Linda Lawton - DaImTo
Linda Lawton - DaImTo

Reputation: 116968

I believe what you are lookging for is revisions.list I am not sure how much of the information you are looking for is actually returned but it does return some information about the changes that where made.

{
  "kind": "drive#revisionList",
  "nextPageToken": string,
  "revisions": [
    revisions Resource
  ]
}

revision

{
  "kind": "drive#revision",
  "id": string,
  "mimeType": string,
  "modifiedTime": datetime,
  "keepForever": boolean,
  "published": boolean,
  "publishAuto": boolean,
  "publishedOutsideDomain": boolean,
  "lastModifyingUser": {
    "kind": "drive#user",
    "displayName": string,
    "photoLink": string,
    "me": boolean,
    "permissionId": string,
    "emailAddress": string
  },
  "originalFilename": string,
  "md5Checksum": string,
  "size": long,
  "exportLinks": {
    (key): string
  }
}

Upvotes: 1

Related Questions