Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Race Data Node Samples

Node.js samples for accessing race data from Svensk Travsport and Svensk Galopp through the Race Data API.

Getting started

Start API simulator
# Start the API simulator in a Docker container
docker run -d -p 8080:8080 troperty/customerapi-broker-simulator
Clone repository and install dependencies
# Clone code from git
git clone [email protected]:troperty/racedata-node-samples.git
cd racedata-node-samples

# Install dependencies
npm install

WebSockets

Listen to messages through WebSocket
# Start listening
npm start
Send WebSocket messages through Simulator
curl -X POST http://localhost:8080/customerapi/channel/id/NonDurable \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -d '<xml>Hello, world!</xml>' \
  -v

About

Node.js samples for accessing race data from Svensk Travsport and Svensk Galopp through the Race Data API.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages