Skip to content

xXxCLOTIxXx/amino.py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub release licence pypi docs

Sponsor project contacts
Installation

Git

pip install git+https://github.com/xXxCLOTIxXx/amino.py.git

pypi

pip install amino.api.py

Library for working with aminoapps servers, below you will see code examples

Login example

import amino

client = amino.Client()
client.login(email='email', password='password')

Ping pong bot

import amino

client = amino.Client()
client.login(email='email', password='password')
print(f"LOGIN: OK.")


@client.event(amino.arguments.wsEvent.on_text_message)
def text_msg(data: amino.objects.Event):
    if data.comId is None or data.message.author.uid == client.userId: return
    print(f"New message: {data.message.content}")
    try:
        com_client = amino.CommunityClient(client.profile, data.comId)
        if data.message.content.lower().split(" ")[0] == "ping":
            com_client.send_message(data.message.threadId, "Pong!", replyTo=data.message.messageId)
        elif data.message.content.lower().split(" ")[0] == "pong":
            com_client.send_message(data.message.threadId, "Ping!", replyTo=data.message.messageId)
    except Exception as e:
        print(e)

=Read the documentation