HackIllinois / api

The Official API supporting HackIllinois
https://api.hackillinois.org
Other
23 stars 51 forks source link

Add async events #460

Closed TakshPSingh closed 2 years ago

TakshPSingh commented 2 years ago

By default, all events are synchronous unless the isAsync field is true.

If isAsync is true, startTime and endTime are optional.

This pull request also updates our validator's version, since the required_if field was not in the old version that we were using.

tanyongzhi commented 2 years ago

Can we add a test for this here?

TakshPSingh commented 2 years ago

Test for async events added

TakshPSingh commented 2 years ago

Looks good. Small nit, but isAsync should be added to other parts of the event documentation, not just for POST /event/.

Good catch. I ended up moving the description of isAsync to the top of the page, so that frontend teams know that it applies to all event endpoints.