+ * Message object that is passed between main worker and worker.
+ *
+ * @typeParam Data - Type of data sent to the worker. This can only be serializable data.
+ * @typeParam MainWorker - Type of main worker.
+ * @internal
+ */
+export interface MessageValue<
+ Data = unknown,
+ MainWorker extends ClusterWorker | MessagePort = ClusterWorker | MessagePort
+> extends Task<Data> {
+ /**
+ * Kill code.
+ */
+ readonly kill?: KillBehavior | 1
+ /**
+ * Error.
+ */
+ readonly error?: string
+ /**
+ * Runtime.
+ */
+ readonly runTime?: number
+ /**
+ * Reference to main worker.
+ */
+ readonly parent?: MainWorker
+}
+
+/**
+ * Worker synchronous function that can be executed.
+ *
+ * @typeParam Data - Type of data sent to the worker. This can only be serializable data.
+ * @typeParam Response - Type of execution response. This can only be serializable data.