23

I saw clientMutationId field in example-strong-typing documentation.

mutation {
 addComment(input:{clientMutationId: 1234, subjectId: "MDA6SXNzdWUyMjcyMDA2MTT=", body: "Looks good to me!"}) {
 clientMutationId
 commentEdge {
 node {
 body
 repository {
 id
 name
 nameWithOwner
 }
 issue {
 number
 }
 }
 }
 }
}

what does clientMutationId mean? How can I generate it?

asked Jul 12, 2018 at 10:40

1 Answer 1

27

clientMutationId is not directly related with GraphQL but it is with graphql-relay.

Check Understanding Relay Mutations for a better explanation.

clientMutationId. This ID is generated by the Relay client behind the scenes to track the mutation's progress.

answered Jul 16, 2018 at 13:31
Sign up to request clarification or add additional context in comments.

1 Comment

Also note, it's optional. Personally wasn't sure if it was required at first.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.