1. Ordering Aya
We appreciate your interest in the Aya demand-side management system. Please consider the following to ensure the system you order is the perfect fit:
1.1 The ordering process
Ordering Aya is straightforward and flexible.

New to demand-side management? We recommend scheduling a free online demonstration with an Exera representative through the "Get demo" button. During this session, we'll work together to evaluate the potential of demand shaping to address your grid's specific requirements and discuss relevant revenue and funding opportunities, including grants and subsidies. You will also get a firsthand look at Aya in action. After the demo, you can request a free trial of an Aya in-home device to test within your organization (shipping is included).

Familiar with demand-side management? Order Aya directly through aya@exera.org by specifying your requirements, including features, quantity, shipping and branding preferences. An Exera representative will then personally review your order and work with you to get the most out of your Aya deployment, serving as your dedicated point of contact for any questions or updates.
Exera is based in the EU (The Netherlands). Order Aya from any country in the world; our global logistics partners ensure smooth and efficient fulfillment to customers worldwide.

For specialized needs such as firmware modifications or self-hosting options, please e-mail aya@exera.org to connect with an Exera representative. We're happy to discuss your unique needs and tailor a solution that works best for you.

Aya's all-inclusive pricing is designed for predictable budgeting, covering the in-home devices themselves, lifetime operational costs and support. To maximize affordability, we offer flexible payment terms beyond our standard 5%/10 Net 30, and will assist your organization in applying for grants (e.g. by providing necessary documentation) which could cover the entire cost of your demand-side management program. Please refer to the terms and conditions for complete details.


1.2 Funding opportunities for Aya: leveraging grants and subsidies
Governments and organizations worldwide are increasingly recognizing the importance of demand-side management for grid stability and renewable energy integration. As a result, various grants and subsidies are available to support the deployment of technologies like Aya.
  • European Union: the EU offers significant funding opportunities for demand-side management technologies like Aya. Funds include Horizon Europe (including the BRIDGE program) and LIFE: clean energy transition to support projects that enhance grid flexibility and integrate renewables. National funding opportunities within individual member states also present avenues for securing financial support for deploying Aya.
  • United States: in the US, the Department of Energy (DOE) offers various grants and funding opportunities for smart grid and demand response programs. The Grid Modernization Initiative and the Grid Resilience and Innovation Partnerships (GRIP) program, for instance, support projects that enhance grid reliability, resilience and flexibility. State-level incentives, such as those offered through Public Utility Commissions, can also be explored.
  • China: the National Development and Reform Commission (NDRC) and the National Energy Administration (NEA) drive funding for smart grid development and demand-side management, often implemented through programs outlined in the Five-Year Plans for Energy Development.
  • India: the Bureau of Energy Efficiency (BEE) under the Ministry of Power plays a key role in implementing demand-side management programs. Initiatives like the National Smart Grid Mission (NSGM) and the National Mission for Enhanced Energy Efficiency (NMEEE) provide funding and support for smart grid technologies, including demand response. Additionally, state-level electricity regulatory commissions often offer incentives for demand-side management programs.
  • Other regions: many other countries and regions are implementing policies and funding programs to promote demand-side management. For example, Australia's Energy Security Board is exploring demand-side participation at the wholesale and retail levels, and various initiatives exist in countries like Canada, Indonesia, Saudi Arabia, Japan and South Korea.


1.3 Order quantity
Determine your Aya order quantity based on the number of households you're targeting. We recommend two Aya in-home devices per household, as users often prefer to place them near major energy-consuming appliances (like EV chargers and ovens) for optimal convenience and effectiveness. Add a 10% buffer to your order to ensure you have spares on hand for quick replacements should any issues arise. With Aya's low minimum order quantity, you can start with a smaller deployment and scale up seamlessly as your demand-side management program expands.

Example: (1.1M households targeted * 2 in-home devices per household) + 10% buffer = 2.42M order quantity (>1M households, Aya Pro preferred).


1.4 Branding and customization
Enhance your brand visibility with Aya's flexible customization options. You can personalize your Aya in-home devices with your company logo, reinforcing brand recognition with every interaction. Furthermore, with individualized shipping, you can include a personalized letter to tailor your messaging and connect directly with your customers. For more advanced customization requirements, such as unique device colors or tailored software interfaces, please reach out to Exera via aya@exera.org. We're ready to discuss your specific needs and develop a solution that perfectly aligns with your brand strategy.


