python-discord / quackstack

An on-demand procedural ducky delivery service. An infinite stack of duckies!
MIT License
7 stars 1 forks source link

(details): Rework /details endpoint #45

Closed Shivansh-007 closed 3 years ago

Shivansh-007 commented 3 years ago

This commit does two major things, it adds a query parameter called type which takes in a string object of the detail they are requesting i.e. either man-duck or ducky as of now. If it is None, then it would send all the details of all types, otherwise it would send the details only of the requested type.

This commit also adds details for man-duck generation and accordingly alters the man-duck generation class

Requesting ?type=ducky

Screenshot from 2021-05-19 19-40-18

Requesting ?type=man-duck

Screenshot from 2021-05-19 19-40-31

Requesting invalid ?type=ababab

Screenshot from 2021-05-19 19-40-44