Catalog PyPI
PACKAGE EXPLORERView in registry

aa-agent-tools

PyPI

aa_agent_tools - a friendly, Pyodide-ready toolbox of cool functions for kid-built agents (web search, fetch pages, email, AI, weather, and tons of fun stuff).

Versions collected1
Direct dependencies1From release 0.1.34
Last observed20 Oct, 16:47 UTC

README

Version 0.1.34 documentation

🛠️ aa_agent_tools

A friendly toolbox of cool functions for kid-built agents.

aa_agent_tools gives your Python agents super-powers: search the web, read pages, send emails, check the weather, grab space pictures from NASA, roll dice, fetch cat facts, and a whole lot more — 38 functions, all listed below with copy-paste examples.

🔑 You bring the API keys. We never store them. Just pass them as arguments when you call a function. Look for the 🔑 badge below (those need a key) and the 🆓 badge (those are totally free, no key at all!).


🎉 Quick start

import aa_agent_tools as aa

# No key needed — just fun!
print(aa.get_joke())
print(aa.get_cat_fact())
print(aa.get_pokemon("pikachu")["types"])
print(aa.flip_coin())
print(aa.number_fact(7))

# With a key you supply
results = aa.search_web("cute penguins", api_key="YOUR_BRAVE_KEY")
print(results)

Want the pretty, searchable version? Open the 📖 HTML Reference Page in your browser.


📖 The full function reference

Every function is listed below, grouped by what it does. Each one shows a short, friendly description and a copy-paste example you can try right away.

  • 🔑 = needs an API key (you pass it as an argument)
  • 🆓 = totally free, no key needed

search_web(query, api_key) 🔑

Search the internet with Brave and get back a tidy list of results (title, link, snippet).

results = aa.search_web("best robots for kids", api_key="YOUR_BRAVE_KEY")
print(results)

search_images(query, api_key, count=5) 🔑

Search for pictures on the web using Brave Search.

pics = aa.search_images("puppies", api_key="YOUR_BRAVE_KEY")
print(pics[0]["url"])

fetch_page(url) 🆓

Download any web page and turn it into clean text (Markdown). Great for reading articles.

text = aa.fetch_page("https://en.wikipedia.org/wiki/Penguin")
print(text[:300])

✉️ Email

send_email(to, subject, body, *, smtp_host, username, password) 🔑

Send a plain-text email through almost any email provider's SMTP server.

aa.send_email(
    to="friend@example.com",
    subject="Hello from my agent!",
    body="My robot wrote this.",
    smtp_host="smtp.gmail.com",
    username="you@gmail.com",
    password="app-password",
)

send_email_gmail(to, subject, body, *, gmail, app_password) 🔑

Send an email using a Gmail account (use a 16-character app password).

aa.send_email_gmail(
    to="friend@example.com",
    subject="hi!",
    body="sent from aa_agent_tools",
    gmail="you@gmail.com",
    app_password="abcd efgh ijkl mnop",
)

🤖 Any API

call_api(url, api_key=None, *, method="GET", ...) 🆓

Call almost any REST API in one line. You give it a URL and (if the API needs one) a key. No key needed for public APIs.

city = input("Enter your city: ")
data = aa.call_api(
	"https://api.weatherapi.com/v1/current.json?key=key&q={city}&aqi=no"	
)

current = data["current"]
	
print(current["temp_c"])

🌤️ Weather

get_weather(city, api_key) 🔑

Get the current weather for any city in the world (OpenWeatherMap).

w = aa.get_weather("London", api_key="YOUR_OWM_KEY")
print(f"{w['temp']}°C and {w['description']}")

get_forecast(city, api_key, days=3) 🔑

Get a short multi-day forecast for a city (OpenWeatherMap).

fc = aa.get_forecast("Tokyo", api_key="YOUR_OWM_KEY", days=3)
print(fc)

🚀 Space

space_image(date=None, api_key="DEMO_KEY") 🆓

