TuskLang API Integration

One API. Nine Languages.

TuskLang works seamlessly with PHP, JavaScript, Python, Bash, Go, C#, Rust, Ruby, and Java.
Simple, consistent, powerful.

PHP + TuskLang

Native PHP integration with familiar syntax. Perfect for Laravel, Symfony, or vanilla PHP projects. Your configs feel right at home.

  • PSR-4 autoloading compatible
  • Laravel service provider included
  • Composer package available
  • PHP 7.4+ support
app.php
<?php
// Load TuskLang parser
use TuskLang\Parser;

// Parse configuration
$config = Parser::load('config.tsk');

// Access values naturally
echo $config['app_name'];
echo $config['database']['host'];

// Dynamic queries
$activeUsers = $config['stats']['users'];

// Environment-aware
if ($config['debug']) {
    echo 'Debug mode enabled';
}
?>

JavaScript + TuskLang

Integrate TuskLang into your Node.js applications with our simple parser. Replace complex JSON configurations with intelligent, self-optimizing configs.

  • Native async/await support
  • Environment variable handling
  • Live reload capabilities
  • TypeScript definitions included
app.js
// Import TuskLang parser
const TuskLang = require('tusklang');

// Load and parse config
const config = await TuskLang.load('config.tsk');

// Access intelligent values
console.log(config.server.port);  // Auto-optimized
console.log(config.cache.ttl);   // Self-learning

// Live queries
const users = config.active_users;  // Real-time from DB

// Watch for changes
config.watch(() => {
    console.log('Config updated!');
});

Python + TuskLang

Clean configuration management for Python applications. Perfect for Django, Flask, or any Python project needing intelligent configs.

  • Type-safe with dataclasses
  • Environment variable support
  • Django/Flask integration
  • Async support built-in
app.py
# Import TuskLang parser
from tusklang import TuskLangParser

# Parse configuration
parser = TuskLangParser()
config = parser.parse_file('config.tsk')

# Access values with type safety
print(f"App: {config.name} v{config.version}")
print(f"Port: {config.port}")

# Access nested configs
db = config.database
print(f"Database: {db.engine} on {db.host}")

# Self-optimizing features
workers = config.server.workers  # Auto-scaled

Start Using TuskLang Today

composer require tusklang
npm install tusklang
pip install tusklang
apt install tusklang
go get tuskt.sk/go
nuget install TuskLang
cargo add tusklang
gem install tusklang
mvn add com.tusklang
📖 View Documentation

Why Developers Choose TuskLang

🚀

Zero Learning Curve

Familiar syntax across all languages. If you can write config, you can write TuskLang.

🧠

Self-Optimizing

Configs that learn and adapt. Set once, optimize forever.

Real-Time Data

Query databases, call APIs, and compute values live in your config.

🌍

9 Languages

Production-ready libraries for PHP, JS, Python, Bash, Go, C#, Rust, Ruby, and Java.

🔧

Type Safe

Full type support for TypeScript, C#, Rust, Java, and Go. Catch errors at compile time.