_alnes_Original post
Rank 2: Process
If I set a token on a storage file using the appwrite function (createFileToken), I can no longer see the file in detail in the appwrite console. I get the error: Invalid Argument Server Error.
Docker Logs:
[Error] Timestamp: 2025-09-27T14:04:42+00:00
[Error] Method: GET
[Error] URL: /v1/tokens/buckets/:bucketId/files/:fileId
[Error] Type: Ahc\Jwt\JWTException
[Error] Message: Invalid maxAge: Should be greater than 0
[Error] File: /usr/src/code/vendor/adhocore/jwt/src/ValidatesJWT.php
[Error] Line: 42
[Error] Timestamp: 2025-09-27T14:04:42+00:00
[Error] Method: GET
[Error] URL: /v1/tokens/buckets/:bucketId/files/:fileId
[Error] Type: Ahc\Jwt\JWTException
[Error] Message: Invalid maxAge: Should be greater than 0
[Error] File: /usr/src/code/vendor/adhocore/jwt/src/ValidatesJWT.php
[Error] Line: 42
Browser Console:
GET https://appwrite.vezept.de/v1/tokens/buckets/68d4e29500081045f8bb/files/68d7ed2b000211cfe158 500 (Internal Server Error)
POST https://plausible.io/api/event net::ERR_BLOCKED_BY_CLIENT
However, everything works fine within my Angular app. I just became this warning in docker logs: ```
[2025-09-27 14:13:59 *55.38] WARNING Context::build_header() (ERRNO 7105): You have set 'Transfer-Encoding', 'Content-Length' will be ignored
Summary
Developers can't view storage file details in Appwrite Console after setting tokens using the function createFileToken due to an "Invalid Argument Server Error." The Docker logs show a JWTException error related to maxAge not being set correctly. This issue does not affect the Angular app's functionality. A warning in Docker logs mentions 'Transfer-Encoding' affecting 'Content-Length.'
**Solution:** Investigate and correct the maxAge parameter setting for the JWT token creation function to resolve the Invalid Argument Server Error when viewing storage file details in the Appwrite Console.