1.5 Included with your order
Your Aya order includes everything you need for a seamless and successful deployment. Here's what's included:
  • Aya in-home devices: the requested quantity and model of Aya in-home devices, ready for immediate deployment to your target area. This includes a digital list of validated unique key codes, one for each Aya in-home device. Customers use these codes to activate their device during the initial setup, linking it to their specific household address and preventing unauthorized use.
    • Branding (optional): if specified during the ordering process, your Aya devices will be customized with your company logo, enhancing brand recognition and creating a cohesive customer experience.
    • Individualized shipping (optional): when individualized shipping is chosen, Exera manages the complete fulfillment process, packaging and shipping orders directly to your customers' addresses. For each specified address, we package the corresponding number of Aya devices in an envelope along with a personalized letter. This letter can incorporate custom fields, such as the unique key code(s) for the included device(s) and specific activation instructions. This ensures a smooth and efficient delivery and activation process, with all logistics handled by Exera. Alternatively, opt for bulk shipping to receive all devices at one location and manage distribution yourself. This option offers potential cost savings for larger deployments.
  • Aya Deployment Manager: with your Exera account, you gain access to the secure Aya Deployment Manager. Here, you can manage your deployment via your Aya system scripts, monitor analytics, and much more. This powerful tool provides comprehensive control and oversight of your demand-side management program.
  • Dedicated support: from initial order placement to ongoing operation, your dedicated Exera representative is available to answer any questions and provide assistance as needed. We're committed to ensuring your demand-side management program is a success.
  • Perpetual ownership license (optional): the perpetual ownership license grants you the right to use and operate the Aya system indefinitely. Upon the product's end-of-life, Exera will release all design files and source code (including firmware, CAD models and electrical schematics) to your organization. This ensures you have the necessary technical information for long-term system management and adaptability (included with Aya Pro).
  • Lifetime operational costs: the initial purchase price of your Aya devices covers all associated costs for the lifetime of the product. This includes the hardware itself, Aya Deployment Manager access (including the ability to create unique blink patterns for your in-home device fleet) and ongoing support.
    There are no hidden fees or recurring subscription charges. Exera is committed to providing a transparent and predictable cost structure for your Aya deployment.
2. The Aya in-home device
The Aya in-home device is at the heart of your demand-side management program. It simplifies demand shaping for both you and the consumer, translating complex grid data into easily understood visual cues. This enables you to manage energy demand at scale and significantly increase grid flexibility.
2.1 Overview
The Aya in-home device is a small, wireless, battery-powered, leaf-shaped IoT device that uses a blinking light to signal grid conditions directly to consumers. Its elegant, minimalist Dutch Design ensures it stands out as a noticeable yet aesthetically pleasing element in any home, serving as a positive reminder of the consumer's contribution to a greener future.

The device also features a button, data display (typically used for current energy prices) and a visual timeline showing projected energy availability for the next two hours when the button on the device is pressed. Its long battery life of 1-2 years on a set of user-replaceable AAA batteries, optimizes both user comfort and your program effectiveness.

Once connected to Wifi, the in-home device automatically follows the blink patterns you configure in the Aya Deployment Manager. Use a yellow blink to indicate high demand/prices or grid instability (reduce consumption, prevent overloading and congestion), and a blue blink for low demand/prices or excess renewable energy (increase consumption, prevent curtailment).

Thanks to its adhesive backing, users can easily place the Aya in-home device near energy-intensive appliances (like EV chargers and ovens) or in frequently viewed locations (like kitchens and living rooms). This ensures the device serves as a constant visual reminder to adjust energy usage. The intuitive blink patterns are easily understood by all demographics, making flexible energy usage an intuitive part of daily life. Because Aya offers such an immediate and clear visual cue for demand response, it uniquely motivates users to also engage with other demand-side management tools (like energy pricing apps), enhancing grid flexibility in ways that other tools alone cannot.

