{
  "id": "vshymanskyy/aiodns",
  "name": "aiodns",
  "prettyName": "aiodns",
  "description": "A small async DNS client for MicroPython",
  "version": "",
  "author": "vshymanskyy",
  "license": "MIT",
  "tags": [
    "asyncio",
    "cellular",
    "dns",
    "esp32",
    "esp8266",
    "ethernet",
    "lte",
    "mdns",
    "micropython",
    "rpi-pico-w",
    "wifi"
  ],
  "status": "VALID",
  "official": false,
  "source": "https://github.com/vshymanskyy/aiodns",
  "updatedAt": "2025-06-28T07:01:33.165Z",
  "page": "https://checkmim.com/packages/vshymanskyy+aiodns",
  "createdAt": "2025-05-27T04:28:06.871Z",
  "submittedBy": "oliverr",
  "install": {
    "mpremote": "mpremote mip install github:vshymanskyy/aiodns",
    "mip": "import mip; mip.install(\"github:vshymanskyy/aiodns\")"
  },
  "readme": "# aiodns\n\n[![StandWithUkraine](https://raw.githubusercontent.com/vshymanskyy/StandWithUkraine/main/badges/StandWithUkraine.svg)](https://github.com/vshymanskyy/StandWithUkraine/blob/main/docs/README.md) \n[![GitHub issues](https://img.shields.io/github/issues-raw/vshymanskyy/aiodns?style=flat-square&label=issues&color=green)](https://github.com/vshymanskyy/aiodns/issues) \n[![GitHub license](https://img.shields.io/badge/license-MIT-blue?style=flat-square)](https://github.com/vshymanskyy/aiodns) \n[![Support vshymanskyy](https://img.shields.io/static/v1?style=flat-square&label=support&message=%E2%9D%A4&color=%23fe8e86)](https://gist.github.com/vshymanskyy/840e6fa41ea6b028b91b333b6e4542ed) \n[![Build status](https://img.shields.io/github/actions/workflow/status/vshymanskyy/aiodns/build.yml?branch=main&style=flat-square&logo=github&label=build)](https://github.com/vshymanskyy/aiodns/actions)\n\n<!--[![GitHub Repo stars](https://img.shields.io/github/stars/vshymanskyy/aiodns?style=flat-square&color=green)](https://github.com/vshymanskyy/aiodns/stargazers) -->\n\nA small async DNS client for MicroPython\n\n- Works on `ESP32`, `ESP8266`, `Raspberry Pi Pico W`, `WM W600` and other boards\n- Versatile, runs multiple queries at a time using multiple DNS servers\n- Supports IPv4 and IPv6\n- Supports `mDNS` (Multicast DNS) name resolution\n- Works with WiFi, Ethernet, Cellular, and in multi-network scenarios\n- Caches up to 32 hostnames (configurable)\n- API-compatible with `getaddrinfo`\n\n## Install\n\n[<img src=\"https://raw.githubusercontent.com/vshymanskyy/ViperIDE/refs/heads/main/assets/btn_install.png\" alt=\"Install using ViperIDE\" height=\"42\"/>](https://viper-ide.org/?install=github:vshymanskyy/aiodns)\n\nUsing CLI:\n\n```sh\nmpremote mip install github:vshymanskyy/aiodns\n```\n\nUsing REPL (your board must be connected to the internet):\n\n```py\nimport mip\nmip.install(\"github:vshymanskyy/aiodns\")\n```\n\n## Example\n\nSee [usage examples](./examples)\n\n## API\n\n```py\naiodns.servers = set([\"8.8.8.8\", \"1.1.1.1\"])\naiodns.servers.add(\"9.9.9.9\")\naiodns.timeout_ms = 5000\naiodns.cache.clear()\naiodns.cache_size = 32\nawait aiodns.getaddrinfo(hostname, port, family=AF_INET, type=0, proto=0, flags=0)\n```\n\n## Build\n\n```sh\npip3 install -U python-minifier mpy-cross\npython3 ./extra/build.py\n```\n\nOutput:\n\n```log\nMinified: 2796 bytes\nCompiled: 2202 bytes\n```\n\n## Run using MicroPython Unix port:\n\n```sh\nexport MICROPYPATH=\".frozen:./lib:.\"\nmkdir -p lib\nmicropython -m mip install logging\nmicropython examples/simple/main.py\n```\n\n## Run using Python 3:\n\n```sh\npip3 install -U microemu\nmicroemu examples/simple/main.py\n```\n"
}