{
  "discoveryVersion": "v1",
  "icons": {
    "x16": "http://www.google.com/images/icons/product/search-16.gif",
    "x32": "http://www.google.com/images/icons/product/search-32.gif"
  },
  "basePath": "",
  "documentationLink": "https://developers.google.com/workspace/keep/api",
  "version_module": true,
  "ownerDomain": "google.com",
  "servicePath": "",
  "parameters": {
    "upload_protocol": {
      "location": "query",
      "type": "string",
      "description": "Upload protocol for media (e.g. \"raw\", \"multipart\")."
    },
    "fields": {
      "type": "string",
      "location": "query",
      "description": "Selector specifying which fields to include in a partial response."
    },
    "oauth_token": {
      "description": "OAuth 2.0 token for the current user.",
      "type": "string",
      "location": "query"
    },
    "prettyPrint": {
      "type": "boolean",
      "location": "query",
      "description": "Returns response with indentations and line breaks.",
      "default": "true"
    },
    "uploadType": {
      "location": "query",
      "type": "string",
      "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\")."
    },
    "quotaUser": {
      "type": "string",
      "location": "query",
      "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters."
    },
    "alt": {
      "enum": [
        "json",
        "media",
        "proto"
      ],
      "description": "Data format for response.",
      "default": "json",
      "type": "string",
      "enumDescriptions": [
        "Responses with Content-Type of application/json",
        "Media download with context-dependent Content-Type",
        "Responses with Content-Type of application/x-protobuf"
      ],
      "location": "query"
    },
    "$.xgafv": {
      "enum": [
        "1",
        "2"
      ],
      "description": "V1 error format.",
      "type": "string",
      "enumDescriptions": [
        "v1 error format",
        "v2 error format"
      ],
      "location": "query"
    },
    "access_token": {
      "description": "OAuth access token.",
      "location": "query",
      "type": "string"
    },
    "callback": {
      "type": "string",
      "location": "query",
      "description": "JSONP"
    },
    "key": {
      "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.",
      "type": "string",
      "location": "query"
    }
  },
  "revision": "20260713",
  "rootUrl": "https://keep.googleapis.com/",
  "kind": "discovery#restDescription",
  "protocol": "rest",
  "auth": {
    "oauth2": {
      "scopes": {
        "https://www.googleapis.com/auth/keep": {
          "description": "See, edit, create and permanently delete all your Google Keep data"
        },
        "https://www.googleapis.com/auth/keep.readonly": {
          "description": "View all your Google Keep data"
        }
      }
    }
  },
  "mtlsRootUrl": "https://keep.mtls.googleapis.com/",
  "name": "keep",
  "title": "Google Keep API",
  "schemas": {
    "ListContent": {
      "id": "ListContent",
      "type": "object",
      "properties": {
        "listItems": {
          "description": "The items in the list. The number of items must be less than 1,000.",
          "items": {
            "$ref": "ListItem"
          },
          "type": "array"
        }
      },
      "description": "The list of items for a single list note."
    },
    "BatchCreatePermissionsResponse": {
      "description": "The response for creating permissions on a note.",
      "type": "object",
      "properties": {
        "permissions": {
          "description": "Permissions created.",
          "type": "array",
          "items": {
            "$ref": "Permission"
          }
        }
      },
      "id": "BatchCreatePermissionsResponse"
    },
    "Permission": {
      "id": "Permission",
      "type": "object",
      "properties": {
        "user": {
          "$ref": "User",
          "description": "Output only. The user to whom this role applies.",
          "readOnly": true
        },
        "deleted": {
          "readOnly": true,
          "type": "boolean",
          "description": "Output only. Whether this member has been deleted. If the member is recovered, this value is set to false and the recovered member retains the role on the note."
        },
        "name": {
          "readOnly": true,
          "type": "string",
          "description": "Output only. The resource name."
        },
        "role": {
          "type": "string",
          "enumDescriptions": [
            "An undefined role.",
            "A role granting full access. This role cannot be added or removed. Defined by the creator of the note.",
            "A role granting the ability to contribute content and modify note permissions."
          ],
          "enum": [
            "ROLE_UNSPECIFIED",
            "OWNER",
            "WRITER"
          ],
          "description": "The role granted by this permission. The role determines the entity’s ability to read, write, and share notes."
        },
        "group": {
          "readOnly": true,
          "description": "Output only. The group to which this role applies.",
          "$ref": "Group"
        },
        "email": {
          "description": "The email associated with the member. If set on create, the `email` field in the `User` or `Group` message must either be empty or match this field. On read, may be unset if the member does not have an associated email.",
          "type": "string"
        },
        "family": {
          "description": "Output only. The Google Family to which this role applies.",
          "$ref": "Family",
          "readOnly": true
        }
      },
      "description": "A single permission on the note. Associates a `member` with a `role`."
    },
    "Note": {
      "description": "A single note.",
      "type": "object",
      "properties": {
        "trashed": {
          "description": "Output only. `true` if this note has been trashed. If trashed, the note is eventually deleted.",
          "readOnly": true,
          "type": "boolean"
        },
        "body": {
          "description": "The body of the note.",
          "$ref": "Section"
        },
        "trashTime": {
          "readOnly": true,
          "type": "string",
          "format": "google-datetime",
          "description": "Output only. When this note was trashed. If `trashed`, the note is eventually deleted. If the note is not trashed, this field is not set (and the trashed field is `false`)."
        },
        "updateTime": {
          "description": "Output only. When this note was last modified.",
          "format": "google-datetime",
          "readOnly": true,
          "type": "string"
        },
        "createTime": {
          "description": "Output only. When this note was created.",
          "format": "google-datetime",
          "readOnly": true,
          "type": "string"
        },
        "permissions": {
          "readOnly": true,
          "type": "array",
          "items": {
            "$ref": "Permission"
          },
          "description": "Output only. The list of permissions set on the note. Contains at least one entry for the note owner."
        },
        "name": {
          "description": "Output only. The resource name of this note. See general note on identifiers in KeepService.",
          "readOnly": true,
          "type": "string"
        },
        "attachments": {
          "description": "Output only. The attachments attached to this note.",
          "items": {
            "$ref": "Attachment"
          },
          "readOnly": true,
          "type": "array"
        },
        "title": {
          "description": "The title of the note. Length must be less than 1,000 characters.",
          "type": "string"
        }
      },
      "id": "Note"
    },
    "ListItem": {
      "description": "A single list item in a note's list.",
      "type": "object",
      "properties": {
        "text": {
          "$ref": "TextContent",
          "description": "The text of this item. Length must be less than 1,000 characters."
        },
        "checked": {
          "description": "Whether this item has been checked off or not.",
          "type": "boolean"
        },
        "childListItems": {
          "description": "If set, list of list items nested under this list item. Only one level of nesting is allowed.",
          "type": "array",
          "items": {
            "$ref": "ListItem"
          }
        }
      },
      "id": "ListItem"
    },
    "Group": {
      "id": "Group",
      "type": "object",
      "properties": {
        "email": {
          "type": "string",
          "description": "The group email."
        }
      },
      "description": "Describes a single Group."
    },
    "BatchDeletePermissionsRequest": {
      "description": "The request to remove one or more permissions from a note. A permission with the `OWNER` role can't be removed. If removing a permission fails, then the entire request fails and no changes are made. Returns a 400 bad request error if a specified permission does not exist on the note.",
      "type": "object",
      "properties": {
        "names": {
          "items": {
            "type": "string"
          },
          "type": "array",
          "description": "Required. The names of the permissions to delete. Format: `notes/{note}/permissions/{permission}`"
        }
      },
      "id": "BatchDeletePermissionsRequest"
    },
    "Family": {
      "description": "Describes a single Google Family.",
      "id": "Family",
      "type": "object",
      "properties": {}
    },
    "TextContent": {
      "description": "The block of text for a single text section or list item.",
      "id": "TextContent",
      "type": "object",
      "properties": {
        "text": {
          "type": "string",
          "description": "The text of the note. The limits on this vary with the specific field using this type."
        }
      }
    },
    "ListNotesResponse": {
      "type": "object",
      "properties": {
        "notes": {
          "items": {
            "$ref": "Note"
          },
          "type": "array",
          "description": "A page of notes."
        },
        "nextPageToken": {
          "type": "string",
          "description": "Next page's `page_token` field."
        }
      },
      "id": "ListNotesResponse",
      "description": "The response when listing a page of notes."
    },
    "CreatePermissionRequest": {
      "description": "The request to add a single permission on the note.",
      "type": "object",
      "properties": {
        "parent": {
          "type": "string",
          "description": "Required. The parent note where this permission will be created. Format: `notes/{note}`"
        },
        "permission": {
          "$ref": "Permission",
          "description": "Required. The permission to create. One of Permission.email, User.email or Group.email must be supplied."
        }
      },
      "id": "CreatePermissionRequest"
    },
    "BatchCreatePermissionsRequest": {
      "description": "The request to add one or more permissions on the note. Currently, only the `WRITER` role may be specified. If adding a permission fails, then the entire request fails and no changes are made.",
      "type": "object",
      "properties": {
        "requests": {
          "description": "The request message specifying the resources to create.",
          "type": "array",
          "items": {
            "$ref": "CreatePermissionRequest"
          }
        }
      },
      "id": "BatchCreatePermissionsRequest"
    },
    "Empty": {
      "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }",
      "type": "object",
      "properties": {},
      "id": "Empty"
    },
    "Attachment": {
      "type": "object",
      "properties": {
        "name": {
          "description": "The resource name;",
          "type": "string"
        },
        "mimeType": {
          "description": "The MIME types (IANA media types) in which the attachment is available.",
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "id": "Attachment",
      "description": "An attachment to a note."
    },
    "User": {
      "id": "User",
      "type": "object",
      "properties": {
        "email": {
          "description": "The user's email.",
          "type": "string"
        }
      },
      "description": "Describes a single user."
    },
    "Section": {
      "type": "object",
      "properties": {
        "text": {
          "description": "Used if this section's content is a block of text. The length of the text content must be less than 20,000 characters.",
          "$ref": "TextContent"
        },
        "list": {
          "description": "Used if this section's content is a list.",
          "$ref": "ListContent"
        }
      },
      "id": "Section",
      "description": "The content of the note."
    }
  },
  "description": "The Google Keep API is used in an enterprise environment to manage Google Keep content and resolve issues identified by cloud security software.",
  "ownerName": "Google",
  "baseUrl": "https://keep.googleapis.com/",
  "fullyEncodeReservedExpansion": true,
  "batchPath": "batch",
  "resources": {
    "notes": {
      "resources": {
        "permissions": {
          "methods": {
            "batchCreate": {
              "httpMethod": "POST",
              "scopes": [
                "https://www.googleapis.com/auth/keep"
              ],
              "description": "Creates one or more permissions on the note. Only permissions with the `WRITER` role may be created. If adding any permission fails, then the entire request fails and no changes are made.",
              "request": {
                "$ref": "BatchCreatePermissionsRequest"
              },
              "id": "keep.notes.permissions.batchCreate",
              "path": "v1/{+parent}/permissions:batchCreate",
              "parameterOrder": [
                "parent"
              ],
              "flatPath": "v1/notes/{notesId}/permissions:batchCreate",
              "parameters": {
                "parent": {
                  "type": "string",
                  "location": "path",
                  "description": "The parent resource shared by all Permissions being created. Format: `notes/{note}` If this is set, the parent field in the CreatePermission messages must either be empty or match this field.",
                  "pattern": "^notes/[^/]+$",
                  "required": true
                }
              },
              "response": {
                "$ref": "BatchCreatePermissionsResponse"
              }
            },
            "batchDelete": {
              "flatPath": "v1/notes/{notesId}/permissions:batchDelete",
              "parameters": {
                "parent": {
                  "type": "string",
                  "location": "path",
                  "description": "The parent resource shared by all permissions being deleted. Format: `notes/{note}` If this is set, the parent of all of the permissions specified in the DeletePermissionRequest messages must match this field.",
                  "pattern": "^notes/[^/]+$",
                  "required": true
                }
              },
              "parameterOrder": [
                "parent"
              ],
              "request": {
                "$ref": "BatchDeletePermissionsRequest"
              },
              "id": "keep.notes.permissions.batchDelete",
              "path": "v1/{+parent}/permissions:batchDelete",
              "httpMethod": "POST",
              "scopes": [
                "https://www.googleapis.com/auth/keep"
              ],
              "description": "Deletes one or more permissions on the note. The specified entities will immediately lose access. A permission with the `OWNER` role can't be removed. If removing a permission fails, then the entire request fails and no changes are made. Returns a 400 bad request error if a specified permission does not exist on the note.",
              "response": {
                "$ref": "Empty"
              }
            }
          }
        }
      },
      "methods": {
        "create": {
          "response": {
            "$ref": "Note"
          },
          "id": "keep.notes.create",
          "path": "v1/notes",
          "request": {
            "$ref": "Note"
          },
          "description": "Creates a new note.",
          "httpMethod": "POST",
          "scopes": [
            "https://www.googleapis.com/auth/keep"
          ],
          "flatPath": "v1/notes",
          "parameters": {},
          "parameterOrder": []
        },
        "get": {
          "response": {
            "$ref": "Note"
          },
          "id": "keep.notes.get",
          "path": "v1/{+name}",
          "httpMethod": "GET",
          "scopes": [
            "https://www.googleapis.com/auth/keep",
            "https://www.googleapis.com/auth/keep.readonly"
          ],
          "description": "Gets a note.",
          "flatPath": "v1/notes/{notesId}",
          "parameters": {
            "name": {
              "description": "Required. Name of the resource.",
              "location": "path",
              "type": "string",
              "required": true,
              "pattern": "^notes/[^/]+$"
            }
          },
          "parameterOrder": [
            "name"
          ]
        },
        "list": {
          "id": "keep.notes.list",
          "path": "v1/notes",
          "description": "Lists notes. Every list call returns a page of results with `page_size` as the upper bound of returned items. A `page_size` of zero allows the server to choose the upper bound. The ListNotesResponse contains at most `page_size` entries. If there are more things left to list, it provides a `next_page_token` value. (Page tokens are opaque values.) To get the next page of results, copy the result's `next_page_token` into the next request's `page_token`. Repeat until the `next_page_token` returned with a page of results is empty. ListNotes return consistent results in the face of concurrent changes, or signals that it cannot with an ABORTED error.",
          "httpMethod": "GET",
          "scopes": [
            "https://www.googleapis.com/auth/keep",
            "https://www.googleapis.com/auth/keep.readonly"
          ],
          "flatPath": "v1/notes",
          "parameters": {
            "pageSize": {
              "type": "integer",
              "location": "query",
              "format": "int32",
              "description": "The maximum number of results to return."
            },
            "filter": {
              "type": "string",
              "location": "query",
              "description": "Filter for list results. If no filter is supplied, the `trashed` filter is applied by default. Valid fields to filter by are: `create_time`, `update_time`, `trash_time`, and `trashed`. Filter syntax follows the [Google AIP filtering spec](https://aip.dev/160)."
            },
            "pageToken": {
              "location": "query",
              "type": "string",
              "description": "The previous page's `next_page_token` field."
            }
          },
          "parameterOrder": [],
          "response": {
            "$ref": "ListNotesResponse"
          }
        },
        "delete": {
          "description": "Deletes a note. Caller must have the `OWNER` role on the note to delete. Deleting a note removes the resource immediately and cannot be undone. Any collaborators will lose access to the note.",
          "httpMethod": "DELETE",
          "scopes": [
            "https://www.googleapis.com/auth/keep"
          ],
          "id": "keep.notes.delete",
          "path": "v1/{+name}",
          "parameterOrder": [
            "name"
          ],
          "flatPath": "v1/notes/{notesId}",
          "parameters": {
            "name": {
              "required": true,
              "pattern": "^notes/[^/]+$",
              "description": "Required. Name of the note to delete.",
              "type": "string",
              "location": "path"
            }
          },
          "response": {
            "$ref": "Empty"
          }
        }
      }
    },
    "media": {
      "methods": {
        "download": {
          "description": "Gets an attachment. To download attachment media via REST requires the alt=media query parameter. Returns a 400 bad request error if attachment media is not available in the requested MIME type.",
          "httpMethod": "GET",
          "supportsMediaDownload": true,
          "scopes": [
            "https://www.googleapis.com/auth/keep",
            "https://www.googleapis.com/auth/keep.readonly"
          ],
          "id": "keep.media.download",
          "path": "v1/{+name}",
          "parameterOrder": [
            "name"
          ],
          "flatPath": "v1/notes/{notesId}/attachments/{attachmentsId}",
          "parameters": {
            "name": {
              "pattern": "^notes/[^/]+/attachments/[^/]+$",
              "required": true,
              "type": "string",
              "location": "path",
              "description": "Required. The name of the attachment."
            },
            "mimeType": {
              "description": "The IANA MIME type format requested. The requested MIME type must be one specified in the attachment.mime_type. Required when downloading attachment media and ignored otherwise.",
              "type": "string",
              "location": "query"
            }
          },
          "useMediaDownloadService": true,
          "response": {
            "$ref": "Attachment"
          }
        }
      }
    }
  },
  "version": "v1",
  "id": "keep:v1",
  "canonicalName": "Keep"
}
