# Error updating schema with @custom directive

**URL:** <https://discuss.dgraph.io/t/error-updating-schema-with-custom-directive/9715>\
**Category:** GraphQL\
**Created:** [August 28, 2020, 3:03am UTC](https://discuss.dgraph.io/t/error-updating-schema-with-custom-directive/9715 "2020-08-28T03:03:32Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![amaster507](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/amaster507/32/4123_2.png) [@amaster507](https://discuss.dgraph.io/u/amaster507)\
**Post date:** [August 28, 2020, 4:10am UTC](https://discuss.dgraph.io/t/error-updating-schema-with-custom-directive/9715/4 "2020-08-28T04:10:29Z")

</div>

Slash has a little better error handling:

> resolving updateGQLSchema failed because input:601: Type Mutation; Field editUser; body template inside @custom directive could not be parsed.  
> input:607: Type Mutation; Field removeUser; body template inside @custom directive could not be parsed.

This is interesting. Not sure why it would allow your createUser to go through seemingly without error, but error parsing your editUser and removeUser.

This was a long shot, but I actually resolved out why. Not that I think it is correct, but that it is a Dgraph bug/restriction.

Your body for editUser and removeUser both contain this snippet:

```auto
auth0ID: $auth0ID

```

I was able to receive a successful parse by using instead:

```auto
authID: $auth0ID

```

I believe that numbers are allowable in property names in JSON.

The problem was identified here:

> [@@custom mutation: underscores within POST body](http://discuss.hypermode.com/t/custom-mutation-underscores-within-post-body/8622/2):
>
> Thanks, This is a limitation currently. At present, only [a-zA-Z] is supported as the character set for keys in body. We should expand it to accept general things like underscores, hyphens or basically any character that one may use in json keys.

But was should now be resolved as also noted on that same thread:

> [@@custom mutation: underscores within POST body](http://discuss.hypermode.com/t/custom-mutation-underscores-within-post-body/8622/4):
>
> Hey @miko, This has been added in master with [this PR](https://github.com/dgraph-io/dgraph/pull/6157). Note that now the character set for keys in body is /[\_A-Za-z][\_0-9A-Za-z]\*/ which is same as the character set for names in GraphQL spec. Closing this topic. Thanks

It was committed here:

[https://github.com/dgraph-io/dgraph/commit/02820c8921a3a954880505c18cc5f0c875168b9a](https://github.com/dgraph-io/dgraph/commit/02820c8921a3a954880505c18cc5f0c875168b9a)

And can be seen inside version 20.07.1-rc1 here:

> **[Commits · dgraph-io/dgraph](https://github.com/dgraph-io/dgraph/commits/v20.07.1-rc1)**
>
> The high-performance database for modern applications - Commits · dgraph-io/dgraph

Which version are you running?

---

_[View the full topic](https://discuss.dgraph.io/t/error-updating-schema-with-custom-directive/9715)._
