Title: Building a Machine-Readable List of WordPress Events
Author: squidboylan
Published: 2017-02-10
Last modified: 2023-02-28

---

 [  ](https://profiles.wordpress.org/squidboylan/) [squidboylan](https://profiles.wordpress.org/squidboylan/)
18:54 _on_ 2017-02-10     
Tags: [Hosting Community ( 124 )](https://make.wordpress.org/hosting/tag/hosting-community/)

# Building a Machine-Readable List of WordPress Events

In [#hosting-community](https://wordpress.slack.com/archives/hosting-community/),
[it was brought up](https://make.wordpress.org/hosting/2017/01/18/hosting-meeting-notes-january-18-2017/)
that several hosts are interested in collecting data of local WordCamps and WordPress
Meetups to promote attendance to customers. With many events happening around the
world, the first task is to build a reliable source of data. The most important 
WordPress-related events are collected in two places: [WordCamp Central](https://wordcamp.org)
and [Meetup](https://meetup.com). Both sites have APIs to retrieve these lists.

### WordCamp CentralWordCamp Central Website for all WordCamp activities globally. 󠀁[https://central.wordcamp.org](https://central.wordcamp.org)󠁿 includes a list of upcoming and past camp with links to each. Events

The WordCamp Central APIAPI An Application Programming Interface (API) is a computing
interface that defines interactions between multiple software intermediaries. It
defines the kinds of calls or requests that can be made, how to make them, the data
formats that should be used, the conventions to follow, etc. does not require an
API key, so no setup is required. To pull the last 100 modified WordCampWordCamp
WordCamps are casual, locally-organized conferences covering everything related 
to WordPress. They're one of the places where the WordPress community comes together
to teach one another what they’ve learned throughout the year and share the joy.
[Learn more](https://central.wordcamp.org/about/). events use the following request:

`[user@localhost]$ curl -g 'https://central.wordcamp.org/wp-json/posts?type=wordcamp&
filter[posts_per_page]=100'`

The response is formatted as JSONJSON JavaScript Object Notation (JSON) is an open
standard file format, and data interchange format, that uses human-readable text
to store and transmit data objects consisting of attribute–value pairs and array
data types. It is a very common data format, with a diverse range of applications,
such as serving as a replacement for XML in AJAX systems.. If `filter[posts_per_page]`
isn’t added, you’ll get only the default amount of results (8, at the time of writing
this). To get a more readable output, you can use `jq` and `less` on Linux/MacOS(
you may need to install `jq` using your package manager):

`[user@localhost]$ curl -g 'https://central.wordcamp.org/wp-json/posts?type=wordcamp&
filter[posts_per_page]=100' | jq '.' | less`

The top level element is a list. Each element in the list is an objectObject In 
computer science, an object can be a variable, a data structure, a function, or 
a method, and as such, is a value in memory referenced by an identifier. with key/
value pairs. The `post_meta` element is a list that contains objects for metadata
including location, Twitter hashtag, start and end date (in epoch format), and other
useful details of approved WordCamps. The location does not follow a strict format
and is usually “city, country” or “city, state” if in the United States, but some
WordCamps follow a slightly different format, and the Community Team [has suggested an effort](https://make.wordpress.org/community/2017/01/19/wordcamp-location-consistency/)
to standardize format and normalize the previous values. A good next step is to 
connect with the Community team to see if the HostingHosting A web hosting service
is a type of Internet hosting service that allows individuals and organizations 
to make their website accessible via the World Wide Web. team can help out here,
since that will make it so that the country retrieved will always be accurate.

### MeetupMeetup All local/regional gatherings that are officially a part of the WordPress world but are not WordCamps are organized through 󠀁[https://www.meetup.com/](https://www.meetup.com/)󠁿. A meetup is typically a chance for local WordPress users to get together and share new ideas and seek help from one another. Searching for ‘WordPress’ on meetup.com will help you find options in your area. Events

The other source of events is on Meetup Their API requires a developer key, which
can be [created for free](https://secure.meetup.com/meetup_api/key/). To get a JSON
formatted object of all scheduled WordPress Meetups, use:

`[user@localhost]$ curl -g "https://api.meetup.com/2/events?member_id=72560962&key
=$KEY&sign=true"`

Be sure to change `$KEY` in the URLURL A specific web address of a website or web
page on the Internet, such as a website’s URL www.wordpress.org to your API key 
or it will not work. Again, you can use `jq` and `less` to parse the JSON:

`[user@localhost]$ curl -g "https://api.meetup.com/2/events?member_id=72560962&key
=$KEY&sign=true" | jq '.' | less`

The `member_id` value `72560962` is the `id` for the WordPress Foundation Meetup
account, and by specifying this, the API returns all WordPress official events, 
rather than the events for a single Meetup group.

The JSON that the Meetup API returns has a different schema than the WordCamp Central
API JSON responses. For Meetup, the top level entity is an object, and the main 
key to look at is `results`. This contains a list of objects, and each object represents
a WordPress Meetup. Each Meetup has a lot of metadata associated with it. Some important
ones to know about are `time`, which is in `epoch format * 1000`, `venue`, which
is an object with information about the venue, `name`, which is the name of the 
WordPress Meetup, and `event_url`, which is the website for the event. The `venue`‘
s `localized_country_name` and `city` keys can be used together to replicate the
WordCamp API’s `location` object.

### Bringing it All Together

To get the full list of WordCamps and Meetups, a script is needed to pull from both
sources and combine them into one list. An example script can be [found on GitHub](https://github.com/squidboylan/wordpress-meetup-scraper)
to see how a host might retrieve the data and combine the two sources. There is 
also an [Official WordPress Events](https://meta.trac.wordpress.org/browser/sites/trunk/wordpress.org/public_html/wp-content/plugins/official-wordpress-events)
pluginPlugin A plugin is a piece of software containing a group of functions that
can be added to a WordPress website. They can extend functionality or add new features
to your WordPress websites. WordPress plugins are written in the PHP programming
language and integrate seamlessly with WordPress. These can be free in the WordPress.
org Plugin Directory or can be cost-based plugin from a third-party., which creates
[this page](https://make.wordpress.org/community/events/), that can be used.

[#hosting-community](https://make.wordpress.org/hosting/tag/hosting-community/)

### Share this:

 * [  Threads ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=threads)
 * [  Mastodon ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=mastodon)
 * [  Bluesky ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=bluesky)
 * [  Tumblr ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=tumblr)
 * [  Facebook ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=facebook)
 * [  X ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=x)
 * [  LinkedIn ](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?share=linkedin)

 * [Login to Reply](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fmake.wordpress.org%2Fhosting%2F2017%2F02%2F10%2Fbuilding-a-machine-readable-list-of-wordpress-events%2F%23respond&locale=en_US)

### Like this:

Like Loading…

 1.  ![](https://secure.gravatar.com/avatar/479f05d4acc73915a43b24a1ee3f30477d4ee19bbec6a5a79906d396f2b2d2ad?
     s=32&d=mm&r=g)
 2.   [Samuel Sidler](https://profiles.wordpress.org/samuelsidler/)  01:27 _on_ 2017-
     02-11
 3.  Fwiw, the +make.wordpress.org/meta team has been working on an Events APIAPI An
     Application Programming Interface (API) is a computing interface that defines 
     interactions between multiple software intermediaries. It defines the kinds of
     calls or requests that can be made, how to make them, the data formats that should
     be used, the conventions to follow, etc. for official WordPress events. [Some code is here.](https://meta.trac.wordpress.org/browser/sites/trunk/api.wordpress.org/public_html/events)
     I’m unclear why this effort is being done as part of the hostingHosting A web 
     hosting service is a type of Internet hosting service that allows individuals 
     and organizations to make their website accessible via the World Wide Web. team
     versus working with the +make.wordpress.org/community and metaMeta Meta is a term
     that refers to the inside workings of a group. For us, this is the team that works
     on internal WordPress sites like WordCamp Central and Make WordPress. teams on
     it.
 4.  There’s also the [Official WordPress Events plugin](https://meta.trac.wordpress.org/browser/sites/trunk/wordpress.org/public_html/wp-content/plugins/official-wordpress-events)
     that’s installed [here](https://make.wordpress.org/community/events/).
 5.  Both of these options seem better than building something from scratch.
 6.   * ![](https://secure.gravatar.com/avatar/ae4a4e54f58de7f040c1caef738bb56f5ccaf16b0eed9b2304df92826609d3ca?
        s=32&d=mm&r=g)
      *  [Mike Schroder](https://profiles.wordpress.org/kirasong/)  19:02 _on_ 2017-
        02-11
      * The effort was/is meant to be discovery, which resulted in this post as documentation
        of that discovery. I expect that anything going forward would be handled either
        by/with the community and metaMeta Meta is a term that refers to the inside
        workings of a group. For us, this is the team that works on internal WordPress
        sites like WordCamp Central and Make WordPress. teams.
      * ![](https://secure.gravatar.com/avatar/ae4a4e54f58de7f040c1caef738bb56f5ccaf16b0eed9b2304df92826609d3ca?
        s=32&d=mm&r=g)
      *  [Mike Schroder](https://profiles.wordpress.org/kirasong/)  19:03 _on_ 2017-
        02-11
      * Ah, and forgot to mention, thanks for pointing to the official events pluginPlugin
        A plugin is a piece of software containing a group of functions that can be
        added to a WordPress website. They can extend functionality or add new features
        to your WordPress websites. WordPress plugins are written in the PHP programming
        language and integrate seamlessly with WordPress. These can be free in the 
        WordPress.org Plugin Directory or can be cost-based plugin from a third-party.!
      * ![](https://secure.gravatar.com/avatar/17ba53c40ebadf4731835ad362d1e2f329c7a8ef3eb7b20cbf9032a5c6f4d63e?
        s=32&d=mm&r=g)
      *  [squidboylan](https://profiles.wordpress.org/squidboylan/)  18:05 _on_ 2017-
        02-15
      * I edited the post to mention the official events pluginPlugin A plugin is a
        piece of software containing a group of functions that can be added to a WordPress
        website. They can extend functionality or add new features to your WordPress
        websites. WordPress plugins are written in the PHP programming language and
        integrate seamlessly with WordPress. These can be free in the WordPress.org
        Plugin Directory or can be cost-based plugin from a third-party., thanks for
        bringing that up!
 7.  ![](https://secure.gravatar.com/avatar/9cc64cf0f650f165ac55f1294105259f82f2b72c4c24903a79af6d6cd1ad2a9a?
     s=32&d=mm&r=g)
 8.   [Corey McKrill](https://profiles.wordpress.org/coreymckrill/)  18:49 _on_ 2017-
     02-22
 9.  Noting here that WordCamp CentralWordCamp Central Website for all WordCamp activities
     globally. [https://central.wordcamp.org](https://central.wordcamp.org) includes
     a list of upcoming and past camp with links to each. now supports the v2 REST 
     APIREST API The REST API is an acronym for the RESTful Application Program Interface(
     API) that uses HTTP requests to GET, PUT, POST and DELETE data. It is how the 
     front end of an application (think “phone app” or “website”) can communicate with
     the data store (think “database” or “file system”)
      [https://developer.wordpress.org/rest-api/](https://developer.wordpress.org/rest-api/)
     for querying WordCamps.
 10. The v2 equivalent of [@squidboylan](https://profiles.wordpress.org/squidboylan/)‘
     s example above would be:
 11. `[user@localhost]$ curl -g 'https://central.wordcamp.org/wp-json/wp/v2/wordcamps?
     per_page=100'`
 12. And if you want to pull only upcoming camps:
 13. `[user@localhost]$ curl -g 'https://central.wordcamp.org/wp-json/wp/v2/wordcamps?
     status=wcpt-scheduled&per_page=100'`

### Leave a Reply 󠀁[Cancel reply](https://make.wordpress.org/hosting/2017/02/10/building-a-machine-readable-list-of-wordpress-events/?output_format=md#respond)󠁿

You must be [logged in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fmake.wordpress.org%2Fhosting%2F2017%2F02%2F10%2Fbuilding-a-machine-readable-list-of-wordpress-events%2F&locale=en_US)
to post a comment.

This site uses Akismet to reduce spam. [Learn how your comment data is processed.](https://akismet.com/privacy/)

# Post navigation

[← Hosting Meeting Notes: February 1, 2017](https://make.wordpress.org/hosting/2017/02/02/hosting-meeting-notes-february-1-2017/)

[Hosting Meeting Notes: February 8, 2017 →](https://make.wordpress.org/hosting/2017/02/15/hosting-meeting-notes-february-8-2017/)