Skip to main content

API Wrapper for ScrathonPayments

Project description

Scrathon

Scrathon is a Python package designed to interact with the Scrathon platform to allow for purchases in your projects.

Installation

You can install Scrathon via pip: pip install scrathon-payments

Usage with Scratchattach

To use Scrathon, you need to instantiate the Scrathon class with a valid username and scratchattach cloud requests client. These will be used to authenticate and perform transactions on the Scrathon platform.

from os import system
system("pip install scratchattach --upgrade")
system("pip install scrathon-payments --upgrade")
import scratchattach as scratch3
from ScrathonPayments import Scrathon

session = scratch3.login("username of any account (can be an alt with new scratcher)", "password of the account")

conn = session.connect_cloud("YOUR PROJECT ID")

client = scratch3.CloudRequests(conn)

ScrathonPayments = Scrathon("username of account to receive coins", client)

client.run()

#Guess what? That's it!

Check out the example project here: https://scratch.mit.edu/projects/996449477/

Methods

Scrathon() Initiates a project connection to Scrathon services.

Parameter Type Description
User str Required. User to receive funds from purchases
Client scratchattach.CloudRequests Required. Scratchattach Client

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

scrathon_payments-0.2.8.tar.gz (3.3 kB view hashes)

Uploaded Source

Built Distribution

scrathon_payments-0.2.8-py3-none-any.whl (3.6 kB view hashes)

Uploaded Python 3

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