[Integration API] GET /site-resource/{siteResourceId} not working #37

Open
opened 2026-04-05 17:00:37 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @ninofaivre on 3/30/2026

Describe the Bug

As said in the title this route in the integration API is not working.
Here is the error I get with a 400 status :
'Validation error: Invalid input: expected string, received undefined at "siteId"; Invalid input: expected string, received undefined at "orgId"'
After taking a quick look at the code (even tho I have not done any ts and zod for a looooong time), I believe this bug is due to the zod schema expecting a siteId and an orgId but the route does not contains it.
So either the getSiteResource function should be working without it either the route needs to be updated with the correct path params.

Environment

I have been able to reproduce this bug in :

  • free tier pangolin.net hosted
  • self hosted v1.15.3 on NixOS

To Reproduce

Just create a site-resource, get its id via /org/{orgId}/site-resources and then try to get it via /site-resource/{siteResourceId}. I think this issue is very old because it is happening on my selfhosted v1.15.3 AND on the app.pangolin.net hosted free tier.

Expected Behavior

Should return me a site-resource.

*Originally created by @ninofaivre on 3/30/2026* ### Describe the Bug As said in the title this route in the integration API is not working. Here is the error I get with a 400 status : `'Validation error: Invalid input: expected string, received undefined at "siteId"; Invalid input: expected string, received undefined at "orgId"'` After taking a quick look at the code (even tho I have not done any ts and zod for a looooong time), I believe this bug is due to [the zod schema](https://github.com/fosrl/pangolin/blob/main/server/routers/siteResource/getSiteResource.ts#L13) expecting a siteId and an orgId but [the route](https://github.com/fosrl/pangolin/blob/main/server/routers/external.ts#L312) does not contains it. So either the getSiteResource function should be working without it either the route needs to be updated with the correct path params. ### Environment I have been able to reproduce this bug in : * free tier pangolin.net hosted * self hosted v1.15.3 on NixOS ### To Reproduce Just create a site-resource, get its id via `/org/{orgId}/site-resources` and then try to get it via `/site-resource/{siteResourceId}`. I think this issue is very old because it is happening on my selfhosted v1.15.3 AND on the app.pangolin.net hosted free tier. ### Expected Behavior Should return me a site-resource.
MrUnknownDE added the needs investigating label 2026-04-05 17:00:38 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/pangolin#37