instructure / canvas-lms

The open LMS by Instructure, Inc.
https://github.com/instructure/canvas-lms/wiki
GNU Affero General Public License v3.0
5.42k stars 2.42k forks source link

ERR_CONNECTION_REFUSED #2232

Open AkshayTembhekar21 opened 12 months ago

AkshayTembhekar21 commented 12 months ago

Summary:

This is for the first time I am trying to work on canvas LMS and I am stuck on step 1 of canvas LMS OAuth. l have client id and secret key. Using postman I am doing this. https://sandbox/login/oauth2/auth?client_id=MY_CLIENT_ID&response_type=code&redirect_uri=http://localhost:8080/welcome Instead getting redirected to the said uri I am getting an error. GET https://sandbox/login/oauth2/auth Error: connect ECONNREFUSED sandboxIP:PortNumber Request Headers User-Agent: PostmanRuntime/7.32.3 Accept: / Postman-Token:Some postman token Host: sandbox Accept-Encoding: gzip, deflate, br Connection: keep-alive

Steps to reproduce:

1. https://sandbox/login/oauth2/auth?client_id=MY_CLIENT_ID&response_type=code&redirect_uri=http://localhost:8080/welcome -> replace sandbox with your sandbox or by your canvas instance in postman. I tried the same using java code as well but getting the same error as connection refused. I have added http://localhost:8080/welcome in Developer keys -> redirect uris field.

Expected behavior:

Should get redirected to the redirect_uri

Actual behavior:

GET https://sandboxIP/login/oauth2/auth Error: connect ECONNREFUSED sandboxIP:PortNumber Request Headers User-Agent: PostmanRuntime/7.32.3 Accept: / Postman-Token:Some postman token Host: sandboxIP Accept-Encoding: gzip, deflate, br Connection: keep-alive

Additional notes: