Skip to main content

Company Logo

Python Versions

Idun Guardian SDK

Idun Guardian SDK is a Python package for interacting with the Guardian Earbud. It enables device search, battery monitoring, impedance streaming, real-time data collection, and report generation.

📖 Read the full documentation here

🎧 Have a look at the user manual here

🔗 Learn more about us here


Main features

  • 🔍 Search for Device: Locate the Guardian Earbud.
  • 🔋 Check Battery: Monitor battery levels.
  • 📡 Stream Impedance: Analyze impedance in real-time.
  • 🎧 Connect & Record Data:
    • Real-time insights (raw & filtered EEG)
    • Real-time predictions (FFT, jaw clench, eye movements, quality score)
  • 💾 Download & Manage Data:
    • Retrieve recorded sessions
    • Delete unwanted recordings
  • 📊 Generate Reports:
    • Sleep report
    • Daytime report

Python version

3.9 - 3.13


Installation

It is advised to create a new Python Virtual Environment:

  python -m venv idun_env
  source idun_env/bin/activate

Alternatively you can use third party tools such as Conda or Pipenv:

  1. First activate the virtual environment, this command must always be run before using the python SDK:
  source idun_env/bin/activate
  1. After the environment is activated, install the Python SDK using the following command:
  pip install idun-guardian-sdk
  1. After installing the package, make sure that the dependencies are correctly installed by running the following command and inspecting the packages installed in the terminal output:
  pip list

You should see as output a package named idun-guardian-sdk


Quick Start

📖 Read the full documentation here

Authentication

To use the API, set your token:

export IDUN_API_TOKEN=my-api-token

Or initialize the client in Python:

from idun_guardian_sdk import GuardianClient
client = GuardianClient(api_token="my-api-token")

Create the API key in the Console (Account > API key). To record, the Guardian must be activated with Connect in the Console or app. See How the SDK chooses the Guardian and the changelog.

Search for Device

import asyncio
from idun_guardian_sdk import GuardianClient

client = GuardianClient()
device_address = asyncio.run(client.search_device())

Check Battery Level

battery_level = asyncio.run(client.check_battery())
print(f"Battery Level: {battery_level}%")

Stream Impedance

asyncio.run(client.stream_impedance(mains_freq_60hz=False))

Start a Recording

RECORDING_TIMER = 600  # 10 minutes
asyncio.run(client.start_recording(recording_timer=RECORDING_TIMER))

Retrieve & Download Recording

recordings = client.get_recordings(status="COMPLETED", limit=10)
recording_id = recordings[0]['id']
client.download_file(recording_id=recording_id)

Generate Reports

client.generate_and_download_sleep_report(recording_id=recording_id)

Metadata

Release files for idun-guardian-sdk 0.1.26

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for idun-guardian-sdk 0.1.26
File Size Uploaded Provenance Actions
idun_guardian_sdk-0.1.26.tar.gz 26.5 kB Without provenance Details for idun_guardian_sdk-0.1.26.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for idun-guardian-sdk 0.1.26
File Interpreter ABI Platform Actions
idun_guardian_sdk-0.1.26-py3-none-any.whl Python 3 none any Details for idun_guardian_sdk-0.1.26-py3-none-any.whl

Total release size: 57.9 kB

Release files / idun_guardian_sdk-0.1.26.tar.gz

Download URL idun_guardian_sdk-0.1.26.tar.gz
Size 26.5 kB
Tags Source
SHA-256 checksum
How to use checksums
b8ab7b0b27f4f8be99e3b7746c9be5679c0286d32f3c0608d912097e94b195a9
BLAKE2b-256 checksum
How to use checksums
a9e88954530efbe0969f2ff5d0304c1976e1a91623073f4cfb40280ee2bbfab1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.5.2 CPython/3.10.22 Linux/7.0.0-1020-azure

Release files / idun_guardian_sdk-0.1.26-py3-none-any.whl

Download URL idun_guardian_sdk-0.1.26-py3-none-any.whl
Size 31.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
19abdb5cbe4063df25fe87880c6f8b55deb97fb3cf471f56185c4ea5a3b85f09
BLAKE2b-256 checksum
How to use checksums
1c5512933ed678680a8fd711f33439678dc3c59ba5b84ccaa68f918a73a7a47d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.5.2 CPython/3.10.22 Linux/7.0.0-1020-azure

Security for idun-guardian-sdk 0.1.26

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page