The primary function of the in-home device is to provide consumer demand shaping through clear visual signals. Additional features, configurable through the user-accessible Aya Configurator, include:
  • Energy Alert: this is the core functionality of the device, with the blue and yellow blinks signaling energy availability and pricing. The button press to light up the LED display and the two-hour energy timeline is part of this mode.
  • Smart Button: this feature enhances user engagement by allowing the button to trigger other smart home actions via GET requests, such as turning off non-essential appliances during peak demand. This functionality can further incentivize participation in demand response events and contribute to load reduction.
  • Smart Stopwatch: this built-in timer and stopwatch adds another layer of utility, allowing users to become more mindful of their daily routines, including water usage during showers, fostering a greater sense of resource awareness. This mode can also trigger external appliances via GET requests at the start and end of stopwatch sessions.
  • Aya Configurator: by long-pressing the button, users access Aya Configurator to tailor their Aya's behavior, including network settings, LED brightness and scheduling periods when blinking is disabled for undisturbed sleep or other preferences.
The Aya Deployment Manager is your central hub for controlling and monitoring your entire Aya deployment, accessible through your Exera account at https://login.exera.org.


2.2 Model features and specifications
Exera offers a diverse selection of in-home device models, each tailored to specific program requirements. This ensures you can find the optimal set of features and functionalities for your deployment.
Model: Aya Blink Aya Plus Aya Pro
In short: Aya Blink Aya Plus Aya Pro
Capabilities:
  • Basic Energy Alert: blink yellow to reduce demand
  • Basic Deployment Manager
  • Basic Energy Alert: blink yellow to reduce demand
  • Basic Deployment Manager
  • LED display for data (e.g. current energy price)
  • Timeline for upcoming blinks
  • Smart Stopwatch
  • Smart Button
  • Perpetual ownership license: fully future-proof, no vendor lock-in, get full source code
  • Priority support with expert engineering assistance
  • Advanced Energy Alert: blink yellow to reduce demand
  • Advanced Energy Alert: blink blue to increase demand and prevent curtailment
  • Advanced Deployment Manager
  • Analytics tailored to your program needs
  • Triggers to keep users engaged long-term
  • Advanced branding options
  • LED display for data (e.g. current energy price)
  • Timeline for upcoming blinks
  • Smart Stopwatch
  • Smart Button
Recommended for: Deployments up to 100,000 households Deployments up to 1,000,000 households Unlimited deployment size
Blink points: 50 max. in memory 120 max. in memory 270 max. in memory
Processor: 32 bit RISC-V, secure boot with encrypted and signed firmware
Wifi: 2.4GHz IEEE 802.11b/g/n, trust zone protected credentials, 21dBm Tx output power, -93dBm Rx sensitivity
Battery: 1-2 years battery life, 2x AAA LR03 (pre-installed), user-replaceable
Compliance: CE, RoHS
IP rating: IP67 (fully waterproof and immersible up to 1 meter for 30 minutes; only when adhered to a solid wall)
Housing: Semi-translucent emerald green rLDPE, adhesive backing
Dimensions: 105 x 55 x 14 mm (H x W x D)
Weight: 36 grams
Volume pricing: US$5.48/unit
US$0 with grants
US$6.47/unit
US$0 with grants
US$6.96/unit
US$0 with grants


2.3 Initial setup flow for consumers
The initial setup flow that consumers will experience after receiving their Aya in-home device is designed to be intuitive and user-friendly, requiring minimal technical expertise and taking about 30 seconds to complete. The screenshots below illustrate each step of the process:
Aya setup flow Aya setup flow Aya setup flow Aya setup flow Aya setup flow
1. Press the button until it blinks (Aya development hardware shown)
2. Connect to the Aya IHD via Wifi
3. Setup welcome screen
4. Network selector
5. Aya key code
3. Implementing and managing Aya
This section covers deploying, configuring and managing your fleet of Aya in-home devices, including setting up custom blink patterns and connecting Aya to your own systems (e.g. energy markets), for precision management of household energy demand at scale.
3.1 Architecture overview
The Aya system is a secure and modular platform comprised of two primary components: the Aya in-home devices, distributed to targeted households, and the Aya core network infrastructure.

Each in-home device has a unique key code, its secure identifier for all system interactions. You can download a digital list of valid key codes for your order via the Aya Deployment Manager. You are responsible for maintaining the mappings between key codes and customer addresses. Exera does not store any personally identifiable information (PII), such as address-to-key code mappings, ensuring consumer privacy. During initial setup, households connect the in-home device to WiFi and enter the key code they received from you (e.g. via a printed letter or e-mail). This securely links the specific in-home device to your account. Blink patterns can be customized for specific key codes, enabling targeted messaging down to the individual device level.

