Railway
Installation & Setup
npm install @computesdk/railwayRAILWAY_API_TOKEN=your_token
RAILWAY_ENVIRONMENT_ID=your_environment_idUsage
import { railway } from '@computesdk/railway';
const compute = railway({
token: process.env.RAILWAY_API_TOKEN,
environmentId: process.env.RAILWAY_ENVIRONMENT_ID,
});
// Create sandbox
const sandbox = await compute.sandbox.create();
// Run a command
const result = await sandbox.runCommand('echo "Hello from Railway!"');
console.log(result.stdout); // "Hello from Railway!"
// Clean up
await sandbox.destroy();Configuration Options
Supported Operations
Method
Supported
Notes
Notes
Last updated
Was this helpful?