Would you like to clone this notebook?

When you clone a notebook you are able to make changes without affecting the original notebook.

Cancel

Hollywood Bowl API

node v18.11.0
version: 1.0.0
endpointsharetweet
const express = require('express'); const axios = require('axios'); const cors = require('cors'); const app = express(); const PORT = process.env.PORT || 8000; // Enable CORS for all routes app.use(cors()); app.get('/', async (req, res) => { try { const response = await axios.get('https://www.hollywoodbowl.com/apiv2/performances'); res.status(200).json(response.data); } catch (error) { console.error('Error fetching performances:', error.message); res.status(500).json({ message: 'Error fetching performances' }); } }); app.listen(PORT, () => { console.log(`Server running at http://localhost:${PORT}`); });
Loading…

no comments

    sign in to comment