For optimum security, in-home devices initiate all communications; the infrastructure cannot contact an in-home device directly. All communications are encrypted via HTTPS, ensuring the integrity and confidentiality of operational data and preventing unauthorized access or manipulation.

Exera manages the key services that make up the core network infrastructure. Redundant, geographically dispersed systems ensure these services remain operational at all times:
  • Redirector service: this service acts as the initial point of contact for all Aya in-home devices. It receives the unique key code from each device and directs it to the appropriate customer-specific service.
  • Setup service: when a new Aya in-home device connects for the first time, it is routed to the setup service. This service validates the device's key code, performs security checks, registers the device and associates it with the relevant customer account.
  • Energy Alert service: after initial setup, subsequent connections from Aya in-home devices are directed to the Energy Alert service. This is the core demand management service of the Aya system, allowing customers to manage their in-home devices' blink patterns. It is designed to be developer-friendly, simplifying blink pattern programming. It interfaces with customer-provided blink scripts, enabling granular control over the visual cues displayed on each in-home device.


3.2 Deployment checklist
This checklist outlines the key steps for a smooth and effective Aya deployment:
  1. Plan and order:
    • Define your strategy: outline your demand-side management goals and how you'll use Aya to achieve them. Consult with an Exera representative (via aya@exera.org) to explore options and best practices.
    • Determine your requirements: determine the number of households you'll target, the corresponding number of Aya in-home devices (consider two per household and a 10% buffer) and any specific customization needs (branding, individualized shipping, etc.).
    • Inspire program adoption and engagement: develop a communication strategy that generates excitement and fosters a sense of collective purpose around your demand-side management program. Use clear, concise messaging across multiple channels (e-mail, social media, website, etc.) to highlight how participation directly and visibly contributes to a more sustainable energy future. Focus on creating a positive and engaging experience with Aya for all users. Provide easy-to-follow instructions, offer ongoing support, and celebrate program milestones and user achievements. Exera offers resources to help you maximize user engagement.
    • Place your order: contact a representative (via aya@exera.org) to place your order, specifying your chosen model, quantity and customization options.
  2. Configure the Aya Deployment Manager:
    • Set up secure access control: set a strong, unique password, update it regularly and ensure the e-mail address used for session validation is secured with two-factor authentication (2FA). Restrict access to approved IP addresses using IP whitelisting. Generate and regularly rotate API keys for integrations.
    • Configure hosting: choose between hosting the Aya system control scripts on your own servers or on Exera's infrastructure (note: Exera cannot store your PII). If self-hosting, configure the endpoint URLs of your scripts in the Deployment Manager.
    • Configure in-home device setup logic: customize the user experience during the initial device setup by modifying the messages presented through the Aya setup (check) and Aya setup (confirm) scripts. Define your validation logic to link the entered key code to the associated household address in your records.
    • Implement blink logic: develop the logic that determines your blink patterns to cue households according to your demand-side management strategy. Consider factors such as energy prices, local grid conditions, predicted congestion or a combination of factors. Ensure your script adheres to the Deployment Manager's expected data formats.
    • Perform thorough testing: before launching your program, test the entire setup, including device registration, blink script execution and data display, using a set of test devices. If self-hosting, ensure your testing environment accurately simulates your production environment. The Deployment Manager offers testing functionality with realistically simulated in-home devices for scripts hosted on the Exera infrastructure. Verify all security configurations, including password strength, IP whitelisting settings and API key security.
  3. Monitor and optimize:
    • Track device activations: monitor the number of devices that have been successfully activated and are actively cueing households.
    • Refine your strategy: based on the data you collect, adjust your blink patterns, communication strategy or other aspects of the program to maximize its impact. Consider utilizing A/B testing of different blink patterns and collecting feedback from users to understand their experience with the Aya program and identify areas for improvement.
    • Utilize triggers and advanced statistics: leverage the Advanced Deployment Manager (included with Aya Pro) to set up triggers based on specific events or conditions (e.g. low battery level, extended periods of device inactivity, specific user interaction patterns). Utilize these triggers to automatically send notifications or emails to users (e.g. reminders to replace batteries, prompts to engage with the program, sending compliments). Work with your Exera representative to create custom triggers and analytics tailored to your specific demand shaping strategy. Gain deeper insights into program performance and user behavior with advanced analytics and reporting features.


