Skip to content

List GDPR Requests

About

The gdprRequests query returns a paginated list of the authenticated customer's own GDPR data requests. Requests are always scoped to the logged-in customer — you can never see another customer's requests. Results are ordered newest first by default.

Authentication

This query requires an authenticated customer — send the storefront key and a customer Bearer token. See the Authentication page.

GDPR must be enabled

If GDPR data requests are disabled in the store's admin configuration, the query fails with the message "GDPR data requests are disabled. Please enable GDPR from the admin configuration." in errors[]. The feature has been turned off on the admin side.

Arguments

ArgumentTypeRequiredDescription
firstInt❌ NoNumber of items to return (forward pagination).
afterString❌ NoCursor for forward pagination. Use endCursor from a previous response.
lastInt❌ NoNumber of items for backward pagination.
beforeString❌ NoCursor for backward pagination. Use startCursor from a previous response.
sortString❌ NoSort column: id or created_at. Default id.
orderString❌ NoSort direction: asc or desc. Default desc.

Possible Returns

FieldTypeDescription
edges[GdprRequestEdge!]Array of request edges with cursor and node.
edges.cursorString!Cursor for this edge, used in pagination.
edges.nodeGdprRequest!The GDPR request object.
edges.node._idInt!Numeric request ID.
edges.node.typeString!Request type: delete or update.
edges.node.statusString!Request status: pending, processing, declined, approved, revoked.
edges.node.messageStringThe customer's message describing the request.
edges.node.emailString!Email address tied to the request.
edges.node.revokedAtDateTimeTimestamp when the request was revoked, or null.
edges.node.createdAtDateTime!Request creation timestamp.
edges.node.updatedAtDateTime!Request last update timestamp.
edges.node.customerCustomer!The customer who owns the request.
edges.node.customer._idInt!Numeric customer ID of the owner.
pageInfoPageInfo!Pagination metadata.
pageInfo.startCursorStringCursor for the first item in the page.
pageInfo.endCursorStringCursor for the last item in the page.
pageInfo.hasNextPageBoolean!Whether more pages exist forward.
pageInfo.hasPreviousPageBoolean!Whether more pages exist backward.
totalCountInt!Total number of the customer's requests.

Released under the MIT License.