Skip to main content

MapleStory OpenAPI Python Library

PyPi Python

This Python library enables the use of the MapleStory OpenAPI of Nexon.

Packages written in other languages can be found HERE.

English | 한국어

Notice

💡 Notice 1: Migration is required when updating to version 3.5.0. Please refer to the documentation for Migration.

🌏 Notice 2: Starting from version 3.4.0, support for tms region has been added. You can now retrieve data from KMS, TMS, MSEA.

🌏 Notice 3: Starting from version 3.0.0, support for msea region has been added.

💡 Notice 4: Migration is required when updating from version 2.x.x to 3.0.0. Please refer to the documentation for Migration.

Installation

Install the latest version of the Python library in your python project:

pip install maplestory-openapi

Usage

API Key

Before using the library, register your application and obtain an api key from the Nexon Open API Console.

Applications must be registered separately for each region. (For example, an API key issued for KMS cannot be used to request data from MSEA.)

Region

Currently, this library supports data retrieval from the KMS, TMS, MSEA regions. To access data from a specific region, import the corresponding package path.

from maplestory_openapi.kms import MapleStoryApi # data from KMS
# or
from maplestory_openapi.msea import MapleStoryApi # data from MSEA

Even though the regions differ, each package inherits the same interface, ensuring a consistent API usage experience across all regions.

Sample Code

Below is an example that retrieves the identifier of a specific character from the KMS server based on the nickname, and then fetches that character’s basic information.

from maplestory_openapi.kms import MapleStoryApi
from maplestory_openapi.common import MapleStoryApiException

api_key = '{Your API Key}'
api = MapleStoryApi(api_key=api_key)

# run your code
try:
    character = api.get_character_id('{Your Character Name}')
    character_basic = api.get_character_basic(ocid=character.ocid)

    print(character_basic)
# exception handling
except MapleStoryApiException as e:
    # handle MapleStoryApiException

You can find more examples in the test cases at the following link.

Features

This library supports all apis published in the MapleStory OpenAPI official docs.

Some features are supported only in specific regions. Please refer to the official documentation for each region for details.

Exception Handling

Handle MapleStoryApiException to safely make calls, ensuring that specific Status defined in the MapleStory OpenAPI Guide are not encountered.

While MapleStoryApi is designed to prevent the occurrence of certain Status, exceptions may arise due to developer mistakes.

Therefore, it's recommended to use MapleStoryApiException for exception handling based on the error code list described in the table below.

ErrorCode Description
OPENAPI00001 Internal server error
OPENAPI00002 Access denied
OPENAPI00003 Invalid identifier
OPENAPI00004 Request format error (incorrect parameter input)
OPENAPI00005 Invalid api key
OPENAPI00006 Invalid api path
OPENAPI00007 Request allowance (Rate Limit) exceeded
OPENAPI00009 Not prepared data
OPENAPI00010 Game server maintenance
OPENAPI00011 API server maintenance

Metadata

Release files for maplestory-openapi 3.12.1

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

Source distribution (sdist)

Source distribution for maplestory-openapi 3.12.1
File Size Uploaded Provenance Actions
maplestory_openapi-3.12.1.tar.gz 92.7 kB Without provenance Details for maplestory_openapi-3.12.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for maplestory-openapi 3.12.1
File Interpreter ABI Platform Actions
maplestory_openapi-3.12.1-py3-none-any.whl Python 3 none any Details for maplestory_openapi-3.12.1-py3-none-any.whl

Total release size: 261.1 kB

Release files / maplestory_openapi-3.12.1.tar.gz

Download URL maplestory_openapi-3.12.1.tar.gz
Size 92.7 kB
Tags Source
SHA-256 checksum
How to use checksums
bad63171e383ad9c66f0b2d5c7d2d47b4e6dae4bed8565e68e5a58e5e6b1014b
BLAKE2b-256 checksum
How to use checksums
c8daa09ff515e3aaef8082dc08e253b7a751018eb292b64798d623a85f1f72bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.22

Release files / maplestory_openapi-3.12.1-py3-none-any.whl

Download URL maplestory_openapi-3.12.1-py3-none-any.whl
Size 168.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
efa6ff454ec0a629ed7d1a86bc8590650ba11c349b7fa2e6ca71a9ab4e2df3ef
BLAKE2b-256 checksum
How to use checksums
4993e83a8058bb29749d687968815f69897d9969817a5a1574b440910958f435
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.22

Security for maplestory-openapi 3.12.1

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

3.12.1 This release

2 release files 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