OnlineCompiler MCP Server
OfficialServer Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| ONLINECOMPILER_API_KEY | No | Optional OnlineCompiler.io API key, sent as `Authorization: Bearer <key>` (the bare key also works). Not needed when signing in with OAuth. Get a free key from https://api.onlinecompiler.io/compilers/api-keys/ |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server lets you compile and run code in 46 programming languages via the OnlineCompiler.io API. Use list_compilers to see available languages, run_code to execute code, run_tests to judge a solution against test cases, and judge_problem to judge code against one of your stored problems.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
| logging | {} |
| prompts | {
"listChanged": true
} |
| resources | {
"subscribe": false,
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| list_compilersA | List all available compilers/languages supported by OnlineCompiler.io. Returns a list of compiler objects with id and name. Use the id value as the compiler argument when calling run_code. |
| run_codeA | Run one program in a sandbox and return its output. Returns output, error, status, exit_code, time (wall-clock seconds), memory and truncated. Limited to 30 seconds (or time_limit) and 512 MB RAM. To check a solution against expected outputs, use run_tests instead. python-3.14 includes numpy, pandas, scipy, scikit-learn, matplotlib, seaborn, statsmodels,
sympy, openpyxl, pillow, duckdb, polars, wordcloud, pgmpy and nltk (with WordNet, VADER and the
English POS tagger data) (no network, so nothing else can be installed).
Files a program writes to the directory in $OUTPUT_DIR come back in |
| run_testsA | Check a program against test cases and judge it like an online judge. Takes at most 10 tests, each counting as one run. Every test runs unless the code fails
to compile or the request runs out of time. Returns an overall verdict, a score from 0
to 100 and a verdict per test. time_limit is seconds per test; compiling before the run
does not count against it, and Java, Groovy and F#, which compile as they start, get a
start-up allowance on top of it. python-3.14 includes numpy, pandas, scipy, scikit-learn,
matplotlib, seaborn, statsmodels, sympy, openpyxl, pillow, duckdb, polars, wordcloud, pgmpy
and nltk, and duckdb-1.5 works
like sqlite-3, so data questions can be judged with checker "rows" and shared |
| judge_problemA | Judge code against one of your stored problems. Runs the problem's tests and returns a verdict, a score, a summary, a submission id, a signed receipt, and the problem id and version. Hidden tests return only their verdict, never their input or expected output. It never invents results: if the problem is missing or the run fails, you get an error. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 4 tools
The tools mostly have distinct roles: list_compilers discovers languages, run_code executes one program, run_tests checks arbitrary test cases, and judge_problem evaluates against a stored problem. The only mild overlap is between run_tests and judge_problem, but the descriptions clarify the distinction between ad-hoc tests and stored problem tests.
All tool names follow a clear verb_noun snake_case convention: run_tests, judge_problem, list_compilers, run_code. The pattern is predictable and easy to scan.
Four tools is a well-scoped surface for an online compiler service: language discovery, direct execution, custom test judging, and stored-problem judging. Each tool has a clear purpose and none feels redundant.
Core execution and judging workflows are covered, but judge_problem depends on stored problems while no tool lists, creates, updates, or retrieves those problems. That is a notable gap for agents trying to manage the problem lifecycle through this server alone.