Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/kjohnson/sportspress-api

A small, incomplete, API for the SportsPress WordPress plugin.
https://github.com/kjohnson/sportspress-api

Last synced: 20 days ago
JSON representation

A small, incomplete, API for the SportsPress WordPress plugin.

Awesome Lists containing this project

README

        

# SportsPress API

A small, incomplete, API for the SportsPress WordPress plugin.

## Example Usage

Get Games by Venue:
```php
get_events_by_venue( $venue_id );
```

Get Games that are scheduled for today:
```php
->today()
```

Include the teams for each game:
```php
->with( 'teams' )
```

Include the teams and results for each game:
```php
->with( [ 'teams', 'results' ] )
```

Get Games by Venue, for today only, include teams and results:
```php
$events = SP_API()->with( [ 'teams', 'results' ] )->today()->get_events_by_venue( $venue_id );
```