On Tue, Aug 22, 2017 at 8:38 AM, Maria Julia Lima <[email protected]> wrote:
> Hi, Min. Thanks for your reply. > > I have tried the endpoints of 0.7.2, but the problem was the same. For > example: > > curl -H "Authorization: Token 057d0e5a8a1b4190895834c6ad6ec01f" -H > "Content-Type: application/json" -XGET http://localhost:8001/hub/api/info > > > curl -H "Authorization: Token 057d0e5a8a1b4190895834c6ad6ec01f" -H > "Content-Type: application/json" -XGET http://localhost:8001/hub/api/users > > > > All the requests answers 404 Not Found error. > > > Is there anything else that I need to check? > > It looks like you are hitting port 8001. This is typically the internal API port of the proxy, not the Hub, so I would expect 404 there. Have you tried accessing port 8000, or the public port of the proxy if you have changed it with `JupyterHub.port`? You can also access the Hub at port 8081, if the default ports are in use. -Min > I am using my own customized Authenticator and the Docker Spawner, but I > don't suppose that it could be the problem. > > > Julia > > Em terça-feira, 22 de agosto de 2017 03:52:45 UTC-3, Min RK escreveu: >> >> You aren’t doing anything wrong, *but* the root /hub/api/ endpoint is >> new in 0.8. You’ll have to hit something like /hub/api/users in 0.7.2. >> You can use the 0.7.2 version of the REST API docs >> <https://jupyterhub.readthedocs.io/en/0.7.2/_static/rest-api/index.html> >> to make sure you don’t get misled. >> >> -Min >> >> >> On Mon, Aug 21, 2017 at 10:50 PM, Maria Julia Lima <[email protected]> >> wrote: >> >>> Hi >>> >>> Certainly, I should be doing something wrong, but I can not access the >>> REST API of jupyterhub. I am using the version 0.7.2 and the following >>> configuration: >>> >>> c.Authenticator.admin_users = {'admin', 'mjulia'} >>> c.JupyterHub.api_tokens = { >>> '057d0e5a8a1b4190895834c6ad6ec01f': 'admin', >>> } >>> >>> I get 404 error when I try to call any API request. For example: >>> >>> curl -H "Authorization: Token 057d0e5a8a1b4190895834c6ad6ec01f" -H >>> "Content-Type: application/json" -XGET http://loc01/hub/api/ >>> >>> >>> I am testing in my own machine. >>> Is there some missing configuration or am I doing something wrong? >>> >>> Thanks in advance. >>> >>> -- Julia >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "Project Jupyter" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to [email protected]. >>> To post to this group, send email to [email protected]. >>> To view this discussion on the web visit https://groups.google.com/d/ms >>> gid/jupyter/253cc9b4-4f9f-4183-965f-36cbdff2a906%40googlegroups.com >>> <https://groups.google.com/d/msgid/jupyter/253cc9b4-4f9f-4183-965f-36cbdff2a906%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- > You received this message because you are subscribed to the Google Groups > "Project Jupyter" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/jupyter/8a006424-b669-4404-b832-fccafc5bd3f0%40googlegroups.com > <https://groups.google.com/d/msgid/jupyter/8a006424-b669-4404-b832-fccafc5bd3f0%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Project Jupyter" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jupyter/CAHNn8BXi2U0F2ki7C1tqFPnFe5su11CTqGbJtU3VUukLu8q93g%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