3.3 Getting familiar with the Aya Deployment Manager
The Aya Deployment Manager is the central hub for configuring and monitoring your entire Aya in-home device fleet. You can access the Deployment Manager securely through your Exera account at https://login.exera.org with your credentials and after passing session validation and the (optional) IP whitelist.
This section provides an introduction to its key features and functionalities, which are divided into five main sections:
  1. Customer Information: your account details, contact information for your Exera representative, order status and recent login history.
  2. Aya Deployment Manager Configuration: account management and IP whitelisting.
  3. Aya Redirector Configuration: Aya system script authorization key and hosting location.
  4. Aya Setup and Energy Alert Configuration: only available for Aya system scripts hosted by Exera; management and testing of in-home device setup and blink scripts.
  5. Aya Fleet Management: monitoring of deployed devices, key statistics, and (for Aya Pro devices) triggers and advanced statistics.
Aya DM
Overview of the Aya Deployment Manager

To facilitate the development process, preloaded example scripts for Aya setup (check), Aya setup (confirm) and Aya Energy Alert (blink data update) are provided within the Aya Deployment Manager. These examples, written in JavaScript, demonstrate the fundamental structure, expected inputs, and required output format for each script. They serve as a valuable starting point, allowing you to adapt and customize them to align with your specific requirements. This includes integrating with your existing customer database and implementing your unique validation logic.

You have the flexibility to host your scripts either on your own servers or using Exera's hosting infrastructure. When opting for hosting by Exera, your scripts are executed within a secure, sandboxed environment based on the V8 JavaScript engine. This environment enforces resource limits to ensure stability and security: the maximum script filesize is 5MB, scripts can run for a maximum of 5 seconds and utilize up to 8MB of memory. Standard JavaScript functions up to ES2020 are supported;
  • Exera hosting: when using hosting by Exera, be aware that request and response data are wrapped in the json_data JSON object. For instance, the key code can be accessed through json_data.aya_keycode. Similarly, your script's output should be written to this same json_data object as well.
    For scenarios requiring internet connectivity from within your scripts (e.g. accessing external APIs), Exera's hosting environment provides the web_query() function. This function is a security-enhanced implementation, based on the widely used fetch() API and shares a similar syntax.
    web_query() returns a JSON object with two keys, query_data and query_status. query_data contains the response data from your web_query() request, and query_status contains an integer with the HTTP response status code. Refer to the provided example code for proper usage of web_query() or check the fetch() API.
  • Self-hosting: if you choose to host your scripts on your own infrastructure, the request data is directly available in the request body, and your response should be a JSON object directly representing the output data.


3.4 Setting up the Aya setup logic
The Aya in-home device setup process securely registers each in-home device and links it to your Aya Deployment Manager (and corresponding system control scripts). Exera provides the core infrastructure for this process. You however are responsible to link key codes to household addresses, which will allow you to target specific households or groups with your demand shaping strategy.

The setup process relies on two customizable scripts within the Aya Deployment Manager: Aya setup (check) and Aya setup (confirm). These scripts work in sequence to validate the device and link it to your systems:
  • Aya setup (check): this script is invoked when a user initiates the in-home device' initial setup flow and enters a valid key code. The Aya Redirector service first verifies that the Aya in-home device hardware is genuine, that the key code is from your purchased set and has not yet been registered. Then, your Aya setup (check) script is executed. The script receives the key code, allowing you to perform the necessary checks on your end. A common use case is to retrieve the corresponding address data associated with that key code from your database. You can then display this address information to the user within the setup flow, prompting them to confirm it.
  • Aya setup (confirm): once the user confirms the address information presented during the Aya setup (check) stage, your Aya setup (confirm) script is triggered. This script holds the final authority on whether to register the device with the Aya system. In typical scenarios, user confirmation of the address would lead your script to proceed with registration. Upon successful execution, this script registers the device's key code with the Aya Redirector service. This crucial step enables the device to connect to your system and begin actively polling for your demand shaping data, allowing it to respond to your configured blink patterns.
Key codes are designed with high entropy and contain embedded verification data. This makes it very difficult for a user to guess a valid key code or to register a device with an incorrect one, ensuring the integrity of the setup process.

