Skip to content
gist.link ↗

nodes

Query Drive API — POST https://drive.api.gist.link/graphql

Paginated listing. Scope via filter: parentId — children of a folder rootOnly — caller’s My Drive roots sharedWithMe — items granted to the caller (or org-wide) starred — caller’s starred items recent — caller-visible files by last update trashed — caller’s trash (explicitly trashed roots) search/type/visibility — combinable refinements

drive:query:nodes

The calling IAM key must hold this permission (or a wildcard that covers it: drive:query:* or drive:*) and the access token must have been minted with audience=drive. See Permissions.

type Query {
nodes(filter: NodeFilter, sort: SortInput, first: Int, after: String): NodeConnection!
}
Argument Type Required Description
filter NodeFilter No —
sort SortInput No —
first Int No —
after String No —

NodeConnection! — see the Drive types reference.

Terminal window
curl https://drive.api.gist.link/graphql \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H 'Content-Type: application/json' \
-d @- <<'JSON'
{
"query": "query Nodes($filter: NodeFilter, $sort: SortInput, $first: Int, $after: String) { nodes(filter: $filter, sort: $sort, first: $first, after: $after) { totalCount edges { cursor node { id type name status } } } }",
"variables": {
"filter": {
"parentId": 10,
"rootOnly": true,
"sharedWithMe": true
},
"sort": {
"field": "example",
"direction": "example"
},
"first": 10,
"after": "cursor"
}
}
JSON