Howtographql: Error: Argument id for data.postedBy.connect.id must not be null. Please use undefined instead.

Created on 7 Dec 2020  路  7Comments  路  Source: howtographql/howtographql

Hi!

I'm attempting to run the two GraphQL mutations specified at the end of the this article: https://www.howtographql.com/react-apollo/1-getting-started/, but after following every step in the above, I'm getting this error that Googling has turned up blank for.

Does anyone know what's going on here?

Screen Shot 2020-12-06 at 9 52 13 PM

Most helpful comment

I was able to get them to run by signing up and logging in.

To sign up (fill in your email, password, and name):

mutation SignUp {
    signup(
        email: ""
        password: ""
        name: ""
    ) {
        token
    }
}

Take that token and put it into the HTTP Headers section at the bottom like:

{
    "authorization": "Bearer <paste token here>"
}

All 7 comments

I'm experiencing the same issue.

I was able to get them to run by signing up and logging in.

To sign up (fill in your email, password, and name):

mutation SignUp {
    signup(
        email: ""
        password: ""
        name: ""
    ) {
        token
    }
}

Take that token and put it into the HTTP Headers section at the bottom like:

{
    "authorization": "Bearer <paste token here>"
}

I was having the same issue, @nataliegirard solution solved it, thanks!

Thanks @nataliegirard for the solution.

I did what @nataliegirard said but when I put the authorization on HTTP header I got server error 500, if I delete from the HTTP header the server come back instantly but with the very same first error.

image

any suggestions?

I did what @nataliegirard said but when I put the authorization on HTTP header I got server error 500, if I delete from the HTTP header the server come back instantly but with the very same first error.

image

any suggestions?

I found the issue, I forget to delete the "<" and ">" from the token, now it works properly, thank you.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Tankerxyz picture Tankerxyz  路  7Comments

ohmoses picture ohmoses  路  6Comments

cmarchena picture cmarchena  路  3Comments

swcarlosrj picture swcarlosrj  路  3Comments

christiaan-janssen picture christiaan-janssen  路  6Comments