Writing the Aya setup (check) script:
  • Input: Aya Redirector will send a HTTP(S) POST request to the URL you specified for your Aya setup (check) script (or populates the json_data object of the Exera hosted Aya setup (check) script) with this JSON object in its request body:
    JSON
  • Expected processing: the Aya setup (check) script displays address data (or other identity verification information) in the initial user setup flow for an Aya in-home device, which the user has to confirm. The script should query your key code to address database and return the corresponding address data.

    Example:
    JavaScript
  • Expected output: return the Aya Redirector HTTP(S) POST request with a JSON object (or, for an Exera hosted Aya setup (check) script, populate the json_data object) containing the following fields:
    JSON
    Aya Redirector will only let the user continue the initial setup flow when "aya_keycode_validity" is set to "1"; any other value will show an error to the user and ask to put in the key code again.

Writing the Aya setup (confirm) script:
  • Input: Aya Redirector will send a HTTP(S) POST request to the URL you specified for your Aya setup (confirm) script (or populates the json_data object of the Exera hosted Aya setup (confirm) script) with this JSON object in its request body:
    JSON
  • Expected processing: a request to your Aya setup (confirm) script indicates that the uses has confirmed the address you showed with the the Aya setup (check) step. The Aya setup (confirm) script should update your key code to address database to administer that this key code to address mapping is valid and ready to receive demand shaping blink commands.
    Return your confirmation of registering this key code, and return the name of the data source for your demand shaping blinks (which is shown in the Aya Configurator on the in-home device).

    Example:
    JavaScript
  • Expected output: return the Aya Redirector HTTP(S) POST request with a JSON object (or, for an Exera hosted Aya setup (confirm) script, populate the json_data object) containing the following fields:
    JSON
    Aya Redirector will only let the user pass the initial setup flow when "aya_keycode_validity_confirmed" is set to "1"; any other value will show an error to the user and ask to put in the key code again.
    After the confirmation of the Aya setup (confirm) script, the corresponding in-home device is registered in the Aya Redirector service and will begin actively polling for your demand shaping data, allowing it to respond to your configured blink patterns.


3.5 Setting up the Aya Energy Alert blink logic
The Aya Energy Alert service allows you to define the blink patterns displayed on your Aya in-home devices based on your demand shaping strategy.

Your Aya Energy Alert (blink data update) script is invoked when an in-home device has displayed all blink data points that were stored in its memory.
Blink data points are sequentially removed from memory after they have been displayed. When the device's blink point memory is empty, it automatically initiates a request to the Aya Redirector to update its blink point memory. This ensures that the device always has a relevant set of blink data points to display. Consequentially, this means that the number of blink data points you provide in each update directly determines the frequency of these update requests. In the event of a network connection failure or an issue with your backend systems that is not solved within 5 retries, the in-home device will persistently attempt to reconnect to the Aya Redirector every 2 hours.

The Aya system provides fine-grained control over the visual cues sent to in-home devices. Each blink data point you provide defines a starting time in minutes (relative to the time of the data update), a blink type, and optionally data to display on the device's screen (Aya Plus and Pro models only). The specified blink type becomes active at the defined starting time and remains active until the starting time of the next blink data point. Aya Pro supports up to 270 blink points per update, allowing you to define very detailed demand shaping sequences. This minute-by-minute control enables you to accurately reflect real-time grid conditions and shape energy demand with high precision.

You can select pre-defined blink types for every blink data point, each designed to communicate different levels of urgency or opportunity. You have the flexibility to define the specific meaning of each blink type within your demand-side management program. For users of Aya Pro, Exera offers the ability to create custom blink types beyond the pre-defined set. You can work with your Exera representative to design blink patterns that perfectly align with your specific program needs and messaging goals.
The available pre-defined blink types are:
  • no_blink: no blinking.
  • blink_yellow_low: one slowly fading yellow blink every 60 seconds to reduce energy demand.
  • blink_yellow_moderate: two quickly fading yellow blinks every 40 seconds to reduce energy demand.
  • blink_yellow_high: three prominent yellow blinks every 20 seconds to reduce energy demand.
  • blink_blue_low: one slowly fading blue blink every 60 seconds to increase energy demand (included with Aya Pro).
  • blink_blue_moderate: two quickly fading blue blinks every 40 seconds to increase energy demand (included with Aya Pro).
  • blink_blue_high: three prominent blue blinks every 20 seconds to increase energy demand (included with Aya Pro).
All blink types, except for no_blink, are automatically displayed on the timeline feature of Aya Plus and Aya Pro devices. Blue blinks are represented as blinking segments on the timeline, while yellow blinks are shown as solid segments. This provides users with a visual preview of upcoming demand periods.

