Add ORCID( to custom social connection

I put the required info into the page
Client ID
Client Secrete
Authorization URL:
Token URL:
Scope: openid or empty
Fetch user profile script
function(access_token, ctx, callback) {
request.get(‘’, {
‘headers’: {
‘Authorization’: 'Bearer ’ + access_token
}, function (e, r, b) {
if (e) {
return callback(e);
if (r.statusCode !== 200) {
return callback(new Error(‘StatusCode:’ + r.statusCode));
callback(null, JSON.parse(b));

Logs always show me
“connection”: “ORCID”,
“error”: {
“message”: “Unexpected token < in JSON at position 0”,
“oauthError”: “invalid_request”,
“type”: “request-error”

When I click try, there is a page showing up without login form

Can you please sort it out?