https://linen.dev logo
BUG: Confluence OAuth Integration Fails Due to Mis...
# 🖥│support-forum
p
Composio’s Confluence OAuth integration completes authentication successfully but fails every downstream Confluence API call with 401 Unauthorized. The root cause might be that Composio does not fetch or store the Confluence Cloud ID, which is required to construct valid Atlassian REST API URLs. Without the Cloud ID, all requests are malformed and rejected, making the entire Confluence integration nonfunctional. The OAuth flow, scopes, and access token are all valid — the failure occurs purely in Composio’s request construction logic. See detailed report attached. https://cdn.discordapp.com/attachments/1447639198176641045/1447639198885744760/message.txt?ex=693cf7d0&is=693ba650&hm=e3b65caba716db481704dfb965c47ecd8dedbe1e3c8ab5f168308035e9da1402&
u
Hey @P_STKN, could you share logId of your tool call? It'll help us in debugging.
p
@Uday Sure thing, here's an example logId: log_D_bsWitVdFJB
Thanks for the quick response
u
Hey @P_STKN, we were unable to reproduce the issue. There could be a minor delay, could you try executing
CONFLUENCE_GET_SPACES
with the same connected account
ca_hhnZHNYmFXQ6
and lmk if you are still facing the error?
p
I get this error message: For context I use the Classic Scopes in the Atlassian OAuth app. { "data": {}, "error": "Failed to retrieve cloud ID: 401: {\"code\":401,\"message\":\"Unauthorized\"}", "successful": false, "logId": "log_dFKa23lSHzfp" }
@Uday
u
Hey @P_STKN, could you try adding
offline_access
scope to your authConfig and try creating a new connected account? This scope enables toke refresh.
p
@Uday offline_access should already be included in the authConfig. Redid the oauth process and connected the account (ca_bpTnNIJRD7SC) but recieved the same error: { "data": {}, "error": "Unauthorized: Authentication failed or missing credentials.", "successful": false, "logId": "log_ul_ttrWqFN6K" } However I see no way on the Atlassian side to add offline_access as a scope, but from what I understood that's purely a "free" scope so to speak. https://cdn.discordapp.com/attachments/1447639198176641045/1448287205117263924/image.png?ex=693ab611&is=69396491&hm=614cbf41b36ce17be799ee4cc7373f09aa46579b62a9db50b4575657d8c5ff8e&
u
Hey @P_STKN, I just checked your connected account (
ca_bpTnNIJRD7SC
) and looks like
offline_access
is not configured. You can actually click on your connected account to verify the same. https://cdn.discordapp.com/attachments/1447639198176641045/1448288791998763049/Screenshot_2025-12-10_at_17.51.08.png?ex=693ab78b&is=6939660b&hm=824dd6988c8ce72cd9f603dbb6da08e8effd0122d0b8c5630386b8c6bc4fa675&
p
@Uday Hmm, it did exist in the list of scopes configured in the authConfig. To verify I removed the scope and readded it and then saved the auth config. Then reconnected the account. Still get errors, not sure what I'm missing here. Fairly certain now that the offline_access scope is added on the Composio end and seems like there's no way to add that "as a scope on the Atlassian" end https://cdn.discordapp.com/attachments/1447639198176641045/1448292020706873385/image.png?ex=693aba8d&is=6939690d&hm=27e98f67ee4cea165bcea2afcd6a4882405ee3bb6e79bda41a0800d32b4d6892& https://cdn.discordapp.com/attachments/1447639198176641045/1448292020966658048/image.png?ex=693aba8d&is=6939690d&hm=711b275d3bac4d1666967ed876f78b8b70935caee83f4d2350a6dd770eb208c5&
Am I missing anything?
u
The connected account(
ca_jzetS1dmb2sf
) in your screenshot has been deleted.
p
Yeah, I set it up from scratch and reconnected to validate that I hadn't accidentally missed the offline_access scope.
Either of the above should work as a reference. Apologies, trying to troubleshoot at the same time as getting help from you 🙏
u
Got it, I can see a successful tool call with
ca_LwtJ1hbNNgeG
. Could you try executing the tool with this connected account Id again and lmk if it's working?
p
Tried now again with that account. Get two types of errors: { "data": {}, "error": "Unauthorized: Authentication failed or missing credentials.", "successful": false, "logId": "log_OU5kxbdWSD4w" } { "data": {}, "error": "Failed to retrieve page '12345678'. Status code: 401. Response: {\"code\":401,\"message\":\"Unauthorized; scope does not match\"}", "successful": false, "logId": "log_uAqx6_PIIn_J" } https://cdn.discordapp.com/attachments/1447639198176641045/1448305476730355773/image.png?ex=693ac715&is=69397595&hm=1b15dcbe3bad91172118a0932213fe1db22fcdb1963e5dd9975279d5f257cbd5&
So missing scopes potentially, but it's odd because I clearly have the right scopes for these tool calls. The only one that isn't a one-to-one match between the scope list in Composio and my Confluence OAuth app is 'offline_access' that I have no way of adding in Atlassian Developer console.
Did the above give any more data in your logs?
u
Hey I've checked the associated scopes for your connected account Id
ca_LwtJ1hbNNgeG
. Looks like you are using irrelevant scopes, for example:
read:confluence-space.summary
instead of
read:space:confluence
. — Could you try configuring correct scopes in your AuthConfig as well as your Confluence and then initiate a connection? You can refer Composio's default list of scopes.
p
@Uday Thanks for the above. I have set it up using the interface Atlassian provides where e.g. the scope "read:confluence-space.summary" does not exist as an option. See attached. Do I understand you then that I have to use Granular Scopes to get the app compatible with Composio? https://cdn.discordapp.com/attachments/1447639198176641045/1448777245802893513/image.png?ex=693c7e74&is=693b2cf4&hm=86322a18c952f1e81cefd06d0364ec51272d98dd04400e7bfc42b74f27b8d8b4&
u
Hey @P_STKN, I can see
read:confluence-space.summary
scope in the attached image(2nd one from top). Ideally, it's better to keep your scopes alined with composio as the use of classic and granular scopes depends on the v1/v2 endpoints.
p
Hey @Uday sorry, might be me who's not understanding something basic here but in the Atlassian UI I only have the option to choose between Classic or Granular scopes to add to my OAuth Atlassian App. I of course have full control in Composio.Dev interface but that does not match Atlassian Developer Console which only gives these options: https://cdn.discordapp.com/attachments/1447639198176641045/1449003378502795409/image.png?ex=693d510e&is=693bff8e&hm=7a3d583fcb706edc88bd839bbb8958781e84bd9cb9975d3981f606c861f8d9b6&
u
Hey @P_STKN, are you unable to configure both Classic and Granular scopes on your Atlassian dev console? Let me know if I misunderstood anything. https://cdn.discordapp.com/attachments/1447639198176641045/1449019202273808384/Screen_Recording_2025-12-12_at_18.12.26.mov?ex=693d5fcb&is=693c0e4b&hm=921d252853a4f6ef6ef36a056eac44162fd4d2086faa8e68b611da95cdb64b22&