Beyond the visual blink cues, each blink data point JSON also includes a "data_on_display" key to update the screen on Aya Plus and Aya Pro devices. This enables you to provide users with relevant contextual information, such as real-time energy prices, demand reduction targets or other key metrics. The screen supports displaying three digits with a decimal separator after the first digit (e.g. "1.23"), integers (e.g. "123"), and the percentage sign ("%") as a special character appended to a number (e.g. "12%"). When "data_on_display" is set to an empty string, no information is shown on the display for that blink data point.

Writing the Aya Energy Alert (blink data update) script:
  • Input: Aya Redirector will send a HTTP(S) POST request to the URL you specified for your Aya Energy Alert (blink data update) script (or populates the json_data object of the Exera hosted Aya Energy Alert (blink data update) script) with this JSON object in its request body:
    JSON
  • Expected processing: a request to your Aya Energy Alert (blink data update) script indicates that in-home device has displayed all of its internally stored blink data points and needs new blink data. Your script should provide this data according to the specified blink data format and your demand shaping strategy. You also have to return the timezone offset of the region you are targeting (compared to UTC in minutes) for blink blanking (not displaying any blinks during a user specified interval) to work correctly for your users.
    Your demand shaping strategy dictates how and when to blink on which device. The example code implements a simple energy price based blink algoritm that is the same for all users. Your algorithm, combined with your household address database and energy data sources (e.g. data on market conditions, grid congestion, renewables output), could target specific regions with their own blink patterns to target local congestion with locally shaped energy demand, or act as a Virtual Power Plant when connected to an energy market.

    Example:
    JavaScript
  • Expected output: return the Aya Redirector HTTP(S) POST request with a JSON object (or, for an Exera hosted Aya Energy Alert (blink data update) script, populate the json_data object) containing the following fields:
    JSON
    blink_datapoints is a chronologically ordered array of blink data points. Every blink data point is a JSON object conforming to this format:
    JSON


3.6 Testing Aya system scripts
Before deploying your Aya system scripts to a live environment with real users, it is crucial to thoroughly test their functionality and performance. Rigorous testing ensures that your scripts behave as expected, handle various scenarios gracefully and integrate seamlessly with the Aya infrastructure. This section outlines recommended testing procedures and tools.

Exera provides a testing environment within the Aya Deployment Manager for scripts hosted on the Exera infrastructure. This environment allows you to simulate interactions with a simulated Aya in-home devices for a key code you provide (this does not go through the Aya Redirector service) and gives you debugging information. When self-hosting, you are responsible for setting up a testing environment that mirrors your production setup.

A multi-stage testing approach is recommended, covering different aspects of your script's functionality:
  1. Unit testing: verify the behavior of individual functions or modules within your scripts.
    Methodology: write unit tests that exercise each function with a variety of inputs, including valid and invalid data, edge cases, and boundary conditions. Assert that the function's output matches the expected results for each input.
    Tools:
    • Exera hosted: you can use standard JavaScript testing frameworks. Since the Exera hosting environment is based on the V8 engine, any framework compatible with ES2020 should work.
    • Self-hosted: use a testing framework compatible with your chosen server-side language and environment.
  2. Integration testing: test the interaction between your scripts and external dependencies, such as your customer database or third-party APIs.
    Methodology: simulate requests from the Aya Redirector to your scripts, including valid and invalid aya_keycode values, authentication credentials, and other relevant parameters. Verify that your scripts correctly interact with external services, handle errors gracefully, and produce the expected output.
    Tools:
    • Exera hosted: the Aya Deployment Manager provides a "Test script" feature. This feature allows you to simulate requests with customizable JSON payloads, mimicking the data sent by the Aya Redirector. You can inspect the output of your script and additional debug information.
    • Self-hosted: use tools like curl or Postman to send HTTP requests to your script's endpoint, simulating requests from the Aya Redirector.
  3. End-to-end testing: validate the entire flow, from an Aya in-home device initiating a request to receiving and processing the response from your script.
    Methodology: use a set of test Aya in-home devices to simulate real-world scenarios. This involves following the devices key codes and observing their behavior when your scripts are executed. Verify that devices successfully complete the setup process, receive the correct blink patterns and data, and react appropriately to changes in your script's logic.
    Tools: physical Aya in-home devices selected for testing.


Still questions left? Contact an Exera representative at aya@exera.org and get a prompt response back.