mdfy plugin for esa.
Project description
mdfy-esa
mdfy plugin for esa
- Documentation: https://argonism.github.io/mdfy-esa
- GitHub: https://github.com/argonism/mdfy-esa
- PyPI: https://pypi.org/project/mdfy-esa/
- Free software: MIT
Usage
The mdfy-esa feature supports uploading of local images and files. With the EsaMdfier, images or files designated with MdImage or MdLink are uploaded automatically. Simply pass the MdImage with the local image path, and voila - it’s done!"
from mdfy import MdImage, MdLink, MdText
from mdfy_esa import EsaMdfier
esa_team = "your esa team name"
post_fullname = "post name as you like"
contents = [
MdText("This is a test article."),
MdImage(src="examples/test_image.png"),
MdLink(url="examples/dummy.pdf"),
]
mdfier = EsaMdfier(post_fullname=post_fullname, esa_team=esa_team)
created_post_info = mdfier.write(contents=contents)
# created_post_info = {'number': 4418, 'name': 'My Test Article', 'full_name': 'note/me/My Test Article', 'wip': True, 'body_md': 'This is a test article.\n', 'body_html': '<p data- ...}
# see esa.io api document for detail
# https://docs.esa.io/posts/102#POST%20/v1/teams/:team_name/posts
You can also update an existing post using its post number!
from mdfy import MdImage, MdLink, MdText
from mdfy_esa import EsaMdfier
esa_team = "your esa team name"
post_number = 4930
contents = [
MdText("NEW! This post is updated!"),
MdText("This is a test article."),
MdImage(src="examples/test_image.png"),
MdLink(url="examples/dummy.pdf"),
]
mdfier = EsaMdfier(post_number=post_number, esa_team=esa_team)
updated_post_info = mdfier.write(contents=contents)
Features
- TODO
Credits
This package was created with Cookiecutter and the waynerv/cookiecutter-pypackage project template.
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
mdfy_esa-0.3.0.tar.gz
(4.7 kB
view details)
Built Distribution
File details
Details for the file mdfy_esa-0.3.0.tar.gz
.
File metadata
- Download URL: mdfy_esa-0.3.0.tar.gz
- Upload date:
- Size: 4.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b4a14c6f1a5528162f728b3241a0530214422b24b6f2d3eb787d6c7f8aaa1273 |
|
MD5 | 066786854b23f0c4f81b1a5af5e297c7 |
|
BLAKE2b-256 | b06f84661691e5d771cf815d277488d3841269bc590382fbbdc29ebfdf542152 |
File details
Details for the file mdfy_esa-0.3.0-py3-none-any.whl
.
File metadata
- Download URL: mdfy_esa-0.3.0-py3-none-any.whl
- Upload date:
- Size: 4.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f76bb7fc7cfc7f01f6180d49c526c0f55b19d5654d7cbe0cba7639c85af08c12 |
|
MD5 | 7bff36e2b5572b52836e49b1bc07d270 |
|
BLAKE2b-256 | 4b79fc52dffe6b1a43a02aa7c149c70549c3e9f971e214d1df67de1ba2f13798 |