How to Hook UploadThing to a Different Route Instead of /api/uploadthing?
Hey everyone,
Is there any way to configure UploadThing to use a custom route instead of /api/uploadthing? I have a separate backend running behind a reverse proxy at example.com/api, so I can't use the /api route for UploadThing. Any help or suggestions would be appreciated!
1 Reply
I had the same trouble because I had to change my folder structure to app/[locale]/api/uploadthing in i18n
I could manage to solve this problem by passing the new URL as a parameter inside of the generateReactHelpers function in uploadthing.ts file (app/lib/uploadthing.ts)
Hope it helps you!