Hi guys,
I have a feature in my forge app which allows users to upload custom images for an entity. I am storing these images to my remote server. Once uploaded, users can see the uploaded image against the entity across sessions. For this, I am using a img tag with the src as the URL for the uploaded image on my remote. In connect, I added the JWT token to the src for authentication. For forge, I am not able to access the FIT. Is there something I am missing, or is there a separate way I can authenticate such requests.
Hello
TLDR: As far as I know, you cannot easily serve binary images from in Forge from your backend.
However, given that you have a remote, you can built your own.
We want a similar thing: Serve images from a backend to a Forge Frontend, via basic tag =). In the past, in Connect we created a JWT token for such a image request and all things where well.
In ‘pure Forge’ we couldn’t find a way, because:
- Forge function invocations assume JSON responses.
- Afaik, remote invocations via Forge APIs also assume JSON/text.
- Forge webtriggers assume text responses.
However, because you are using a Forge remote, you can ‘skip’ the Forge APIs with some effort. See the approach other take here.
Hi @RomanStoffel
Thanks for the post. We already have our UI separated from the manifest as mentioned in the post, and we had a similar reasoning to go that route. I think, we would just need to implement the signed JWT part.