# Forge Invocation Token \`context\` claim appearing in backend function calls

**URL:** <https://community.developer.atlassian.com/t/forge-invocation-token-context-claim-appearing-in-backend-function-calls/102843>\
**Category:** Forge Platform and Tools\
**Created:** [September 23, 2026, 1:39pm UTC](https://community.developer.atlassian.com/t/forge-invocation-token-context-claim-appearing-in-backend-function-calls/102843 "2026-09-23T13:39:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![JorgeToms](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/jorgetoms/32/56136_2.png) [@JorgeToms](https://community.developer.atlassian.com/u/JorgeToms)\
**Post date:** [September 23, 2026, 1:39pm UTC](https://community.developer.atlassian.com/t/forge-invocation-token-context-claim-appearing-in-backend-function-calls/102843/1 "2026-09-23T13:39:46Z")

</div>

The documentation on both the Forge Remote essentials page and the invoke-remote API reference states that `invokeRemote` calls from backend functions do not receive a `context` claim. However, I observed the opposite behavior.

When I called `invokeRemote` from a backend trigger function handling the `avi:forge:upgraded:app` event, the Forge Invocation Token attached to the request included a `context` claim with `cloudId`. The token was verified and contained: `app`, `context`, `aud`, `nbf`, `iss`, `iat`, `exp`, `jti`. The `context` field held exactly `{ “cloudId”: “” }`.

For comparison, a UI module token had the same structure plus a `principal` claim.

References:

- [https://developer.atlassian.com/platform/forge/remote/essentials/](https://developer.atlassian.com/platform/forge/remote/essentials/)
- [https://developer.atlassian.com/platform/forge/runtime-reference/invoke-remote-api/](https://developer.atlassian.com/platform/forge/runtime-reference/invoke-remote-api/)
- RFC-138 states “No changes will occur for triggers, lifecycle events or backends connected to endpoints”, which suggests triggers are expected to carry context.

Filed as [Jira](https://ecosystem.atlassian.net/browse/FRGE-2277)

---

<div class="post-metadata">

**Author:** ![ShannonJohnson](https://avatars.discourse-cdn.com/v4/letter/s/d9b06d/32.png) [@ShannonJohnson](https://community.developer.atlassian.com/u/ShannonJohnson)\
**Post date:** [September 25, 2026, 3:49am UTC](https://community.developer.atlassian.com/t/forge-invocation-token-context-claim-appearing-in-backend-function-calls/102843/2 "2026-09-25T03:49:29Z")

</div>

You’re right, and our documentation is wrong here.

When a Forge backend function calls `invokeRemote`, the Forge Invocation Token includes a `context` claim that contains only `cloudId`. This covers trigger and lifecycle event handlers too. We don’t plan to change this.

- `cloudId` is set for Jira and Confluence installations. For other products, such as Bitbucket, `context` is an empty object.
- No other context fields are included. If your remote needs more, send it in the request body and treat it as untrusted input.
- `principal` is only present when there’s a user behind the invocation, so it’s absent for triggers and lifecycle events like `avi:forge:upgraded:app`.

We’ll update the Forge Remote essentials and Invoke Remote API pages to match.

On RFC-138: “No changes will occur for triggers, lifecycle events or backends connected to endpoints” means the proposed `trusted-only` opt-in won’t change what those invocations receive, including this `cloudId` claim.
