I am generating a token in Java and rendering the document using the following code:
The value of selectFile.s3Url
is a publicly accessible document URL. I verified that I can access it directly by pasting it into the browser’s address bar.
When I decode the token using https://jwt.io/, it shows the following output:
I have set the secretKey
in local.json
and am using the same secretKey
in Java to generate the token.
Is there anything incorrect in my data? How can I resolve this issue?
Thank you.
Hello @moonjb,
Please provide the following (you can send it via PM):
- The local.json (/etc/onlyoffice/documentserver, for Docker - in the container)
- The whole Editor’s initialization config which is used for token generation (original version)
Hello,
Thank you sincerely for your response.
The issue I initially reported was caused by the secretKey
being transmitted after base64 encoding. After resolving that, I am now encountering a different error.
I am providing a publicly accessible S3 URL, and the config
structure is as follows:

The contents of local.json
are as follows:
The out.log
file from docservice
contains the following log entries:
Is there anything incorrect in my code?
If this question requires a new topic, I apologize in advance.
Thank you.
+) Additionally, I am using the DocumentEditor
component as it is, imported via:



Hello @moonjb,
S3 bucket cannot be used as file storage as it is (although it can be configured as the cache storage - Connecting Amazon S3 bucket as a cache to ONLYOFFICE Docs)
To be able to use it as file storage, you’d have to build additional layer, we have only C# example of integration with S3 as file storage, here it is - document-server-integration/web/documentserver-example/csharp-mvc at feature/csharp-mvc-s3 · ONLYOFFICE/document-server-integration · GitHub
Also, the logs indicate that you have a commercial license, which is about to expire. Please contact your sales manager at sales@onlyoffice.com. If you have a commercial license, you can create tickets in the helpdesk and ask questions there
P.S. Yes, it is better to create another topic for the new issue
1 Like