From 69bcb52eb6e8c42e6384a75db116609c5ed0d49d Mon Sep 17 00:00:00 2001 From: Doug Allrich Date: Wed, 14 Oct 2020 21:00:46 -0500 Subject: [PATCH] Add a remove configuration section Fixes #6941 --- _includes/graphql/customisation.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/_includes/graphql/customisation.md b/_includes/graphql/customisation.md index 82bc52a6b..944314315 100644 --- a/_includes/graphql/customisation.md +++ b/_includes/graphql/customisation.md @@ -288,6 +288,22 @@ You can optionally override the default generated mutation names with aliases: } ``` +### Remove Configuration + +Deploying a custom configuration via `setGraphQLConfig` persists the changes into the database. As a result, simply deleting a configuration change and deploying again does not result in a default Parse GraphQL configuration. The configuration changes remain. + +To remove a configuration, set the affected properties to `null` or `undefined` before deploying. The default Parse GraphQL configuration for those properties will be restored. + +```js +{ + "enabledForClasses": undefined, + "disabledForClasses": undefined, + "classConfigs": undefined, +} +``` + +Once a default configuration is restored, you can safely remove any unused configuration changes from your `parseGraphQLServer` setup. + ## Cloud Code Resolvers The Parse GraphQL API supports the use of custom user-defined schema. The [Adding Custom Schema](#adding-custom-schema) section explains how to get started using this feature.