Run Java is a Discord bot that allows users to execute Java code directly inside Discord using slash commands. It leverages the Judge0 sandbox API to safely compile and run code in an isolated environment, returning the output in real time.
The bot supports both short inline snippets and large multi-part submissions through a modal editor, making it suitable for complex programs as well as quick tests.
This bot is designed to:
Enable real-time code testing without leaving Discord
Support learning and teaching environments
Assist developers in quickly validating logic
Provide a lightweight execution tool for coding communities
Demonstrate scalable API integration and asynchronous polling systems
It is especially useful for:
Programming study groups
Discord coding communities
Competitive programming practice
Java experimentation and debugging
Showcasing Discord bot architecture and API orchestration
###Execution Flow
/run lang:Java code:your code here input:if you code need input, /run lang:Java <- press ENTER and will show up modal editor, copy your code there
/clear amount:100 will clear your messages in your channel
Code is collected (inline or via modal)
Source is base64 encoded
Sent to Judge0 CE
Bot polls for completion
Output is formatted and returned
Large output is automatically sent as file

