403 "Current user not permitted to use Confluence" when using OAuth 2.0 Service Account token with Confluence Search API

I’m trying to access the Confluence Search API using an OAuth 2.0 service account, but I’m getting a 403 Forbidden error.

What I’ve done

  1. Created a service account.
  2. Generated a Client ID and Client Secret.
  3. Granted the scope:
    • read:page:confluence
  4. Generated an access token using the service account credentials.

I’m calling the following API:

GET https://api.atlassian.com/ex/confluence/{cloudId}/wiki/rest/api/search?cql=space="FAQ" AND type="page" AND created >= "2026-07-01" AND created <= now()

The response is:

{
  "message": "Current user not permitted to use Confluence",
  "statusCode": 403
}

What I’ve verified

If I call the equivalent Confluence site endpoint using Basic Authentication (email + API token):

GET https://your-domain.atlassian.net/wiki/rest/api/search?cql=space="FAQ" AND type="page" AND created >= "2026-07-01" AND created <= now()

I receive a successful response with the expected results.

My question is

  1. Are there additional OAuth scopes required beyond read:page:confluence?
  2. Any changes needed in the api?

Any guidance or suggestions would be greatly appreciated.

Thanks!

Welcome to the Atlassian Developer Community forums, @AkhilMohanan!

Since you’re using the Search Content REST API, you need to use the search:confluence scope.

Do try it out and let us know how it goes.

Cheers,

Ian