Skip to main content

mdfy plugin for esa.

Project description

mdfy-esa

pypi python Build Status test status codecov

mdfy plugin for esa

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.2.1.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mdfy_esa-0.2.1-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file mdfy_esa-0.2.1.tar.gz.

File metadata

  • Download URL: mdfy_esa-0.2.1.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for mdfy_esa-0.2.1.tar.gz
Algorithm Hash digest
SHA256 2470564194c0bb78cf5d0ef5d8314532014d11efee5e7a560ac8ae85323e7a9a
MD5 765be41c228467742f2e1fb056155af4
BLAKE2b-256 e7654bf073bfaf8fbb0c21790e4f51a741fa4b3b19961f026d2b17614749a1f1

See more details on using hashes here.

File details

Details for the file mdfy_esa-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: mdfy_esa-0.2.1-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

Hashes for mdfy_esa-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fafff18a4e6a01d686fef78faf095018b0a5b2eef40f2bcd3ddb925f9aa1d8af
MD5 bfd7d4b5a0b567ca8e8c2ee6c755080b
BLAKE2b-256 b2884b48057ba57354f41d823826bd6c5239b4b858ef18c0fefa73ca3b111348

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page