<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: -"
  ],
  "documentType" : "symbol",
  "framework" : "EnergyKit",
  "identifier" : "/documentation/EnergyKit/EnergyVenue/submitEvents(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "EnergyKit"
    ],
    "preciseIdentifier" : "s:9EnergyKit0A5VenueV12submitEventsyySayxGYaKAA27ElectricalLoadEventProtocolRzlF"
  },
  "title" : "submitEvents(_:)"
}
-->

# submitEvents(_:)

Submits electrical load events to be used by EnergyKit to generate energy insights.

```
func submitEvents<Event>(_ events: [Event]) async throws where Event : ElectricalLoadEventProtocol
```

## Parameters

`events`

An array of [`ElectricalLoadEventProtocol`](/documentation/EnergyKit/ElectricalLoadEventProtocol) conforming  load events to send.

## Discussion

The submission may contain events for multiple devices.
The system throws [`EnergyKitError.invalidLoadEvent`](/documentation/EnergyKit/EnergyKitError/invalidLoadEvent) if a
load event is submitted for an incorrect
[`EnergyVenue`](/documentation/EnergyKit/EnergyVenue) or if it’s submitted by an iPhone, iPad, or Mac
that didn’t fetch the corresponding [`ElectricityGuidance`](/documentation/EnergyKit/ElectricityGuidance).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)