Get NASA's Astronomy Picture of the Day ("DEMO_KEY" works for light use).

pic = aa.space_image()
print(pic["title"], pic["url"])

near_earth_objects(api_key="DEMO_KEY", *, start_date=None) 🆓

List asteroids flying near Earth in a date range (NASA NeoWs).

aa.near_earth_objects(api_key="DEMO_KEY", start_date="2024-01-01")

mars_photo(*, sol=1000, api_key="DEMO_KEY") 🆓

Fetch a real photo taken by a rover on Mars (NASA).

print(aa.mars_photo(sol=1000, api_key="DEMO_KEY"))

🎉 Fun & Games

get_joke() 🆓

Get a random, clean joke with a setup and punchline.

j = aa.get_joke()
print(j["setup"]); print(j["punchline"])

get_advice() 🆓

Get a random piece of (silly but wise) advice.

print(aa.get_advice())

get_cat_fact() 🆓

Get a random fact about cats.

print(aa.get_cat_fact())

get_cat_image() 🆓

Get a link to a random photo of a cat.

print(aa.get_cat_image())

get_dog_image() 🆓

Get a random photo of a good dog.

print(aa.get_dog_image())

get_quote() 🆓

Get an inspirational quote and who said it.

q = aa.get_quote()
print(f'"{q["text"]}" - {q["author"]}')

roll_dice(sides=6) 🆓

Roll a die with any number of sides (default 6).

print(aa.roll_dice(20))

flip_coin() 🆓

Flip a coin: returns "heads" or "tails".

print(aa.flip_coin())

random_number(min_value=1, max_value=100) 🆓

Pick a random whole number between two values.

print(aa.random_number(1, 100))

pick_one(*items) 🆓

Randomly pick one item from the ones you list.

print(aa.pick_one("red", "green", "blue"))

get_pokemon(name="pikachu") 🆓

Look up a Pokémon by name: its type, height, and a picture.

p = aa.get_pokemon("charizard")
print(p["name"], p["types"])

📚 Knowledge

wikipedia_summary(title) 🆓

Get a short, friendly summary of almost any Wikipedia topic.

info = aa.wikipedia_summary("Aurora")
print(info["summary"])

define_word(word) 🆓

Get the dictionary definition and an example sentence for a word.

d = aa.define_word("serendipity")
print(d["definitions"][0])

number_fact(number) 🆓

Get a fun, fact-packed description of any number (works offline!).

print(aa.number_fact(7))

country_info(name) 🆓

Get a friendly snapshot of a country using Wikipedia.

c = aa.country_info("Japan")
print(c["summary"][:80])

convert_money(amount, from_currency, to_currency) 🆓

Convert money between currencies using live rates (no key needed).

print(aa.convert_money(10, "USD", "EUR"))

shorten_url(url) 🆓

Make a long URL short using the free is.gd service.

print(aa.shorten_url("https://example.com/very/long/path"))

🖼️ Images

generate_image(prompt, api_key, *, size="1024*1024", prompt_extend=False) 🔑

Create a picture from a text description using Alibaba's Z-Image-Turbo model and return the image URL.

url = aa.generate_image("a robot painting a sunset", api_key="YOUR_DASHSCOPE_KEY")
print(url)

get_photo(query, api_key) 🔑

Search free stock photos on Pexels and get image links.

for url in aa.get_photo("mountains", api_key="YOUR_PEXELS_KEY"):
    print(url)

random_image(*, width=400, height=300, seed=None) 🆓

Get a random photo of any size (no key needed).

print(aa.random_image(width=600, height=400, seed="sunset"))

🧰 Text Tools

hash_text(text, *, algorithm="sha256") 🆓

Turn text into a fixed "fingerprint" hash (sha256 by default).

print(aa.hash_text("hello"))

base64_encode(text) 🆓

Encode text into Base64 (a common way to pack data).

print(aa.base64_encode("hi"))

base64_decode(text) 🆓

Decode Base64 text back to normal text.

