Skip to main content

A Python Client for Anytype.

Project description

Anytype Python Client

Python Version License

A Python client for interacting with Anytype. Automate workflows and integrate with your apps! ✨


🚀 Features

  • Seamless Integration: Connect Python scripts directly to your Anytype workspace.
  • Object Management: Create, modify, and organize pages, notes, and custom objects.
  • Space Operations: Manage spaces, types, and relations programmatically.
  • Batch Operations: Export data, automate repetitive tasks, and more.
  • PDF Import Example: Bulk import annotated PDFs as structured notes (see examples).

📦 Installation

pip install anytype-client

Prerequisites:

  • Python 3.10+
  • Anytype desktop app (v0.44.13-beta or higher) running during authentication

⚡ Quick Start

  1. Authentication
from anytype import Anytype

# Initialize client (first run triggers authentication)
any = Anytype()
any.auth()  # 🔑 Enter 4-digit code from Anytype app when prompted
  1. Create Your First Object
from anytype import Object

# Get your workspace
spaces = any.get_spaces()
my_space = spaces[0]  # Use your preferred space

# Create a new page
note_type = my_space.get_type("Page")
new_note = Object()
new_note.name = "My Python-Powered Note 📝"
new_note.icon = "🔥"
new_note.description = "Automatically generated via Python API"

# Add rich content
new_note.add_title1("Welcome to Automated Knowledge Management!")
new_note.add_text("This section was created programmatically using Python")

# Commit to workspace
created_object = my_space.create_object(new_note, note_type)
print(f"Created object: {created_object.name}")

🌟 Examples

Example Description Results
📄 Hello World Create a basic note with formatted text Check Result
📚 PDF Notes Importer Batch import annotated PDFs Check Result
More examples coming as Anytype API evolves Request a feature ⚔️

📄 Documentation

Check the documentation here!

🤝 Contributing

Contributions are welcomed! Here's how to help:

  1. Report bugs or request features via Issues
  2. Submit pull requests for improvements
  3. Share your use cases in Discussions

📄 License

GPL-3.0 License - see LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

anytype_client-0.4.0.tar.gz (34.2 kB view details)

Uploaded Source

File details

Details for the file anytype_client-0.4.0.tar.gz.

File metadata

  • Download URL: anytype_client-0.4.0.tar.gz
  • Upload date:
  • Size: 34.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for anytype_client-0.4.0.tar.gz
Algorithm Hash digest
SHA256 55032651d72408f833f35d9cc674d8d9f7811754da85dbd6129803092ef1df08
MD5 0cbc01fc976dd0c9748faba41f6c753e
BLAKE2b-256 b8eaf8ed66de96b8f22972fea0d649e907ff350f3c906684f4baf7ac959ce771

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page