Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customization of JSONWebTokenMixin field names #275

Open
Koldar opened this issue Jul 7, 2021 · 0 comments
Open

Customization of JSONWebTokenMixin field names #275

Koldar opened this issue Jul 7, 2021 · 0 comments

Comments

@Koldar
Copy link

Koldar commented Jul 7, 2021

Hi,

loving this library. I'm using it in combination with federations, where multiple services (one per subgraph) authenticate using this library. However, during the merge of the subgraphs, the Apollo gateway complains about:

Field "Mutation.payload" can only be defined once.
Field "Mutation.refreshExpiresIn" can only be defined once.
Field "Mutation.user" can only be defined once.

It makes sense (at least to me), since the there are 2 mutations ObtainJSONWebToken in 2 different subgraphs that are merged together: when merging the output values have the same name, hence the error.

I don't know if this is the correct approach (I'm still a newbie); however, I feel like it should be possible to customize the output name of the ObtainJSONWebToken mutation. I'd be happy to create a pull request about this fix, however if, possible, it would be awesome if you could tell me if this feature is easy to do of if there are some challenges generated by how the library work right now.

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant