HSG-MCS-HS21_tapas/mocks/auction-house/publisher.js

18 lines
360 B
JavaScript
Raw Permalink Normal View History

2021-11-10 14:14:41 +00:00
const axios = require('axios').default
// Run the server!
const start = async () => {
await axios
.post('http://localhost:3000/publish', {
'hub.mode': 'publish',
'hub.url': 'http://localhost:3100/auctions'
})
.then(response => {
console.log(response.data)
})
.catch(error => {
console.log(error)
})
}
start()