A leetcode based RESTful testcase generator API.
For comprehensive documentation visit - LC/tcg API docs
- Local -
http://localhost:5000
- Remote -
https://lc-tcg-api.cyclic.app/
choose remote server when using the api documentation to try out endpoints
GET /api/arrays/0
Parameter | Type | Description |
---|---|---|
- |
- |
no parameter |
RETURNS : a random array
POST /api/arrays/1
Parameter | Type | Description |
---|---|---|
count |
number |
Required. Number of arrays to generate |
minSz |
number |
Required. Minimum possible array size |
maxSz |
number |
Required. Maximum possible array size |
minEle |
number |
Required. Minimum possible array element size |
maxEle |
number |
Required. Maximum possible array element size |
uniqueEle |
boolean |
Required. True if all elements in array should br unique |
RETURNS : A list of count
number of arrays each of size in range [minSz,maxSz]
having elements in range [minEle,maxEle]
Clone the project
git clone https://github.com/DeweshSoc/lc_tcg.git
Go to the project directory
cd lc_tcg
Install dependencies
npm install .
Start the server
npm run start
Server available at http://localhost:5000