News & Announcements User Community Developer Community

Welcome to the RingCentral Community

Please note the community is currently under maintenance and is read-only.

Search
Make sure to review our Terms of Use and Community Guidelines.
  Please note the community is currently under maintenance and is read-only.
Home » Developers
Password Flow - errorCode OAU-123 "Client authentication is required"
Tags: authentication
Aug 23, 2019 at 11:06am   •   1 replies  •  1 likes
ATT OFFICE AT HAND BILLING

I have followed the instructions for the Password Flow. Instead of receiving a token, I am receiving error OAU-123 "Client authentication is required."

I am using VBScript so I cannot use any of the provided libraries or examples.

I created a new application in the ringCentral console with the type of Server-only (No UI) and permissions of Read Accounts, SMS, and Webhook.

I have concatenated the app's client ID+":"+client secret, then encapsulated the entire string to base64.

authString=base64Encode(clientId+":"+clientSecret)

I am testing with the sandbox url "https://platform.devtest.ringcentral.com".

My endpoint is "/restapi/oauth/token".

I open an async POST to the url and endpoint.

objHttp.open |POST|, url+endpoint, async

I then set the following request headers.

objHttp.setRequestHeader "Accept", "application/json"
objHttp.setRequestHeader "Authorization", "Basic "+authString
objHttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded;charset=UTF-8"

I post the following data:

"grant_type=password&username="+userName+"&extension=101&password="+password

I get the following response:

{
"error" : "invalid_client",
"errors" : [ {
"errorCode" : "OAU-123",
"message" : "Client authentication is required"
} ],
"error_description" : "Client authentication is required"
}


I have verified that I am using the correct sandbox Client ID and Client Secret. I have tried resetting the user password. I have tried the user email address as the username, and the phone number with and without the leading "+", url encoded and clear. I always receive the same error.

Google searches for this exact wording have returned no results. Nor is this error listed in the RingCentral errors documentation. (https://ringcentral-faq.readthedocs.io/en/latest/errors/).

Any help would be appreciated.

1 Answer
answered on Aug 23, 2019 at 1:24pm  

I am not sure about vbScript but currently, I don't see any issue in your parameters and url to call OAuth token API, not sure about the code though. Maybe someone else here can help with the code

It may not be an issue from your side. I found something similar here:

https://forums.developers.ringcentral.com/questions/285/error-oau-123-authorization-header-is-not-specifie.html

Please check with the back-end support team once to make sure the issue is not from your side by submitting a help ticket.


 0
on Aug 26, 2019 at 6:08am   •  0 likes

Thank you for your reply. Using an API debugger (Runscope) I plugged in my code generated parameters and successfully received a token response. At this point I'm convinced that it is the Windows WinHttp object itself causing the issue. I have noticed that if I do not send an Authorization header at all, I get the same response. If I send an invalid Authorization header (just a few characters), then it produces a different error. This leads me to believe that it the Authorization header is not being attached. There may be an issue with the length or content of the authString. I will post any resolution if I find one.



A new Community is coming to RingCentral!

Posts are currently read-only as we transition into our new platform.

We thank you for your patience
during this downtime.

Try Workflow Builder

Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!

Try RingCentral Workflow Builder

PRODUCTS
RingEX
Message
Video
Phone
OPEN ECOSYSTEM
Developer Platform
APIs
Integrated Apps
App Gallery
Developer support
Games and rewards

RESOURCES
Resource center
Blog
Product Releases
Accessibility
QUICK LINKS
App Download
RingCentral App login
Admin Portal Login
Contact Sales
© 1999-2024 RingCentral, Inc. All rights reserved. Legal Privacy Notice Site Map Contact Us