# Error 400 Bad Request URL Too Long

**URL:** <https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778>\
**Category:** Uncategorized\
**Created:** [April 27, 2023, 2:14pm UTC](https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778 "2023-04-27T14:14:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Loubens](https://avatars.discourse-cdn.com/v4/letter/l/9fc29f/32.png) [@Loubens](https://forum.collaboraonline.com/u/Loubens)\
**Post date:** [April 27, 2023, 2:14pm UTC](https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778/1 "2023-04-27T14:14:17Z")

</div>

Good morning  
I have a problem when I try to access documents in a cloud with a tree structure that is too large.  
When I’m in a folder that has a 380 character request it works, and when I go to 410 I get a 400 Bad Request error on Collabora/code.  
I’m on kubernetes with the latest version of Collabora/Code.  
I tried in my Ingress-Nginx to add maxurllength but it didn’t change anything.  
Do you have an idea ?  
THANKS

---

<div class="post-metadata">

**Author:** ![rash419](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.collaboraonline.com/rash419/32/1157_2.png) [@rash419](https://forum.collaboraonline.com/u/rash419)\
**Post date:** [May 4, 2023, 10:50am UTC](https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778/2 "2023-05-04T10:50:58Z")

</div>

@Loubens can you give some steps to reproduce the problem please ?

---

<div class="post-metadata">

**Author:** ![Loubens](https://avatars.discourse-cdn.com/v4/letter/l/9fc29f/32.png) [@Loubens](https://forum.collaboraonline.com/u/Loubens)\
**Post date:** [May 4, 2023, 11:36am UTC](https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778/3 "2023-05-04T11:36:01Z")

</div>

@rash419 Good morning  
when I try to create a file in a folder, and that folder is in a subfolder, which is in a subfolder, etc…  
I can create my file in my cloud without worries, I can download it if needed, however I can’t open it from Collabora/code, here is the length of my WOPI request:  
[https://libreofficexxx.mondomainexx.com/browser/dcae5fa/cool.html?lang=fr-FR&WOPISrc=https://api.mondomainexx.com/restv3/ws/wopi/files/MDczVEpPRUzCpENMT1VEwqRYRnhEVEU5VlJEQTVYR05zYjNWa1hEQTNNMVJLVDBWTVhGQmNNelE1](https://libreofficexxx.mondomainexx.com/browser/dcae5fa/cool.html?lang=fr-FR&WOPISrc=https://api.mondomainexx.com/restv3/ws/wopi/files/MDczVEpPRUzCpENMT1VEwqRYRnhEVEU5VlJEQTVYR05zYjNWa1hEQTNNMVJLVDBWTVhGQmNNelE1) WEUxdmJpQmpiRzkxWkNCUVpYSnpiMXhOYjI0Z1kyeHZkV1FnVUdWeWMyOGdNbHhOYjI0Z1EyeHZkV1FnVUdWeWMyOGdNMXhOYjI0Z1kyeHZkV1FnTkZ4TmIyNGdZMnh2ZFdRZ05WeE5iMjRnUT J4dmRXUWdVR1Z5YzI4Z05seDBaWE4wSUdOc2IzVmtJRE11Wkc5amVBPT0=  
And when I do that, I get a 400 error.  
Is that enough information?  
Otherwise the other question is:  
What is the MAX URL length for Collabora/code?

---

<div class="post-metadata">

**Author:** ![Loubens](https://avatars.discourse-cdn.com/v4/letter/l/9fc29f/32.png) [@Loubens](https://forum.collaboraonline.com/u/Loubens)\
**Post date:** [May 5, 2023, 2:01pm UTC](https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778/4 "2023-05-05T14:01:26Z")

</div>

Good morning  
I found a solution, I did an MD5 HASH of my files path in my WOPI call, and now it works.  
THANKS

---

<div class="post-metadata">

**Author:** ![mmeeks](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.collaboraonline.com/mmeeks/32/371_2.png) [@mmeeks](https://forum.collaboraonline.com/u/mmeeks)\
**Post date:** [May 5, 2023, 4:33pm UTC](https://forum.collaboraonline.com/t/error-400-bad-request-url-too-long/1778/5 "2023-05-05T16:33:59Z")

</div>

Glad that works for you; I’m surprised it caused an issue - we don’t have an internal limit on WOPISRC length that I’m aware of; but I can believe that proxies the connection goes through may do.

Ultimately any unique hash we can provide back to you to uniquely identify the file should work I hope. Thanks for asking.
