Skip to content

Latest commit

 

History

History
72 lines (52 loc) · 3.86 KB

File metadata and controls

72 lines (52 loc) · 3.86 KB

HackGreenville Events API

The Events API can be used to build your own custom applications from the structured JSON data representing the HackGreenville events.

Interactive API Explorer

Start with the interactive API explorer which:

  • documents the query parameters that allow for filtering the results
  • allows you to use a built-in "Try it out" button to generate API URLs
  • allows you to use a built-in "Send Request" button to execute the API call within the explorer
  • shows sample JSON responses

Limitations, Gotchas, and Contributor Tips

  • We support two API versions, v1 and v0, but we encourage using v1.
  • The production / live website is cached and changes may take up to 4 hours to show due to the cache.
  • The Events API's responses are controlled by server .env variables that may limit the data available to calling / consuming applications.
  • All timestamps are in UTC.
  • The event description fields may include HTML markup. This application does not sanitize those fields and it's unclear if the upstream source should be trusted, so sanitize any output to avoid malicious cross-site scripting (XSS).
  • Results are returned only in JSON format.
  • Please do not hammer the APIs
  • Contact the contributors at HackGreenville Labs via Slack #hg-labs channel with any questions.

The Code

The code for the Events API is primarily located in /app-modules/

  • Controllers: api/src/Http/Controllers/
  • Resources: api/src/Resources/
  • Tests: api/tests/Feature/

Luma.com

The Luma events are pulled via public calendar URLs for each organizations.

  • These URLs are primarily used to render the calendar on the public organization pages and not part of the offical API
  • The official API, which requires a paid account, is limited to events for ones own organization
  • The public organization webpages also include JSON+LD markup if access to the public calendar URL were to cease.

The code for this service includes the following /app-modules/event-importer/

  • src/Services/LumaHandler.php
  • tests/Feature/LumaTest.php
  • tests/fixtures/luma/

Meetup.com

The Meetup GraphQL-ext API is used to query events. This version replaces an earlier, deprecated GraphQL version.

This API requires a paid Meetup Pro account, the cost of which is covered by RefactorGVL.

The code for this service includes the following /app-modules/event-importer/

  • src/Services/MeetupGraphqlExtHandler.php
  • tests/Feature/MeetupGraphqlExtTest.php
  • tests/fixtures/meetup-graphql/
  • Note: Ext is the latest Meetup API, while MeetupRest & MeetupGraphql are legacy / deprecated APIs we have yet to delete.

Eventbrite.com

The free Eventbrite API is used to syndicate the events for each organization using the service.

The code for this service includes the following /app-modules/event-importer/

  • src/Services/EventBriteHandler.php
  • tests/Feature/EventBriteTest.php
  • tests/fixtures/eventbirte/

Kudos to Past Contributors

  • Thanks to @Nunie123 for the initial development, and to @ramona-spence for sustaining the previous Python implementation.
  • Thanks to @bogdankharchenko for migrating the Python implementation to PHP / Laravel