print(aa.base64_decode("aGk="))

make_qr(text, *, size=200) 🆓

Make a QR code image for text or a link (returns a URL).

print(aa.make_qr("https://example.com"))

convert_units(value, from_unit, to_unit) 🆓

Convert between length or weight units.

print(aa.convert_units(1, "mi", "km"))  # ~1.609
print(aa.convert_units(1, "kg", "lb"))  # ~2.205

count_words(text) 🆓

Count how many words are in some text.

print(aa.count_words("one two three"))

reverse_text(text) 🆓

Reverse a string backwards.

print(aa.reverse_text("abc"))  # cba

is_palindrome(text) 🆓

Is the text the same forwards and backwards?

print(aa.is_palindrome("Racecar"))  # True

🔑 Where to get API keys

Most "cool" functions need a free key from the service. You only need the ones you want to use:

Functions that need no key at all: get_joke, get_advice, get_cat_fact, get_cat_image, get_dog_image, get_quote, roll_dice, flip_coin, random_number, pick_one, get_pokemon, wikipedia_summary, define_word, number_fact, country_info, convert_money, shorten_url, random_image, fetch_page, call_api (key optional), and all the Text Tools.


🛠️ Development

uv build                 # build wheel + sdist
PYTHONPATH=src python make_reference.py   # regenerate docs/reference.html

The build produces a pure-Python wheel tagged py3-none-any, which is exactly what micropip needs inside Pyodide.


Made with 💛 for young coders and the agents they build.

Downloads & popularity

6downloads
1-day window · source-reported counts19 Oct 2026
11959.50
2026-07-22: 23 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-22–2026-07-222026-07-23: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-23–2026-07-232026-07-24: 22 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-24–2026-07-242026-07-27: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-27–2026-07-272026-07-28: 21 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-28–2026-07-282026-07-29: 119 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-29–2026-07-292026-07-30: 17 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-30–2026-07-302026-07-31: 7 · observed 2026-10-20T17:49:06.3843204Z · period 2026-07-31–2026-07-312026-08-01: 5 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-01–2026-08-012026-08-02: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-02–2026-08-022026-08-03: 24 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-03–2026-08-032026-08-04: 12 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-04–2026-08-042026-08-05: 8 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-05–2026-08-052026-08-06: 25 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-06–2026-08-062026-08-09: 9 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-09–2026-08-092026-08-11: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-11–2026-08-112026-08-13: 9 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-13–2026-08-132026-08-14: 9 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-14–2026-08-142026-08-15: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-15–2026-08-152026-08-17: 8 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-17–2026-08-172026-08-18: 54 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-18–2026-08-182026-08-20: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-20–2026-08-202026-08-23: 4 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-23–2026-08-232026-08-24: 42 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-24–2026-08-242026-08-25: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-25–2026-08-252026-08-28: 17 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-28–2026-08-282026-08-29: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-29–2026-08-292026-08-30: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-30–2026-08-302026-08-31: 5 · observed 2026-10-20T17:49:06.3843204Z · period 2026-08-31–2026-08-312026-09-01: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-01–2026-09-012026-09-02: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-02–2026-09-022026-09-03: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-03–2026-09-032026-09-05: 6 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-05–2026-09-052026-09-06: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-06–2026-09-062026-09-07: 4 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-07–2026-09-072026-09-08: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-08–2026-09-082026-09-09: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-09–2026-09-092026-09-10: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-10–2026-09-102026-09-11: 4 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-11–2026-09-112026-09-12: 19 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-12–2026-09-122026-09-13: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-13–2026-09-132026-09-14: 8 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-14–2026-09-142026-09-15: 7 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-15–2026-09-152026-09-16: 18 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-16–2026-09-162026-09-17: 4 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-17–2026-09-172026-09-18: 17 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-18–2026-09-182026-09-19: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-19–2026-09-192026-09-22: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-22–2026-09-222026-09-23: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-23–2026-09-232026-09-24: 8 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-24–2026-09-242026-09-25: 5 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-25–2026-09-252026-09-26: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-26–2026-09-262026-09-27: 10 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-27–2026-09-272026-09-28: 11 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-28–2026-09-282026-09-29: 6 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-29–2026-09-292026-09-30: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-09-30–2026-09-302026-10-01: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-01–2026-10-012026-10-03: 7 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-03–2026-10-032026-10-04: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-04–2026-10-042026-10-06: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-06–2026-10-062026-10-07: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-07–2026-10-072026-10-08: 2 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-08–2026-10-082026-10-09: 6 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-09–2026-10-092026-10-10: 15 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-10–2026-10-102026-10-11: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-11–2026-10-112026-10-12: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-12–2026-10-122026-10-13: 3 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-13–2026-10-132026-10-14: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-14–2026-10-142026-10-15: 6 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-15–2026-10-152026-10-16: 1 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-16–2026-10-162026-10-17: 13 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-17–2026-10-172026-10-18: 5 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-18–2026-10-182026-10-19: 6 · observed 2026-10-20T17:49:06.3843204Z · period 2026-10-19–2026-10-19
22 Jul19 Oct

