HackGT / SponsorshipPortal

[in development] Web interface for sponsors to view participant information. Integrates with HackGT/registration
GNU General Public License v3.0
7 stars 0 forks source link

Use GraphQL endpoints to get fresh information. #26

Open illegalprime opened 7 years ago

illegalprime commented 7 years ago

Use the a GraphQL endpoint (registration endpoint is fine) to poll for new user data and integrate it into the app. Push notifications are not implemented in registration yet so it will have to be a poll, considering the frequency of new information it might be better as a poll.

Make sure this is configurable, e.g. which URL endpoint to hit.

Relevant routes for to initiate a GraphQL Search:

Route Method Description Request Response
/search POST Perform combined resume token and participant name/email search {search: <string>, use_regex: <boolean>} {participants: [Array of <Participant>]}

Inside of this route, should implement a method to perform a GraphQL search on participants information using the search_user(search: String!, use_regex: Boolean = false, offset: Int!, n: Int!, filter: UserFilter): SearchResult! registration GraphQL endpoint.

bunsenmcdubbs commented 6 years ago

Push notifications are to be implemented in HackGT/registration#198 removing the need for polling. This app should be listening for changes to any of the fields that will be indexed and synchronize its data accordingly.

If this^ is too complicated, I suggest waiting only for user creation or resume upload so those documents can be parsed as part of #61, when that happens, a GraphQL can be made to registration to get the participant's data.