0
import requests

params = {
    'apiKey': 'hidden',
    'author_id': '36573126000'
}


def main():
    r = requests.get('https://api.elsevier.com/content/author', params=params)
    print(r.text)


main()

I'm unable to communicate with the API, as it's returning the following error:

<service-error><status><statusCode>AUTHORIZATION_ERROR</statusCode><statusText>The requestor is not authorized to access the requested view or fields of the resource</statusText></status></service-error>

What is / are the issue(s), and how can I resolve this?

taylor.2317
  • 582
  • 1
  • 9
  • 23

2 Answers2

0

There can be two issues that can cause this:

  1. Your API Key does not have the correct level of entitlement to access that resource
  2. You are attempting to access this resource outside of your institutional network and will need an Institutional Token to enable this.

Both can be resolved by contacting Elsevier Support at the following form:

https://service.elsevier.com/app/contact/supporthub/researchproductsapis/

0

This issue is usually because your current connection/IP is not the same as the one you used to create your Scopus Account; which is usually the Institutional Connection that has been granted access to Scopus. So if there is a need to access Scopus outside that specific IP (institutional IP), then you need to setup a remote VPN proxy for yourself or Inst tokens might work as well.

Read below for clarity:

The Scopus API recognizes you as a member of your institution via IP range. For working remotely, Scopus can also grant InstTokens. Thus one of three things needs to happen:

  1. You are in your instition’s network

  2. You use your instition’s VPN

  3. You use an InstToken

Option 1 is easy and the most common.

Option 2 might require you to additionally set a proxy. You can do so in the configuration file.

Option 3 is rare. If you have an InstToken, please provide it during the setup. Alternatively, add it to the configuration file manually. You may also set the InstToken via insttoken=”XYZ” in any class. This is the preferred solution if you possess multiple keys.

Please Note: These suggestions are listed under pybliometrics python wrapper class documentation. However, this issue of accessing Scopus API must be the same regardless of the language and these suggestions might work.