Skip to content

Should retry on 4401 #559

Answered by enisdenjo
pederbl asked this question in Q&A
May 19, 2024 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

Hey there! The close code 4401 indicates that the client tried subscribing before the handshake's finished (before receiving a ConnectionAck message), meaning there's something wrong with the implementation of the client and should therefore not be retried.

Executing operations is allowed only after the server has acknowledged the connection through the ConnectionAck message, if the connection is not acknowledged, the socket will be closed immediately with the event 4401: Unauthorized.

GraphQL over WebSocket spec

You may be confusing 4401 (Unauthorized) with 4403 (Forbidden), where the latter means that the implementation is OK but the user is not allowed to do something.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@pederbl
Comment options

Answer selected by pederbl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #558 on May 20, 2024 12:16.