Simple API wrapper for paste.myst.rs written in Python
Project description
PasteMyst.py
paste.myst.rs API wrapper written in Python.
Install
Install using pip:
pip install pastemyst
Or if using Linux:
pip3 install pastemyst
Requirements
Here's the libraries used to create the wrapper:
- json
- requests
- urllib
- datetime
Functions
create_paste_myst(code: str, expires_in: str = 'never', language: str = None)
Alias:
CreatePasteMyst(..)
This function creates a new PasteMyst and returns a PasteMystInfo object
get_paste_myst(id: str)
Alias:
GetPasteMyst(..)
This function gets an exisiting PasteMyst by an id. It returns the Responding PasteMystInfo object
Objects
PasteMystInfo
Here's a table of the classes contents
| Variable | Type | Alias | Description |
|---|---|---|---|
| id | str | ID | This is the PasteMyst's ID. Use this to access the PasteMyst again |
| created_at | datetime | CreatedAt | This holds the exact date and time the PasteMyst was created at |
| code | str | Code | This is the code, the PasteMyst contains |
| expires_in | str | ExpiresIn | This is when the PasteMyst will expire and be deleted |
| language | str | Language | The target programming language of the PasteMyst |
| url | str | URL | The exact URL to get to the PasteMyst |
Contribution
Feel free to make a pull request! All help is appreciated!
License
This repo is licensed under the MIT license
Maintainers
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pastemyst-1.6.tar.gz.
File metadata
- Download URL: pastemyst-1.6.tar.gz
- Upload date:
- Size: 2.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7592331ac07d6d0e7335d0a60cd08bf3ac445cd588e53a6d10d0e0a72d670b90
|
|
| MD5 |
f59444bf64a94a1a149b7200437ae315
|
|
| BLAKE2b-256 |
330d657fd9779e0b6eea8b14e870adb8e0e1c2afe2940b5d5f3ea58f1af65632
|
File details
Details for the file pastemyst-1.6-py3-none-any.whl.
File metadata
- Download URL: pastemyst-1.6-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7bdac5bc0255e2a19eff0a49b55e4c840db2940516fc5fc7530aba9d1cd68ce6
|
|
| MD5 |
d821d8577f9e866c07ccea6831060329
|
|
| BLAKE2b-256 |
7c1b97dfabd123b57d71e221615dadf1e6034fd3e432cbbc562c6c271b7a638d
|