For AI agents: the complete documentation index is available at /next/llms.txt, the full documentation bundle is available at /next/llms-full.txt, and this page is available as Markdown at /next/api/cdp/api-ref/lynx-native-module.md.
Lynx
  • English
  • LynxNativeModule

    This page documents the LynxNativeModule CDP domain supported by Lynx DevTool.

    Experimental reference

    This generated reference is still being completed.

    • CDP events are not included yet.
    • Some Lynx extensions are listed but do not yet have detailed documentation.
    • Method descriptions are not automatically verified against the implementation and may be incomplete or inaccurate.

    Verify behavior against the implementation and the linked upstream CDP reference before relying on it.

    Overview

    • Scope: instance
    • CDP domain: Lynx-specific

    Lynx Extensions

    LynxNativeModule.disable

    Disables live NativeModule record events for the current Lynx target.

    • Origin: lynx-extension
    • Source: devtool/lynx_devtool/agent/domain_agent/inspector_lynx_native_module_agent.cc
    Parameters

    No parameters.

    Returns

    No return fields.

    Notes
    • Recording continues in bounded history while live events are disabled.
    • The operation is idempotent and returns an empty result object.
    Examples

    Disable live NativeModule records

    Request:

    {
      "id": 1,
      "method": "LynxNativeModule.disable"
    }

    Response:

    {
      "id": 1,
      "result": {}
    }

    LynxNativeModule.enable

    Enables live NativeModule record events for the current Lynx target.

    • Origin: lynx-extension
    • Source: devtool/lynx_devtool/agent/domain_agent/inspector_lynx_native_module_agent.cc
    Parameters

    No parameters.

    Returns

    No return fields.

    Events
    • LynxNativeModule.recordAdded: Emitted when a NativeModule invocation, callback, or global event record is captured.
    Notes
    • Existing records remain available through LynxNativeModule.getRecords.
    • The operation is idempotent and returns an empty result object.
    Examples

    Enable live NativeModule records

    Request:

    {
      "id": 1,
      "method": "LynxNativeModule.enable"
    }

    Response:

    {
      "id": 1,
      "result": {}
    }

    LynxNativeModule.getRecords

    Returns the bounded NativeModule record history for the current Lynx target.

    • Origin: lynx-extension
    • Source: devtool/lynx_devtool/agent/domain_agent/inspector_lynx_native_module_agent.cc
    Parameters

    No parameters.

    Returns
    NameTypeDescription
    recordsarrayCaptured records in sequence order, including invocation, callback, and global event records.
    latestSequencenumberSequence number assigned to the most recently captured record, or zero when history is empty.
    Notes
    • History retains at most 200 records and 4 MiB of serialized record data.
    • Fetching records does not change whether live reporting is enabled.
    Examples

    Read NativeModule history

    Request:

    {
      "id": 1,
      "method": "LynxNativeModule.getRecords"
    }

    Response:

    {
      "id": 1,
      "result": {
        "records": [],
        "latestSequence": 0
      }
    }
    Except as otherwise noted, this work is licensed under a Creative Commons Attribution 4.0 International License, and code samples are licensed under the Apache License 2.0.