# Random Number Generator API This API generates random numbers using a combination of randomness from NIST (National Institute of Standards and Technology) and DRAND (Distributed Randomness Beacon). It uses the Mersenne Twister (MT19937) algorithm seeded with combined values from these sources to produce pseudo-random numbers. ## How it works: 1. **Randomness Sources:** The API fetches random values from: - **NIST Beacon:** A public randomness beacon provided by NIST, offering unpredictable and verifiable random bits. - **DRAND:** A distributed cryptographic randomness beacon, ensuring decentralized and robust randomness. 2. **Combining Randomness:** The API retrieves the latest or time-specific pulses from both NIST and DRAND. It combines the 'outputValue' from NIST and 'randomness' from DRAND to create a seed. 3. **Mersenne Twister (MT19937):** The combined seed is then used to initialize the MT19937 pseudo-random number generator. MT19937 is a fast and widely-used algorithm for generating high-quality pseudo-random numbers. 4. **Generating Random Numbers:** Using the seeded MT19937 generator, the API generates the requested number of random integers within the specified range (min and max). ## Endpoints: - **GET /random/:timestamp**: Generates random numbers for a given timestamp. You can specify query parameters: `num` (count), `min`, and `max`. - **GET /nist/:timestamp**: Returns raw randomness data from NIST for a given timestamp. - **GET /drand/:timestamp**: Returns raw randomness data from DRAND for a given timestamp. - **GET /details**: Provides detailed information about the API, including how it works and the endpoints. - **GET /**: This description. For more details, see /details. For source, view https://github.com/shuimu5418/dual-entropy-random