A Pastebin api created in python with easy to use syntax
Project description
PasteBinPy
An easy to learn, use, and contribute to api for python.
Getting Started
To get your pastebin api key, create or login to your pastebin account here > after creating your account, head over to the api documentation and grab your api key under Your Unique Developer API Key —
Example
import pastebinpy as pbp
# All thats needed for a successfull response
pbp.paste("api_key", "title", "body")
pbp.paste("api_key", "title", "body", raw=1, expiry="10M", privacy="1", format="python")
pastebinpy.paste()
API_KEY can be retrieved by making a pastebin account and getting your api key from this link
CONTENT is the body of the paste, the inside that your user will be looking at.
TITLE is at the top of the paste, users will probably not notice this, but its a good attribute to still use.
PRIVACY has two values, 0 being public, and 1 being unlisted, meaning only people with the pastebin link can view it.
EXPIRY is defining the expiration time and/or time limit that you give your paste. Allowed variables are below.
N = Never 10M = 10 Minutes 1H = 1 Hour 1D = 1 Day 1W = 1 Week 2W = 2 Weeks 1M = 1 Month 6M = 6 Months 1Y = 1 Year
RAW is the toggle attribute for obtaining a raw pastebin link, with 1 equaling the raw pastebin link, and 0 being the default, returning the normal pastebin link.
FORMAT is the selected language attribute to format and color the content given. (e.g HTML, PHP, LUA, PYTHON, BF, CSS, CPP, CSHARP, RUBY, RAILS, etc)
Created by css / cesiyi
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
Built Distribution
File details
Details for the file pastebinpy-0.1.5.tar.gz
.
File metadata
- Download URL: pastebinpy-0.1.5.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.11 CPython/3.8.12 Linux/5.13.0-1025-gcp
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9cd5cf716faa7d5fdb05e779b6e47aa9f507a96001786ed44cc091601e0bd482 |
|
MD5 | f861e1ee41e470144fca1977cf3ed513 |
|
BLAKE2b-256 | 7b841e220e030f5252c8d40208b761e4e0fceb0c164c36750c5e252545da1e01 |
File details
Details for the file pastebinpy-0.1.5-py3-none-any.whl
.
File metadata
- Download URL: pastebinpy-0.1.5-py3-none-any.whl
- Upload date:
- Size: 3.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.11 CPython/3.8.12 Linux/5.13.0-1025-gcp
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f79f0b582f04003e394f160312c4cc773bbaaa49fd4be1f49f5845e2efd8069b |
|
MD5 | 928ad02b6045bd5aac6b73c5d03da183 |
|
BLAKE2b-256 | e02ec76014c7babf509502ef7f3c36fbaf8c2f81cff6bcb13c15ee51e88e36c8 |