Question

Why Receiving StatusCode 401 in creating API user ?

  • 25 March 2024
  • 5 replies
  • 35 views

I’m in Benin, and searching through these pages, i have no answer. Can somebody help me. I got 401 even though i submitted the right suscription key.

{
"statusCode": 401,
"message": "Access denied due to invalid subscription key. Make sure to provide a valid key for an active subscription."
}

 


5 replies

Userlevel 2

ITs better you share the request code too so we can understand whcih subscriptiion key you submitted, and which endpoint you are trying to request.
Thank you.

Thank you so mush @crankluga , I’m using postman to contact MTN API, the suscription key i’m using is the one i get from suscribing to collection product. But still getting same result in postman. I then used the one got from Disbursement product and it worked, so my my question, doesn’t it matter the suscription key i used, can i use disbursement key to access collection product without problem in the future ?

Userlevel 2

I think maybe you intermixed / interchanged those subscription keys somewhere for sure.

Oh God, MTN why don't you fix this bug for good. Seeing all the compiling complaints from developers and still haven't come up with an eventual solution.

I also added the right credentials to create the API USER but still encountering 401 😠😠 regenerated the key even the UUID but still denies me access 401

Userlevel 2

You are going to recreate the APIUSER and API KEy following the  link i have shared,,
there must be something small u are missing, 
kindly get but to us with your success or errror.
 

 

Reply