Project CARS 2 Randomizer API

Desktop Cell Basic

Updated March 11, 2020

The randomizer was created to add some fun and variety into race nights. Want to level the playing field? Nobody practices Indycars on an RX track...in the rain.

Even if you're just looking for a random car, some random classes, anything - the randomizer is designed to make those decisions for you.

Updated for v. 1.7.1 - notes at the bottom. Contact me via email at JasonArizona[at]duck[dawt]com with all feedback. Made in Arizona and free to use. Enjoy!

API

Path

All calls are made to https://pc2randomizer.azurewebsites.net/api/PC2Randomizer

Flags

Default values are bold. Order does not matter.

format

Determines output from API. No default; required.

images

Include images in HTML output. The default may change if it is expensive for me.

dlc

Include DLC cars and tracks.

karts

Include kart tracks.

rx

Include rally cross tracks.

snow

Chance of snow on a track that would allow it. If Fuji is randomly chose, there is a chance of snow being chosen as the season. "Snow" is a season type
different from the snow weather type. If this is set to false, snow can still fall but the track will not be pre-covered in snow.

snowpct

If the above is true, this is the likelihood of snow being chosen if the track supports snow. By default, this is 30 percent. For no snow, set above flag to false.

laps

This sets the maximum number of laps. This number is used to calculate the race time also, guessing an average speed of 90mph. This is wildly inaccurate
so consider it just another alternate recommendation for the race length.

avs

Average speed in MPH used to figure race length. Default is 90. Take a good guess!

Samples

Car and Track

XML

HTML

Chat Bots

To use the random car and track call with a command chat bot, add these custom commands. Accepted arguments for car are dlc and karts.

Notes

Latest at top

  1. 20231102 - removed link to forum
  2. 20200311 - updated output contact info as well. i forgot api put out my discord name which is now dead.
  3. 20191209 - changed contact info. getting rid of discord, added outlook email
  4. 20190524 - added sample code for Stream Labs OBS (SLOBS) and indicated testing for pc2rando.com
  5. 20190310 - added "tt" as an input, creates a car/track suggestion for time trial and some emoji to the tt, car, and track output for some color
  6. 20190224 - minor change, track and car output now use square brackets
  7. 20181022 - fixed a dumb bug, didn't consider LeMans vintage track dlc as dlc and fixed a typo
  8. 20180916 - added Ferrari DLC
  9. 20180722 - added km to track output for single use "track", best for chat bots, changed some brackets to ">" because bots make emojis with ")"
  10. 20180721 - added info for joining Botisimo
  11. 20180720 - changed "Average Speed" to "Average MPH" on both the cell and desktop landing page
  12. 20180717 - added "car" and "track" to output, a single element returned and provided custom bot use commands
  13. 20180628 - primary landing page redirected to mobile site if narrow display is detected
  14. 20180604 - added le mans legend dlc
  15. 20180601 - added dlc flag to documentation and updated examples, forgot to include it with initial documentation
  16. 20180528 - added avs argument to feed average speed, changed assets to transfer via https only