All Projects → AbstractUmbra → mystbin.py

AbstractUmbra / mystbin.py

Licence: MIT license
A Mystb.in API wrapper!

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to mystbin.py

Privatebin
A minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted in the browser using 256 bits AES.
Stars: ✭ 3,622 (+21205.88%)
Mutual labels:  paste
Spacehook
minecraft premium undeteck cheat!
Stars: ✭ 80 (+370.59%)
Mutual labels:  paste
Piknik
Copy/paste anything over the network.
Stars: ✭ 2,221 (+12964.71%)
Mutual labels:  paste
Pasteme
PasteMe 是一个无需注册的文本分享平台,可以为文本设置密码和阅后即焚,支持二维码分享和各种一键复制,最大化释放你的双手,针对代码提供了额外的高亮功能。主站点已全站 CDN 以及 GZIP 传输,有着好看的前端(嘤嘤嘤)和优秀的访问速度。
Stars: ✭ 606 (+3464.71%)
Mutual labels:  paste
Nekobin
Elegant and open-source pastebin service
Stars: ✭ 61 (+258.82%)
Mutual labels:  paste
Feedback
Feedback & wiki for Snipaste https://snipaste.com
Stars: ✭ 1,863 (+10858.82%)
Mutual labels:  paste
SourceBin
💻 Sharing code made easy
Stars: ✭ 48 (+182.35%)
Mutual labels:  paste
PasteServer
PasteServer to upload text or code
Stars: ✭ 29 (+70.59%)
Mutual labels:  paste
Nopaste
📋 Client-side paste service
Stars: ✭ 79 (+364.71%)
Mutual labels:  paste
Markdown Img Paste
一个可以快速粘贴剪贴板里的照片到markdown的插件,并且可以设置使用七牛存储照片。
Stars: ✭ 176 (+935.29%)
Mutual labels:  paste
Pasteex
📋 Paste As File 把剪贴板的内容直接粘贴为文件
Stars: ✭ 634 (+3629.41%)
Mutual labels:  paste
Ayyhook Loader
A Free Open Source Cheat Loader
Stars: ✭ 52 (+205.88%)
Mutual labels:  paste
Paste.laravel.io
The Laravel.io Pastebin.
Stars: ✭ 135 (+694.12%)
Mutual labels:  paste
Scavenger
Crawler (Bot) searching for credential leaks on different paste sites.
Stars: ✭ 347 (+1941.18%)
Mutual labels:  paste
rentry
Markdown pastebin from command line
Stars: ✭ 252 (+1382.35%)
Mutual labels:  paste
pb
pb; a command line pastebin service helper (12 supported services)
Stars: ✭ 22 (+29.41%)
Mutual labels:  paste
Vim Paste Easy
Automatically set paste for you
Stars: ✭ 87 (+411.76%)
Mutual labels:  paste
gradle-cpd-plugin
Gradle plugin to find duplicate code using PMDs copy/paste detection (= CPD).
Stars: ✭ 88 (+417.65%)
Mutual labels:  paste
react-gluejar
Paste images from your clipboard, declaratively
Stars: ✭ 58 (+241.18%)
Mutual labels:  paste
Xcv
✂️ Cut, Copy and Paste files with Bash
Stars: ✭ 144 (+747.06%)
Mutual labels:  paste

Mystbin.py!

Documentation Status Linting status Build status

A small simple wrapper around the Mystb.in API. API docs can be found here.

Documentation for this wrapper can be found here. If you want the docs for the main branch, those can be found here.


Features

  • - Creating pastes.
  • - Editing pastes.
    • Pending design work.
  • - Deleting pastes.
  • - Getting pastes.
  • - User endpoints.
  • - Sync client.
    • This one will take some time as I have no motivation to do it, but PRs are welcome if others want to do it.

Installation

This project will be on PyPI as a stable release, you can always find that there.

Installing via pip:

python -m pip install -U mystbin.py

Installing from source:

python -m pip install git+https://github.com/PythonistaGuild/mystbin.py.git

Usage examples

Since the project is considered multi-sync, it will work in a sync/async environment, see the optional dependency of requests below.

# async example - it will default to async
import mystbin

mystbin_client = mystbin.Client()

paste = await client.create_paste(filename="Hello.txt", content="Hello there!")
str(paste)
>>> 'https://mystb.in/<your generated ID>'

get_paste = await mystbin_client.get_paste("<your generated ID>")
get_paste.files[0].content
>>> "Hello there!"

get_paste.created_at
>>> datetime.datetime(2020, 10, 6, 10, 53, 57, 556741)

Or if you want to create a paste with multiple files...

import mystbin

file = mystbin.File(filename="File1.txt", content="Hello there!")
file2 = mystbin.File(filename="test.py", content="print('hello!')")

paste = await client.create_multifile_paste(files=[file, file2])

for file in paste.files:
    print(file.content)

>>> "Hello there!"
>>> "print('hello!')"

If you have any question please feel free to join the Pythonista Discord server:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].