pypistats · 73 observations shown. Missing days are unknown. Source category: overall: without mirrors.

View observed values
Date / source periodValueObserved at
2026-10-19 – 2026-10-1962026-10-20T17:49:06.3843204Z
2026-10-18 – 2026-10-1852026-10-20T17:49:06.3843204Z
2026-10-17 – 2026-10-17132026-10-20T17:49:06.3843204Z
2026-10-16 – 2026-10-1612026-10-20T17:49:06.3843204Z
2026-10-15 – 2026-10-1562026-10-20T17:49:06.3843204Z
2026-10-14 – 2026-10-1412026-10-20T17:49:06.3843204Z
2026-10-13 – 2026-10-1332026-10-20T17:49:06.3843204Z
2026-10-12 – 2026-10-1232026-10-20T17:49:06.3843204Z
2026-10-11 – 2026-10-1132026-10-20T17:49:06.3843204Z
2026-10-10 – 2026-10-10152026-10-20T17:49:06.3843204Z
2026-10-09 – 2026-10-0962026-10-20T17:49:06.3843204Z
2026-10-08 – 2026-10-0822026-10-20T17:49:06.3843204Z
2026-10-07 – 2026-10-0712026-10-20T17:49:06.3843204Z
2026-10-06 – 2026-10-0612026-10-20T17:49:06.3843204Z
2026-10-04 – 2026-10-0412026-10-20T17:49:06.3843204Z
2026-10-03 – 2026-10-0372026-10-20T17:49:06.3843204Z
2026-10-01 – 2026-10-0112026-10-20T17:49:06.3843204Z
2026-09-30 – 2026-09-3032026-10-20T17:49:06.3843204Z
2026-09-29 – 2026-09-2962026-10-20T17:49:06.3843204Z
2026-09-28 – 2026-09-28112026-10-20T17:49:06.3843204Z
2026-09-27 – 2026-09-27102026-10-20T17:49:06.3843204Z
2026-09-26 – 2026-09-2622026-10-20T17:49:06.3843204Z
2026-09-25 – 2026-09-2552026-10-20T17:49:06.3843204Z
2026-09-24 – 2026-09-2482026-10-20T17:49:06.3843204Z
2026-09-23 – 2026-09-2322026-10-20T17:49:06.3843204Z
2026-09-22 – 2026-09-2222026-10-20T17:49:06.3843204Z
2026-09-19 – 2026-09-1922026-10-20T17:49:06.3843204Z
2026-09-18 – 2026-09-18172026-10-20T17:49:06.3843204Z
2026-09-17 – 2026-09-1742026-10-20T17:49:06.3843204Z
2026-09-16 – 2026-09-16182026-10-20T17:49:06.3843204Z
2026-09-15 – 2026-09-1572026-10-20T17:49:06.3843204Z
2026-09-14 – 2026-09-1482026-10-20T17:49:06.3843204Z
2026-09-13 – 2026-09-1312026-10-20T17:49:06.3843204Z
2026-09-12 – 2026-09-12192026-10-20T17:49:06.3843204Z
2026-09-11 – 2026-09-1142026-10-20T17:49:06.3843204Z
2026-09-10 – 2026-09-1012026-10-20T17:49:06.3843204Z
2026-09-09 – 2026-09-0922026-10-20T17:49:06.3843204Z
2026-09-08 – 2026-09-0812026-10-20T17:49:06.3843204Z
2026-09-07 – 2026-09-0742026-10-20T17:49:06.3843204Z
2026-09-06 – 2026-09-0622026-10-20T17:49:06.3843204Z
2026-09-05 – 2026-09-0562026-10-20T17:49:06.3843204Z
2026-09-03 – 2026-09-0332026-10-20T17:49:06.3843204Z
2026-09-02 – 2026-09-0212026-10-20T17:49:06.3843204Z
2026-09-01 – 2026-09-0112026-10-20T17:49:06.3843204Z
2026-08-31 – 2026-08-3152026-10-20T17:49:06.3843204Z
2026-08-30 – 2026-08-3012026-10-20T17:49:06.3843204Z
2026-08-29 – 2026-08-2912026-10-20T17:49:06.3843204Z
2026-08-28 – 2026-08-28172026-10-20T17:49:06.3843204Z
2026-08-25 – 2026-08-2512026-10-20T17:49:06.3843204Z
2026-08-24 – 2026-08-24422026-10-20T17:49:06.3843204Z
2026-08-23 – 2026-08-2342026-10-20T17:49:06.3843204Z
2026-08-20 – 2026-08-2022026-10-20T17:49:06.3843204Z
2026-08-18 – 2026-08-18542026-10-20T17:49:06.3843204Z
2026-08-17 – 2026-08-1782026-10-20T17:49:06.3843204Z
2026-08-15 – 2026-08-1522026-10-20T17:49:06.3843204Z
2026-08-14 – 2026-08-1492026-10-20T17:49:06.3843204Z
2026-08-13 – 2026-08-1392026-10-20T17:49:06.3843204Z
2026-08-11 – 2026-08-1132026-10-20T17:49:06.3843204Z
2026-08-09 – 2026-08-0992026-10-20T17:49:06.3843204Z
2026-08-06 – 2026-08-06252026-10-20T17:49:06.3843204Z
2026-08-05 – 2026-08-0582026-10-20T17:49:06.3843204Z
2026-08-04 – 2026-08-04122026-10-20T17:49:06.3843204Z
2026-08-03 – 2026-08-03242026-10-20T17:49:06.3843204Z
2026-08-02 – 2026-08-0232026-10-20T17:49:06.3843204Z
2026-08-01 – 2026-08-0152026-10-20T17:49:06.3843204Z
2026-07-31 – 2026-07-3172026-10-20T17:49:06.3843204Z
2026-07-30 – 2026-07-30172026-10-20T17:49:06.3843204Z
2026-07-29 – 2026-07-291192026-10-20T17:49:06.3843204Z
2026-07-28 – 2026-07-28212026-10-20T17:49:06.3843204Z
2026-07-27 – 2026-07-2732026-10-20T17:49:06.3843204Z
2026-07-24 – 2026-07-24222026-10-20T17:49:06.3843204Z
2026-07-23 – 2026-07-2322026-10-20T17:49:06.3843204Z
2026-07-22 – 2026-07-22232026-10-20T17:49:06.3843204Z

Versions 1

Collected releases
VersionPublishedDirect dependenciesOpen version
0.1.3429 Jul 20261

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
obaodelana/aa_agent_tools

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 16:47 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:1cc8e3aef3473ba9da51d0e709d2e69c2520007da202b9bbb0f5fe5c68ed48df