Match Resources

class soccermetrics.rest.resources.match.MatchConditions(play, base_uri, auth)[source]

Access to Match Conditions resources (/<play>/matches/conditions resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchGoals(play, base_uri, auth)[source]

Access to Match Goals resources (/<play>/matches/goals resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchInformation(play, base_uri, auth)[source]

Access to Match Information resources (/<play>/matches/info resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchLineups(play, base_uri, auth)[source]

Access to Match Lineups resources (/<play>/matches/lineups resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchOffenses(play, base_uri, auth)[source]

Access to Match Offenses resources (/<play>/matches/offenses resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchPenalties(play, base_uri, auth)[source]

Access to Match Penalties resources (/<play>/matches/penalties resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchPlay(play, base_uri, auth)[source]

Access to Match objects for a specific type of match (club, national team).

Attribute Description
information Match information
lineups Match lineups
conditions Match conditions
goals Goal events
penalties Penalty kick events
offenses Disciplinary events
substitutions Substitution events
shootouts Penalty shootout events
stats Match statistics
events Match micro-events
class soccermetrics.rest.resources.match.MatchResource(play, base_uri, auth)[source]

Represents a Match REST resource (<play>/matches/<resource> endpoints).

The Match Resources are a collection of macro-events, micro-events, and summary statistics resources in the Soccermetrics Connect API.

Derived from resources.Resource.

EndpointURI()[source]

Construct URI of Match REST resource.

URI is of format /matches/<match>/<resource>/.

Returns:URI of REST resource.
Return type:string
get(match=None, uid=None, **kwargs)[source]

Retrieves a representation of Match REST resource.

If the status code is 200 (OK), returns the representation. Otherwise, returns an error.

Parameters:
  • match (integer) – Unique ID associated with football match.
  • uid (integer) – Unique ID of API resource representation.
  • kwargs (dict) – Collection of query parameters.
Returns:

Resource representation.

Return type:

Return value of MatchResource.get().

head()[source]

Retrieves header data of Match REST resource.

Returns:Header data.
Return type:Return value of MatchResource.head().
options()[source]

Retrieves documentation of Match REST resource.

If the status code is 200 (OK), returns the documentation. Otherwise, returns an error.

Link resources are not included in the documentation.

Returns:Resource documentation data.
Return type:Return value of MatchResource.options().
class soccermetrics.rest.resources.match.MatchShootouts(play, base_uri, auth)[source]

Access to Match Shootouts resources (/<play>/matches/shootouts resource).

Derived from MatchResource.

class soccermetrics.rest.resources.match.MatchSubstitutions(play, base_uri, auth)[source]

Access to Match Substitutions resources (/<play>/matches/substitutions resource).

Derived from MatchResource.

class soccermetrics.rest.resources.events.MatchEventResource(play, resource, base_uri, auth)[source]

Represents a Match Event REST resource.

The Match Event resource controls access to data about the micro-events in a football match, such as ball touches, non-touch events, positional data, and explanatory data related to touch events.

Micro-events are modelled as a combination of three components: events, actions, and modifiers.

Derived from base.Resource.

class soccermetrics.rest.resources.events.MatchEvents(play, base_uri, auth)[source]

Establish access to Match Event objects (/<play>/events/<resource> endpoint).

Attribute Description
all All micro events
touches All touch events
actions All event actions
class soccermetrics.rest.resources.statistics.CrossingStatistics(play, base_uri, auth)[source]

Establish access to Cross statistical resources (/<play>/stats/crosses endpoint).

Attribute Description
corners Crosses from corners
totals Total crossing stats
class soccermetrics.rest.resources.statistics.DefensiveStatistics(play, base_uri, auth)[source]

Establish access to Defensive statistical resources (/<play>/stats/defense endpoint).

Attribute Description
actions Defensive actions
blocks Shot block stats
clearances Ball clearance stats
goalline Goal-line clearance stats
tackles Tackling stats
class soccermetrics.rest.resources.statistics.FoulingStatistics(play, base_uri, auth)[source]

Access to Foul statistical resources (/<play>/stats/fouls endpoint).

Attribute Description
cards Card stats
wins Foul suffered stats
class soccermetrics.rest.resources.statistics.GoalStatistics(play, base_uri, auth)[source]

Access to Goal statistical resources (/<play>/stats/goals endpoint).

Attribute Description
assists Goal assist stats
bodyparts Goalscoring bodypart stats
locations Goalscoring location stats
penalties Match penalty stats
totals Total goalscoring stats
class soccermetrics.rest.resources.statistics.GoalkeepingStatistics(play, base_uri, auth)[source]

Access to Goalkeeper statistical resources (/<play>/stats/goalkeeper endpoint).

Attribute Description
actions Goalkeeping action stats
goals Goals allowed stats
shots Shots allowed stats
saves Goalkeeper saves stats
class soccermetrics.rest.resources.statistics.MatchStatistics(play, base_uri, auth)[source]

Establish access to Match Statistics objects (/<play>/stats endpoints).

Attribute Description
crosses Crossing statistics
defense Defensive statistics
fouls Foul statistics
goals Goal statistics
goalkeeper Goalkeeping statistics
passes Passing statistics
setpieces Set-piece statistics
shots Shot statistics
touches Ball touch statistics
class soccermetrics.rest.resources.statistics.MatchStatisticsResource(play, statistic, resource, base_uri, auth)[source]

Represents a Match Statistics REST resource.

The Match Statistics resources controls access to summary in-match statistical data of players who are in the match lineups of a football match.

Derived from base.Resource.

class soccermetrics.rest.resources.statistics.PassingStatistics(play, base_uri, auth)[source]

Access to Passing statistical resources (/<play>/stats/passes endpoint).

Attribute Description
directions Pass direction stats
lengths Pass length stats
locations Pass location stats
totals Total passing stats
class soccermetrics.rest.resources.statistics.SetPieceStatistics(play, base_uri, auth)[source]

Access to Set-Piece statistical resources (/<play>/stats/setpieces endpoint).

Attribute Description
corners Corner kick stats
freekicks Direct freekick stats
throwins Throw-in stats
class soccermetrics.rest.resources.statistics.ShotStatistics(play, base_uri, auth)[source]

Access to Shot statistical resources (/<play>/stats/shots endpoint).

Attribute Description
bodyparts Shot bodypart stats
locations Shot location stats
plays Shot play stats
totals Total shot stats
class soccermetrics.rest.resources.statistics.TouchStatistics(play, base_uri, auth)[source]

Access to Touch statistical resources (/<play>/stats/touches endpoint).

Attribute Description
duels 50/50 dueling stats
locations Ball touch location stats
totals Total ball touch stats