• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Adobe PDF Extract API fails to generate access token for my scopes: invalid_target_scope

Community Beginner ,
Aug 24, 2023 Aug 24, 2023

Copy link to clipboard

Copied

The code I am using to generate an access token can be found here.

 

It is written in Rust, but should be easy enough to follow for non-rustaceans here.

 

The problem is that Adobe isn't returning a standard response, and also they are returning an error "invalid_target_scope" with description: "None of the requested scopes are both on the client and the binding.".

 

I am planning on using the Adobe PDF extract API, but I am currently stuck.

 

NOTE: I am using the "openid, AdobeID and DCAPI" scopes only.

TOPICS
Bug , PDF Extract API , REST APIs

Views

849

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Aug 24, 2023 Aug 24, 2023

According to our documentation, you don't need the scope at all, just the id and secret.

Votes

Translate

Translate
Community Beginner ,
Aug 24, 2023 Aug 24, 2023

Copy link to clipboard

Copied

My temp fix: change the token URI to “https://pdf-services-ew1.adobe.io/token” and I swapped out an OAuth client library to just make a direct POST request for fetching tokens, as I got error 400: bad request using oauthlib + oauthlib_requests in Python, which I switched to temporarily assuming something was wrong with the oauth2_async crate in Rust.

 

Oh well, for now I am using plain POST requests and I hope that serves me well enough.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 24, 2023 Aug 24, 2023

Copy link to clipboard

Copied

According to our documentation, you don't need the scope at all, just the id and secret.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Aug 24, 2023 Aug 24, 2023

Copy link to clipboard

Copied

I eventually found that out after re-checking the API docs. This makes it a pain in the ass to use OAuth2 libraries, as Adobe suggests.

 

Thanks for the reply

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 24, 2023 Aug 24, 2023

Copy link to clipboard

Copied

LATEST

I have some nodejs samples that work and use scopes. Try setting the scope to...

 

'openid,AdobeID,read_organizations'

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources