[microgateway configure] Error: HTTP error 401

brianademba
Participant II

I am trying to configure Edge Microgateway on my local Windows with my free Apigee account. I get the HTTP error 401 despite using the correct Apigee password.

C:\Users\XXX>edgemicro configure -o xxxxx-eval -e prod -u xxxxx@gmail.com -r https://xxxxx-eval-prod.apigee.net

2021-01-27T18:16:15.350Z [44220] [microgateway edgemicro] current nodejs version is v12.14.1
2021-01-27T18:16:15.354Z [44220] [microgateway edgemicro] current edgemicro version is 3.2.0
password:
2021-01-27T18:16:26.066Z [44220] [microgateway-config io] file doesn't exist, setting up
2021-01-27T18:16:27.128Z [44220] [microgateway configure] Error: HTTP error 401

at Request._callback (C:\Users\XXX\AppData\Roaming\npm\node_modules\edgemicro\node_modules\apigeetool\lib\commands\listdeployments.js:93:12)
at Request.self.callback (C:\Users\XXX\AppData\Roaming\npm\node_modules\edgemicro\node_modules\request\request.js:185:22)
at Request.emit (events.js:223:5)
at Request.<anonymous> (C:\Users\XXX\AppData\Roaming\npm\node_modules\edgemicro\node_modules\request\request.js:1154:10)
at Request.emit (events.js:223:5)
at IncomingMessage.<anonymous> (C:\Users\XXX\AppData\Roaming\npm\node_modules\edgemicro\node_modules\request\request.js:1076:12)
at Object.onceWrapper (events.js:312:28)
at IncomingMessage.emit (events.js:228:7)
at endReadableNT (_stream_readable.js:1185:12)
at processTicksAndRejections (internal/process/task_queues.js:81:21)

0 2 270
2 REPLIES 2

brianademba
Participant II

I realised it was not possible to connect to configure my free account with my local machine. Instead I confired it with on prem installation.

I got the information here. Also you can refer to Apigee docs too

brianademba
Participant II

I have managed to execute the command to private cloud installation. However I cannot see the client key and secret:

edgemicro private configure -o xxx -e prod -u xxxxxx -p xxxxxx -r http://xx.xx.x.xx:9001 -m http://xxx.xx.xxx.xx:8080 -v default
2021-01-28T09:04:10.266Z [22344] [microgateway edgemicro] current nodejs version is v12.14.1
2021-01-28T09:04:10.271Z [22344] [microgateway edgemicro] current edgemicro version is 3.2.0
2021-01-28T09:04:14.909Z [57868] [microgateway private] delete cache config
2021-01-28T09:04:14.914Z [57868] [microgateway private] deleted C:\Users\XXX\.edgemicro\xxx-prod-config.yaml
2021-01-28T09:04:14.922Z [57868] [microgateway private] init config
2021-01-28T09:04:14.926Z [57868] [microgateway-config io] file doesn't exist, setting up
2021-01-28T09:04:16.659Z [57868] [microgateway private] Proxy edgemicro-internal is already deployed
2021-01-28T09:04:16.666Z [57868] [microgateway private] edgemicro-auth is already deployed
2021-01-28T09:04:16.671Z [57868] [microgateway private] checking org for existing KVM
2021-01-28T09:04:16.929Z [57868] [microgateway private] error checking for cert. Installing new cert.
2021-01-28T09:04:17.981Z [57868] [microgateway cert lib] creating KVM
2021-01-28T09:04:17.983Z [57868] [microgateway cert lib] adding private_key
2021-01-28T09:04:17.985Z [57868] [microgateway cert lib] adding public_key
2021-01-28T09:04:18.526Z [57868] [microgateway private] generating keys
2021-01-28T09:04:19.255Z [57868] [microgateway private] invalid response from region api http://xxx.xxx.x.xx:9001/edgemicro/region/organization/xxx/environment/prod undefined
2021-01-28T09:04:19.267Z [57868] []
2021-01-28T09:04:19.272Z [57868] [microgateway private] saving configuration information to: C:\Users\XXXX\.edgemicro\xxx-prod-config.yaml
2021-01-28T09:04:19.289Z [57868] []
2021-01-28T09:04:19.295Z [57868] [microgateway private] edgemicro configuration complete!

Can someone help. I am unable to proceed as I cannot verify my Microgateway installation without key and secret.I am using Windows.