as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support

Step 8: Register your Task with the System

Tell the system to execute your task's entry points. Create or update a task.js file in the package.json path location with the following content.

Copied to clipboard.

import { HeadlessEntryPointRegistry } from "@amazon-devices/headless-task-manager";

import { default as doOnInstallOrUpdateTask } from "./src/OnInstallOrUpdateTask"
import { default as doEpgSyncTask } from "./src/EpgSyncTask"

// Register your EPG Sync function by setting the value of 'doTask'
HeadlessEntryPointRegistry.registerHeadlessEntryPoint("<packageId>.epgSyncTask::doTask",
    () => doEpgSyncTask);

// If you created a new task in Step 6, register it here as well
HeadlessEntryPointRegistry.registerHeadlessEntryPoint("<packageId>.onInstallOrUpdateTask::doTask",
    () => doOnInstallOrUpdateTask);

Copied to clipboard.

HeadlessEntryPointRegistry.registerHeadlessEntryPoint("<packageId>.epgSyncTask::doTask",
    () => doEpgSyncTask);

Last updated: Jan 20, 2026