Event Feed
The events endpoint returns a chronological feed of things that happened to your player: attacks dispatched and resolved, scouts returning with intel, research starting and finishing. It is the natural companion to the game state endpoint — state tells you where things stand now, events tell you what happened while you were away.
Endpoint
GET /api/v1/events/Requires authentication. Returns events scoped to the authenticated player, ordered newest-first.
Query Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
limit | int | 50 | Page size. Minimum 1, capped at 200. |
offset | int | 0 | Number of events to skip. Minimum 0, maximum 9,223,372,036,854,775,807 (the most any list’s offset takes; more is a 422). |
event_type | string | — | Optional exact-match filter, e.g. ?event_type=attack_resolved. Omit to receive all types. |
Response
The standard pagination envelope { "count", "limit", "offset", "results" }, where count is the total number of matching events and results holds the event objects for the requested page (newest-first):
{ "count": 2, "limit": 50, "offset": 0, "results": [ { "id": 42, "player_id": "uuid", "event_type": "attack_resolved", "data": { "attack_id": "uuid", "origin_town_id": "uuid", "target_town_id": "uuid", "attacker_won": true, "units_lost_attacker": { "swordsman": 3 }, "units_lost_defender": { "archer": 10 }, "resources_looted": { "wood": 120, "stone": 40 }, "returns_at": "2026-03-26T22:10:00Z", "role": "attacker" }, "occurred_at": "2026-03-26T21:40:00Z" }, { "id": 41, "player_id": "uuid", "event_type": "research_started", "data": { "technology_id": "military_tradition", "level": 2, "finished_at": "2026-03-26T23:00:00Z" }, "occurred_at": "2026-03-26T21:00:00Z" } ]}| Field | Type | Description |
|---|---|---|
id | int | Numeric event identifier. Strictly increasing, so it works well as a “last seen” cursor. |
player_id | uuid | Always the authenticated player — you only ever see your own events. |
event_type | string | One of the event types below. |
data | object | Type-specific payload, documented per event type below. |
occurred_at | datetime | When the event happened (server time, UTC). |
Event Types
Combat
See Combat & Raiding for the underlying mechanics.
attack_sent— logged for the attacker the moment an attack is dispatched.data:attack_id,origin_town_id,target_town_id,units(the composition you sent),arrives_at.attack_resolved— logged for both sides when the battle resolves on arrival. Both receive the same payload plus arolefield ofattackerordefender.data:attack_id,origin_town_id,target_town_id,attacker_won,units_lost_attacker,units_lost_defender,fortifications_lost_defender(the defender’s wall fortifications lost by type, before repair;{}when none),resources_looted,returns_at(nullwhen no attackers survived),colony_razed(trueif the battle destroyed a colony,falseif it did not,nullin a realm with no colonies),role. Medals:medals_change_attacker/medals_change_defender(counts) andmedals_awarded_attacker/medals_awarded_defender(the named medals behind them, medal_id -> count;{}when the battle earned none,nullin a realm that mints no medals).attack_returned— logged for the origin town’s owner when surviving units arrive back home and loot is credited to the town: the attacker, or — if the town was captured while the army was away — its new owner, who receives the survivors and loot (the spoils of war rule).data:attack_id,origin_town_id,target_town_id,attacker_won,resources_looted.
Support
See Support for how reinforcement works, including the population-capacity cap on arrival. “The sender” below is the player who sent the party, even if the town it left from has changed hands since (a party sent before senders were recorded: the origin town’s current owner).
support_arrived— logged for the sender when a support march reaches its target town.data:support_id,target_town_id,garrisoned_units(the subset that fit the target’s remaining population capacity and joined the garrison),overflow_units(the remainder, which never dismounts and rides the same march’s return leg home —{}when everything fit; everything, when the host no longer admits the sender).support_sent_home— a party standing in a host’s garrison was sent home before its time.data:support_id,target_town_id(the host),units(the survivors leaving the garrison),returns_at(when they are home),reason:dismissed— the host sent it home, logged for the sender — orno_longer_admitted— the relationship that admitted it ended, logged for the sender and for the host.
Valleys
See Valleys for the capture, abandon and reinforcement rules. Every valley event carries valley_id, valley_type, valley_level and owner_town_id (the city holding the valley after the event; null once abandoned).
valley_captured— logged for the captor when acapture-intent attack wins and takes the valley for the attacking city.data: the shared keys above,attack_id,previous_owner_town_id(nullif the valley was unowned).valley_lost— logged for the previous holder in the same moment, with the same payload.valley_capture_denied— logged for the attacker when acapture-intent attack won but could not take the valley and fell back to plunder.data: the shared keys,attack_id,reason—valley_cap(the capturing city’s Town Hall cap was full at arrival),already_owned(an earlier capture of yours landed first),no_survivorsorowner_gone; the same value is stamped on the attack’sintent_fallback_reason.valley_abandoned— logged for you when you abandon a valley.data: the shared keys (owner_town_idisnull),previous_owner_town_id.
Scouting
See Scouting for the full screening mechanics — a target garrisoning its own scouts can contest, and even destroy, an incoming mission.
scout_sent— logged when you dispatch a scouting mission.data:scout_id,origin_town_id,target_town_id,units,arrives_at,returns_at.scout_returned— logged for the player who sent the scouts when they make it home, carrying the intel they gathered — even if the town they left from was captured while they were away (a mission sent before senders were recorded: the origin town’s current owner). The owner of a captured origin, whose garrison the survivors join, getsinherited_scouts_returnedinstead (below). The report’sdata:scout_id,origin_town_id,target_town_id,detail_tier(how deep the report goes — see Detail tiers),wall_level_observed,loyalty_observed,units_observed(exact counts, tiers that reveal them),units_band_observed(count-word bands, tiers below that),resources_observed,fortifications_observed,research_observed(eachnullwhen the tier hid it),valley_type_observed,valley_level_observed,valley_owner_town_id_observed(a valley target’s type, level and holding city; allnullagainst a town or a barbarian),units_lost(scouts lost breaking the target’s screen on the way in, by unit type;nullwhen the mission was never contested),bounced(truewhen the target’s closed gates and higher Informatics turned the party away — it came home unharmed and every observation field isnull). Never logged for an intercepted mission — seescout_interceptedbelow.inherited_scouts_returned— logged for a town’s owner when scouts that an earlier owner of the town sent out come home to it after it changed hands: the survivors join your garrison (spoils of war), but the mission and its report stay their sender’s.data:town_id(the town they came home to),units(the scouts that joined its garrison, by unit type).scout_intercepted— logged for the sender (the player who sent the party, as forscout_returned) when the target’s screen holds (your party sent no more scouts than the target garrisoned): every scout dies and nothing comes home.data:scout_id,origin_town_id,target_town_id,units_lost(always the sender’s whole outbound party, by unit type).town_scouted— logged for the target’s current owner. With the town’s gates open, whenever an arriving scouting mission is contested — i.e. the target garrisoned at least one scout at the moment of arrival; never when the target had no scouts home (the mission still succeeds; the owner just never finds out). With the gates closed, on every arrival, carrying the Informatics draw-out’s verdict. Never logged for barbarian settlements (their garrisoned scouts still screen and die, just with nobody to notify).data:town_id(the target),origin_town_id(the scouting party’s origin),intercepted(trueif the screen held),units_lost(the target’s own scout losses, by unit type),attacker_units_lost(the scouting party’s losses, by unit type), and — closed gates only —bounced(true: your Informatics turned them away;false: theirs beat yours and they read the town).
Diplomacy
See Alliance Diplomacy for war declarations and truces.
war_declared— logged for both alliance Hosts when a war declaration is issued.data:relation_id,alliance_id(the Host’s own alliance),other_alliance_id,effective_at(when attacks open; until then neither side may attack the other).war_effective— logged for both alliance Hosts when the declaration takes effect. Same payload aswar_declared.war_ended— logged for both alliance Hosts when an effective war is broken (peace made; the two alliances go back to holding no relation).data:relation_id,alliance_id,other_alliance_id.truce_started— logged for you when you apply a Truce Agreement.data:truce_until,truce_cooldown_until.truce_ended— logged for you when your truce window closes.data:truce_until(the moment it ended),truce_cooldown_until(when you may truce again — the cooldown outlives the truce).
Alliances
See Join an Alliance by application.
alliance_application_accepted— logged for the applicant when an Officer or above accepts their application: they are now a member.data:alliance_id.alliance_application_rejected— logged for the applicant when their application is rejected. They may apply again at once.data:alliance_id.
Research
See Research for how technologies work.
research_started— logged when you begin researching a technology.data:technology_id,finished_at.research_completed— logged when the server marks the research finished (within a few seconds of its finish time).data:technology_id.
Economy
See Food upkeep & desertion for the full mechanic.
desertion— logged whenever a settle sheds units to keep a town’s food from going negative.data:town_id,deserted_units(unit_type_id -> count deserted this settle).
Fortune Wheel
See Fortune Wheel for how spins are earned and spent, and why the wheel’s outcome is not random.
spin_earned— logged whenever a spin is credited to your balance, from any of the wheel’s play sources.data:source(one ofpvp_win,npc_clear,quest_claim,achievement,promotion,daily),count(spins credited by this event),spins(your balance immediately after).spin_spent— logged when you take a spin.data:prize_id,kind(resources,medalsoritem),resources(the bundle delivered to your oldest town,{}otherwise),medals(the named medals credited, medal_id -> count,{}otherwise),spins(your balance immediately after).
Quests
See Quests for triggers and rewards.
quest_claimed— logged once when you claim a quest’s reward.data:quest_id,reward(resources delivered totown_id, before storage caps),reward_items,reward_medals,reward_population(before the town’s capacity cap),reward_spins(the quest’s own spins; they and the realm’s per-claim spins, if any, are credited by onespin_earnedevent withsource: quest_claim),town_id(the reward town, your oldest).
Items
See Items for the catalog, the targets each kind needs, and why a ranged item’s payout is not random.
item_used— logged every time you use an inventory item, whatever its kind.data:item_id,kind(the catalog kind, e.g.medal_box,troop_chest,hero_xp),quantity(how many of the stack were spent),applied(exactly theappliedblock the use endpoint returned — the medals rolled, the troops delivered, the experience granted, and so on). A refused use logs nothing.
Titles and ranks
See Titles & Ranks.
title_promoted— logged when you climb one title.data:from_title_id(nullfrom Civilian),to_title_id,medal_costs(the named medals consumed, medal_id -> count),gold_cost,town_id(the town that paid).rank_promoted— logged when you climb one rank.data:from_rank_id(nullfrom Civilian),to_rank_id,medal_costs,gold_cost,town_id.
Additional event types may be added as new features ship; treat unknown event_type values as something to skip rather than an error.
Key Notes
- Newest-first — the first element is the most recent event. Page deeper with
offsetfor older history. - Defender notifications —
attack_resolvedis the only way a defender learns the full outcome of a battle, including the attacker’s losses. There is no event for an attack being sent at you: incoming attacks surface in the game state only as far as the target town’s Watchtower reveals them (beacon warning tiers). - Resolver-driven events (
attack_resolved,attack_returned,valley_captured,valley_lost,valley_capture_denied,scout_returned,inherited_scouts_returned,scout_intercepted,town_scouted,support_arrived,research_completed) are written by the background resolver within a few seconds of their due time — there is no need to call anything to trigger them. - Filtering is an exact match on a single type. An unrecognized
event_typevalue simply returns an emptyresultsarray (count0).
Usage
import httpx
client = httpx.AsyncClient( base_url="https://YOUR-RESTFALL-HOST", headers={"Authorization": f"Bearer {token}"},)
# React to anything new since the last loop iterationres = await client.get("/api/v1/events/", params={"limit": 50})events = res.json()["results"]
new_events = [e for e in events if e["id"] > last_seen_id]for event in new_events: if event["event_type"] == "attack_resolved" and event["data"]["role"] == "defender": print(f"We were attacked! Won: {not event['data']['attacker_won']}") elif event["event_type"] == "research_completed": print(f"Research done: {event['data']['technology_id']}")
if events: last_seen_id = max(e["id"] for e in events)# Latest 50 eventscurl -H "Authorization: Bearer $TOKEN" \ https://YOUR-RESTFALL-HOST/api/v1/events/
# Only battle outcomescurl -H "Authorization: Bearer $TOKEN" \ "https://YOUR-RESTFALL-HOST/api/v1/events/?event_type=attack_resolved&limit=20"const res = await fetch("/api/v1/events/?limit=50", { headers: { Authorization: `Bearer ${token}` },});const events = (await res.json()).results;
const incoming = events.filter( (e) => e.event_type === "attack_resolved" && e.data.role === "defender",);console.log(`${incoming.length} battles fought at our towns recently`);