Viewing an older version of mapbox.js. Check out v1.4.0 for the latest.

Using Toner Tiles

The MapBox Javascript API can be used with other tile sources
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>Using Toner Tiles</title>
  <script src='http://api.tiles.mapbox.com/mapbox.js/v0.6.7/mapbox.js'></script>
  <link href='http://api.tiles.mapbox.com/mapbox.js/v0.6.7/mapbox.css' rel='stylesheet' />
  <style>
    body { margin:0; padding:0; }
    #map { position:absolute; top:0; bottom:0; width:100%; }
  </style>
</head>
<body>
<div id='map'>
</div>
<script>
var m = mapbox.map('map');
// It's simple to add non-MapBox Layers by using the
// full Modest Maps API. Stamen also has a JavaScript
// snippet you can add to add their layers quickly:
// http://maps.stamen.com/
m.addLayer(new MM.TemplatedLayer('http://b.tile.stamen.com/toner/{Z}/{X}/{Y}.png'));
m.ui.attribution.add()
    .content('Map tiles by <a href="http://stamen.com">Stamen Design</a>, under' +
    ' <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>.' +
    ' Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://creativecommons.org/licenses/by-sa/3.0">CC BY SA</a>.');
m.ui.zoomer.add();
m.ui.zoombox.add();
m.zoom(3);
</script>
The code and documentation to mapbox.js is hosted on GitHub where you can contribute changes and improvements.