Skip to main content

Simple wrapper over https://inboxes.com API, for generating and work with temporary emails

Project description

INBOXES_API Simple wrapper over https://inboxes.com API, for generating and work with temporary emails

Example

import asyncio
import os

from inboxes_api import InboxesClient


async def main():
    
    example_email = "example@example.com"
    
    client = InboxesClient(access_token=os.environ["INBOXES_ACCESS_TOKEN"])
    
    await client.create_inbox(email=example_email)
    
    email_messages_previews = await client.get_messages(email=example_email)
    
    for message_preview in email_messages_previews:
        message = await client.get_message(message_id=message_preview.id)
        
        sender = message.sender
        reciever = message.reciever
        subject = message.subject
        created_at = message.created_at
        text = message.text
    
    await client.delete_inbox(email=example_email)


if __name__ == "__main__":
    asyncio.run(main())

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

inboxes_api-0.1.0.tar.gz (14.0 kB view details)

Uploaded Source

Built Distribution

inboxes_api-0.1.0-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

Details for the file inboxes_api-0.1.0.tar.gz.

File metadata

  • Download URL: inboxes_api-0.1.0.tar.gz
  • Upload date:
  • Size: 14.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.6 Windows/10

File hashes

Hashes for inboxes_api-0.1.0.tar.gz
Algorithm Hash digest
SHA256 1812f19a2ba5f273061b24d1b1266c8a3014ed0c3486e28d6dbe4f5065d5af51
MD5 457de967c2a67b5fec4aaa5f5f267b1a
BLAKE2b-256 55337c0893995cad5456688e34a8462f5e4f53f12f80c4ae5bdf9d29383b8fc2

See more details on using hashes here.

File details

Details for the file inboxes_api-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: inboxes_api-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.6 Windows/10

File hashes

Hashes for inboxes_api-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 814bed539147d49ac6fbfb49b3f1ce1e464dd083da287577476fd9517180fb38
MD5 315fe7d8c87a9120e1aa6bed6ebdcce5
BLAKE2b-256 2dbb3efc8c209c074b5ce9b425a7cf03b526e96553bd81b37f80d9b446ba68aa

See more details on using hashes here.

Supported by

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