Skip to main content

Nintendo Switch Online API bridge (for Nintendo Switch Online API wrapper)

Project description

Nintendo Switch Online API Bridge

Nintendo Switch Online API bridge (for Nintendo Switch Online API wrapper)

What is it?

Nintendo Switch Online API Bridge is a simple wrapper. It allows you to easily access the API and get the data you need.

Installation

pip install nso-bridge
pip install git+https://github.com/zeroday0619/Nintendo_Switch_Online_API_Bridge.git

Example Code

GetSelf

Get information of My Nintendo Switch Account.

import json
import keyring

from nso_bridge.nsa import NintendoSwitchAccount
from nso_bridge.nso import NintendoSwitchOnlineAPI

import logging

logging.basicConfig(level=logging.DEBUG, format='%(asctime)s - %(levelname)s - %(message)s')

app = NintendoSwitchAccount()

# override the nso_app_version
app.nso_app_version = app.get_nso_app_version()
session_token = keyring.get_password("nso-bridge", "session_token")


nso_res = NintendoSwitchOnlineAPI(
    nso_app_version=app.nso_app_version,
    session_token=session_token,
)
nso_res.sync_login()
print(json.dumps(nso_res.getCurrentUser(), indent=4, ensure_ascii=False))

GetFriends

Get information of friends registered to Nintendo Switch account.

import json
import keyring

from nso_bridge.nsa import NintendoSwitchAccount
from nso_bridge.nso import NintendoSwitchOnlineAPI

import logging

logging.basicConfig(level=logging.DEBUG, format='%(asctime)s - %(levelname)s - %(message)s')

app = NintendoSwitchAccount()

# override the nso_app_version
app.nso_app_version = app.get_nso_app_version()
session_token = keyring.get_password("nso-bridge", "session_token")


nso_res = NintendoSwitchOnlineAPI(
    nso_app_version=app.nso_app_version,
    session_token=session_token,
)
nso_res.sync_login()
print(json.dumps(nso_res.getFriends(), indent=4, ensure_ascii=False))

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

nso-bridge-0.1.7.tar.gz (10.1 kB view details)

Uploaded Source

Built Distribution

nso_bridge-0.1.7-py2.py3-none-any.whl (9.2 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file nso-bridge-0.1.7.tar.gz.

File metadata

  • Download URL: nso-bridge-0.1.7.tar.gz
  • Upload date:
  • Size: 10.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.28.1

File hashes

Hashes for nso-bridge-0.1.7.tar.gz
Algorithm Hash digest
SHA256 01dbd32c6873ac4f852c0c2313fc3ec87274d15c7d19928ede600961211a1b93
MD5 45f71219c9d68c5909ae98663615d5bf
BLAKE2b-256 17dfeb3c88b5bb2bcf0012a76125bb24188fbc84d60f4760a23e06b546e89c62

See more details on using hashes here.

File details

Details for the file nso_bridge-0.1.7-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for nso_bridge-0.1.7-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 2a0c2698f5f08cf9bf9789243d8f5026c9c25558fb370bebd13452af6b052a05
MD5 8cd5c3795d0bb6efa1405891aa0f740c
BLAKE2b-256 2934c0bf5201eb12ee8e74aa86ebd3b2c29e2b3c240da93fe26c6a0f207bbc00

See more details on using hashes here.

Supported by

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