Live events
Retrieve the live events for a match.
- Refresh interval
- Once a minute
The path parameter is the match id, which comes from matches. The same events are part of get match by ID, alongside the rest of the match record.
The feed refreshes once a minute. For team level numbers use match statistics, and for the starting players use lineups.
Event types
| Type | Meaning |
|---|---|
Goal |
A player strikes the ball into the opposing team's goal. |
Own Goal |
A player strikes or deflects the ball into their own team's goal. |
Penalty |
A goal scored from the penalty spot after a foul or handball by the defending team inside the area. |
Missed Penalty |
The penalty taker failed to score, either missing the target or having the shot saved. |
Yellow Card |
A player is cautioned for unsporting behaviour or foul play. |
Red Card |
A player is sent off for serious foul play, violent conduct, or a second yellow. |
Substitution |
A player is replaced from the bench during a stoppage. |
VAR Goal Confirmed |
Video review confirms a goal is valid and stands. |
VAR Goal Cancelled |
Video review disallows a goal for an infringement. |
VAR Goal Cancelled - Offside |
Video review disallows a goal for offside. |
VAR Penalty |
Video review awards a penalty. |
VAR Penalty Cancelled |
Video review overturns a penalty already awarded. |
Polling a live match
Poll this endpoint once a minute while the match is in play, and stop once
the match state reaches one of its
terminal values. state on the matches response also carries the clock and
the score, so a single matches call tells you both whether to keep polling and what the
current score is.
Get match by ID also returns the events for a match, alongside its statistics. Certain popular leagues also carry the venue, weather forecast, news and referee.
Parameters
| Parameter | Type | Description |
|---|---|---|
idrequired
|
numberpath | Requested match id. |
Request
curl --request GET \
--url 'https://soccer.highlightly.net/events/{id}' \
--header 'x-rapidapi-key: YOUR_API_KEY'
const response = await fetch('https://soccer.highlightly.net/events/{id}', {
headers: {
'x-rapidapi-key': process.env.HIGHLIGHTLY_API_KEY
}
})
if (!response.ok) {
throw new Error(`Highlightly responded ${response.status}`)
}
const data = await response.json()
import os
import requests
response = requests.get(
'https://soccer.highlightly.net/events/{id}',
headers={
'x-rapidapi-key': os.environ['HIGHLIGHTLY_API_KEY'],
},
timeout=10,
)
response.raise_for_status()
data = response.json()
Response
teamLiveEventTeamrequired3 fields
idnumberrequired
logostring
namestringrequired
timestringrequired
typestringrequiredGoalOwn GoalPenaltyMissed PenaltyYellow CardRed CardSubstitutionVAR Goal ConfirmedVAR Goal CancelledVAR PenaltyVAR Penalty CancelledVAR Goal Cancelled - Offside
playerIdnumber
playerstring
assistingPlayerIdnumber
assiststring
substitutedstring
Example response
[
{
"team": {
"id": 13394673,
"logo": "https://example.com/logo/preview/66311.13394673",
"name": "Tersana"
},
"time": "45+1",
"type": "Goal",
"playerId": 63606907,
"player": "M. Mamdouh",
"assistingPlayerId": 0,
"assist": "J. Johanson",
"substituted": ""
}
]
Values are the examples declared in the OpenAPI spec, not a captured live response.
Errors
| Status | Description |
|---|---|
400 |
Bad request descriptive error. |
500 |
Internal server error. |