IEX API: Not a WebSocket handshake response.
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 6.1k
- Forks
- 1.7k
- PR merge metrics
- No merged PRs in 30d
Description
Just installed WebSocketSharp and checking it out first time. I am trying to access the IEX API: https://iextrading.com/developer/docs/ using this simple code from the example:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WebSocketSharp;
namespace ConsoleApp2
{
class Program
{
static void Main(string[] args)
{
using (var ws = new WebSocket("wss://ws-api.iextrading.com/1.0"))
{
ws.OnMessage += (sender, e) =>
Console.WriteLine("Data: " + e.Data);
ws.Connect();
Console.ReadKey(true);
}
}
}
}
However, I am getting: |Fatal|WebSocket.doHandshake|Not a WebSocket handshake response.
I've gotten it to run with Javascript, so I am not sure if there's a problem here with WebSocketSharp, or my method connecting to this API? Thanks!!
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the reported ConsoleApp2 example, the WebSocket constructor for wss://ws-api.iextrading.com/1.0, and the ws.Connect() call. Reproduce the handshake error and compare the request and response with the JavaScript client that reportedly works. Done means identifying whether the endpoint or WebSocketSharp produces the incompatible handshake and documenting a reproducible fix or limitation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- api, networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100