Skip to main content

mysb-scraping

MySoftbankをスクレイピングして通信データ残量をLINE通知するやつ

Install

$ pip3 install mysb-scraping

Initialize

import mysoftbank

telnum = "your_phone_number"
password = "your_MySoftbank_password"
line_access_token = "your_line_notify_access_token"

api = mysoftbank.API(telnum=telnum, password=password, line_access_token=line_access_token)

Feature

# データ(使用量、残量、繰越残量、追加量、追加使用量、追加繰越量、追加繰越使用量)の取得
data = api.get_data()
print(data)

# out
{
    'used_data': 6.34,
    'remain_data': 0.02, 
    'step_remain_data': 0.0,
    'additional_data': 1.0,
    'additional_used_data': 0.98,
    'given_data': 0.36, 
    'given_used_data': 0.36
}
# lineに通知
status = api.send_message()
print(status)

# out
200

Demo

サンプルコードを実行した!

Metadata

Release files for mysb-scraping 5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for mysb-scraping 5.0
File Interpreter ABI Platform Actions
mysb_scraping-5.0-py3-none-any.whl Python 3 none any Details for mysb_scraping-5.0-py3-none-any.whl

Release files / mysb_scraping-5.0-py3-none-any.whl

Download URL mysb_scraping-5.0-py3-none-any.whl
Size 4.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f5a418797b6472b24dab1baefd370735a788d5b4f111955a987793f4067d8a64
BLAKE2b-256 checksum
How to use checksums
702d054e69704c24b7621e774a907f96bfc2c38b7b93070b950c3d8c5bf1571d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.7

Security for mysb-scraping 5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

5.0 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page