# Forge Containers: invokeService requires 'body: string'?

**URL:** <https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033>\
**Category:** Forge Platform and Tools\
**Tags:** forge-containers\
**Created:** [October 1, 2026, 2:25pm UTC](https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033 "2026-10-01T14:25:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![RomanStoffel](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/romanstoffel/32/42175_2.png) [@RomanStoffel](https://community.developer.atlassian.com/u/RomanStoffel)\
**Post date:** [October 1, 2026, 2:25pm UTC](https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033/1 "2026-10-01T14:25:57Z")

</div>

For the Forge Containers the ‘[invokeService](https://developer.atlassian.com/platform/forge/containers-reference/int-invokeservice/)’, the body argument has a type ‘unknown’, and the documentation states that it must be a JSON.  
This aligns with other similar calls, like [`invokeRemove`](https://developer.atlassian.com/platform/forge/apis-reference/ui-api-bridge/invokeRemote/)

However, in practise it seems that it must be String JSON formatted. At least when using the forge tunnel and proxy-sidecar.

If we try to send a JSON object over it, I see the JSON object in the GraphQL call, like I expect. However, at the proxy-sidecar level a `[object Object]` arrives. When I send the body as a String with JSON in it, then at the proxy-sidecar the JSON inside of that String arrives.

This looks to me like a bug? Or it needs way more explicit documentation that this body must be a String with JSON in it.

---

<div class="post-metadata">

**Author:** ![HeyJoe](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/heyjoe/32/39049_2.png) [@HeyJoe](https://community.developer.atlassian.com/u/HeyJoe)\
**Post date:** [October 2, 2026, 1:12am UTC](https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033/2 "2026-10-02T01:12:43Z")

</div>

Hi @RomanStoffel

Thanks for reporting this. The team is taking a look!

---

<div class="post-metadata">

**Author:** ![RomanStoffel](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/romanstoffel/32/42175_2.png) [@RomanStoffel](https://community.developer.atlassian.com/u/RomanStoffel)\
**Post date:** [October 2, 2026, 5:23am UTC](https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033/3 "2026-10-02T05:23:47Z")

</div>

Not really related, but:

`invokeService` also works to invoke Forge remotes. We did it by accident and never noticed. So, there might be apps that rely on this behavior that `invokeSevice` works for Forge Containers and Forge Remotes!

It’s actually nice that it works for both, if your app has a flavor based of Forge Remotes (public cloud) and Forge Containers (Isolated Cloud). Because as far as I know there is not appID or something like that in the context that let’s you switch to the ‘right’ call.

---

<div class="post-metadata">

**Author:** ![HeyJoe](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/heyjoe/32/39049_2.png) [@HeyJoe](https://community.developer.atlassian.com/u/HeyJoe)\
**Post date:** [October 5, 2026, 12:55am UTC](https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033/4 "2026-10-05T00:55:44Z")

</div>

A fix to the docs is in the works. The correct/intended behaviour is that the body is a string containing JSON.

---

<div class="post-metadata">

**Author:** ![HeyJoe](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/heyjoe/32/39049_2.png) [@HeyJoe](https://community.developer.atlassian.com/u/HeyJoe)\
**Post date:** [October 12, 2026, 8:01am UTC](https://community.developer.atlassian.com/t/forge-containers-invokeservice-requires-body-string/103033/5 "2026-10-12T08:01:19Z")

</div>

This wasn’t intentional but now that it’s been built we’ll probably leave it as is; especially it’s actually useful in some cases 🙂
