Converts text to CONSTANT_CASE format (uppercase with underscores). Access via `/v1/case/constant` endpoint or MCP in Cursor and other editors. Transform "hello world" to "HELLO_WORLD" instantly. Also called screaming snake case — perfect for environment variables and configuration constants.
curl "https://tinyfn.io/v1/case/constant" \
-H "X-API-Key: YOUR_API_KEY"
const response = await fetch('https://tinyfn.io/v1/case/constant', {
headers: { 'X-API-Key': 'YOUR_API_KEY' }
});
const data = await response.json();
console.log(data);
import requests
response = requests.get('https://tinyfn.io/v1/case/constant',
headers={'X-API-Key': 'YOUR_API_KEY'})
data = response.json()
print(data)
Connect your AI agent (Claude, Cursor, Windsurf, etc.) to TinyFn's case conversion tools:
{
"mcpServers": {
"tinyfn-case": {
"url": "https://tinyfn.io/mcp/case",
"headers": {
"X-API-Key": "YOUR_API_KEY"
}
}
}
}
CONSTANT_CASE uses uppercase letters with underscores separating words (API_KEY, MAX_RETRY_COUNT). It's the standard convention for constants, environment variables, and configuration values in most programming languages.
Use the to_constant_case tool in MCP-enabled editors like Cursor or Windsurf. Pass your text as input and get deterministic CONSTANT_CASE output for variable names and constants.
They're the same format — CONSTANT_CASE is an alias for screaming snake case. Both produce uppercase text with underscores, like DATABASE_URL or HTTP_TIMEOUT.
Yes, it converts alphanumeric text and handles special characters by replacing or removing them appropriately. Numbers are preserved: "api-key-2" becomes "API_KEY_2".
Absolutely. CONSTANT_CASE is the standard for environment variables across languages and platforms. Convert "database connection string" to "DATABASE_CONNECTION_STRING" for use in .env files.
Get your free API key and start using To Constant Case in seconds.
Get Free API Key