I want to take a bounding box, use the OpenStreetMap API and get a tile, then use it as a background in basemap. This should be easy, but I haven't been able to figure out the API.
Go to OSM website (http://www.openstreetmap.org), choose a BBOX and select
When you take data from OSM you'll get just the data. You'll need to import it to your database/QGIS/Geoserver and apply some styles to see the data as seen in OSM map. I know nothing about
To import the data to PostgreSQL you can use
osm2pgsql -C 2500 -c -d database_target -U postgre_user -W -s -S ./your_style_file.style your_osm_file.osm
database_target must have the GIS extensions.
Getting the same beautiful OSM map appearance is not so easy since there is no official style file to download. You must dig it.