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

Bad Request - Invalid Hostname #124

josephfo opened this issue Jul 28, 2019 · 2 comments


Copy link

commented Jul 28, 2019

After setting up my smee channel, I'm using this command line:
smee -u -t https://localhost:44359/api/issues

I have an ASPNet Core WebApi controller running locally on port 44359 - that I want to handle these requests coming from smee.

I'm sure it's something on my side, but hoping someone can let me know what I'm doing wrong.

I updated smee index.js to echo out the request object, and I see the POST is being made to https://localhost:44359/api/issues (see below). If I make this same POST request using fiddler, my breakpoint is hit in the ASPNet Core controller - which is the desired behavior. But when smee makes the request, I see this error:

         '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""">\r\n<HTML><HEAD><TITLE>Bad Request</TITLE>\r\n<META HTTP-EQUIV="Content-Type" Content="text/html; charset=us-ascii"></HEAD>\r\n<BODY><h2>Bad Request - Invalid Hostname</h2>\r\n<hr><p>HTTP Error 400. The request hostname is invalid.</p>\r\n</BODY></HTML>\r\n' },

Full smee output attached.

Request {
  _events: {},
  _eventsCount: 0,
  _maxListeners: undefined,
  _agent: false,
  _formData: null,
  method: 'POST',
  url: 'https://localhost:44359/api/issues',
   { 'user-agent': 'GitHub-Hookshot/20c7c42',
     'content-type': 'application/json',
     host: '',
     connection: 'close',
     accept: '*/*',

This comment has been minimized.

Copy link

commented Jul 28, 2019

Issue Label Bot is not confident enough to auto-label this issue. See dashboard for more details.


This comment has been minimized.

Copy link

commented Jul 30, 2019

If you are running on localhost
smee --url --path /github-webhook/ --port 44359

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.