We’re overhauling Dgraph’s docs to make them clearer and more approachable. If
you notice any issues during this transition or have suggestions, please
let us know.
Dropping data programmatically
You can drop data by invoking thedropData
mutation on /admin/slash
endpoint.
As an example, if your GraphQL endpoint is https://<your-backend>/graphql
,
then the admin endpoint for schema is at https://<your-backend>/admin/slash
.
This endpoint requires authentication.
Here is curl example.
allDataAndSchema
flag.
Self-managed
Drop data and schema
The/alter
endpoint is used to drop data.
To drop all data and schema:
/alter
endpoint can also be used to drop a specific property or all nodes
of a specific type.
To drop property name
:
Film
: