Skip to main content

An unofficial Python wrapper for Disney's API

Project description

MouseTools

PyPI - Version PyPI - Downloads

An unofficial Python wrapper for the Disney API. Data is pulled directly from Disney. This package supports Walt Disney World and Disneyland Resort.

This package makes no attempt to access data that would require individual user authentication. All data is pulled using public channels.

Installation

You can install using pip:

pip install mousetools

You can also install directly from this repo in case of any changes not uploaded to Pypi.

pip install git+https://gitlab.com/caratozzoloxyz/public/MouseTools

Usage

The Disney API considers everything an entity. Attractions, resorts, restaurants, etc, are all entities. Entities belong to channels, or a group of entities.

Getting Started

You'll want to create a facility channel object.

from mousetools.channels.facilities import AttractionFacilityChild

pirates = AttractionFacilityChild("wdw.facilities.1_0.en_us.attraction.80010177;entityType=Attraction")

All Facility Entities inherit from FacilityChildChannel.

print(pirates.name)
# 'Pirates of the Caribbean'

print(pirates.ancestor_theme_park_id)
# '80007944;entityType=theme-park'

In order to access a facility's live data, you'll need a FacilityStatusChildChannel. Fortunately for you, this can be quickly done from the facility object.

fs = pirates.get_facility_status_channel()
print(fs.get_wait_time())
# 15

print(fs.get_status())
# 'Operating'

Alternatively, you can create the object yourself.

from mousetools.channels.facilitystatus import FacilityStatusChannel

fsc = FacilityStatusChannel("wdw.facilitystatus.1_0.80010177;entityType=Attraction", lazy_load=False)
print(fs.last_update)
# 2025-05-15 22:52:52.176069-04:00

NOTE: All channels are lazy loaded, meaning there is no request sent to load the data until an object's attributes are accessed. This allows objects to be created faster, and reduce requests to Disney's servers until the data is actually needed.

For ease of use, you can use the available channel enums or facility enums to get access to a destination facility's children channels.

from mousetools.channels.facilities import FacilityChannel, ThemeParkFacilityChild
from mousetools.channel.facilities.enums import WaltDisneyWorldParkChannelIds
from mousetools.channels.facilitystatus import FacilityStatusChannel
from mousetools.channels.enums import WDWCouchbaseChannels, DLRCouchbaseChannels

wdw = FacilityChannel(WDWCouchbaseChannels.FACILITIES)
print(list(wdw.get_children_attractions()))
# [Attraction(wdw.facilities.1_0.en_us.123), Attraction(wdw.facilities.1_0.en_us.456), ...]

dlr = FacilityStatusChannel(DLRCouchbaseChannels.FACILITY_STATUS)
print(dlr.get_children_channel_ids())
# ["dlr.facilitystatus.1_0.123", "dlr.facilitystatus.1_0.456", ...]

mk = ThemeParkFacilityChild(WaltDisneyWorldParkChannelIds.MAGIC_KINGDOM, lazy_load=False)
print(mk.description)
# "Enter a Land Where Fantasy Reigns"

There is also a search functionality to help find the channels you want.

from mousetools.api.search import Search
from mousetools.enums import DestinationShort

search = Search(DestinationShort.WALT_DISNEY_WORLD)
print(search("pirates", max_results=1))
# [{'channel_id': 'wdw.facilities.1_0.en_us.attraction.80010177;entityType=Attraction',
#   'entity_id': '80010177;entityType=Attraction',
#   'name': 'Pirates of the Caribbean',
#   'search_score': 3507.1604}]

License

This project is distributed under the MIT license. For more information see LICENSE

Disclaimer

This project is in no way affiliated with The Walt Disney Company and all use of Disney Services is subject to the Disney Terms of Use.

About Project

Support my projects

MouseTools is a passion project I've been working on since 2018 when I was first learning Python. The package has evolved and been rewritten multiple times as I've become a better developer and as the Disney API has changed. There is a lot of time exploring Disney's API and figuring out how all the pieces work before any code is even written. I work on this project when I have time or when I have an idea for another project that could use this data.

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

mousetools-4.5.1.tar.gz (70.0 kB view details)

Uploaded Source

Built Distribution

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

mousetools-4.5.1-py3-none-any.whl (72.4 kB view details)

Uploaded Python 3

File details

Details for the file mousetools-4.5.1.tar.gz.

File metadata

  • Download URL: mousetools-4.5.1.tar.gz
  • Upload date:
  • Size: 70.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for mousetools-4.5.1.tar.gz
Algorithm Hash digest
SHA256 6430ad97b22ef4b5b09312ae3d15cade995df02c9592234688dab51da05dbec1
MD5 e45e3c7eef9d405044687ec5cbf67b74
BLAKE2b-256 040fba574d4ee7d76d47b03c2d0e160a82aa25073ee506bcd4dd8bdd368661d8

See more details on using hashes here.

File details

Details for the file mousetools-4.5.1-py3-none-any.whl.

File metadata

  • Download URL: mousetools-4.5.1-py3-none-any.whl
  • Upload date:
  • Size: 72.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for mousetools-4.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 52134a682241c6bdda87c8d92282b5fa9b9f74db2d1acc499605c5d75eeb09d3
MD5 53d727cdd4bf8836d9af9476a6db535b
BLAKE2b-256 6b9e1fb6a8ee51a49c8a8364dd7d9d1989629bc76517da2e19033d950560f1e4

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