Skip to main content

Python SDK for the OpenSea API

PyPI version python

An unofficial Python SDK for the OpenSea API.

Features

  • Typing
  • All endpoints supported
  • Optional API key
  • WebSocket support

Installation

pip install py-opensea-sdk

Upgrade

pip install py-opensea-sdk -U

Usage

from pyopensea import OpenSeaAPI

# Create API instance
api = OpenSeaAPI('OPTIONAL-API-KEY')

# Examples
api.assets(owner='0x20481b79a4F03b624D214d23aDf5bF5f33bEB4aA')

api.contract('0x8a90cab2b38dba80c64b7734e58ee1db38b8992e')

api.listings('0x8a90cab2b38dba80c64b7734e58ee1db38b8992e', tokenID=10)

api.offers('0x8a90cab2b38dba80c64b7734e58ee1db38b8992e', tokenID=10, limit=5)

api.orders()

from datetime import datetime
# Note: datetime objects are automatically converted to the UTC timezone
api.orders('0x8a90cab2b38dba80c64b7734e58ee1db38b8992e',
           listedAfter=datetime(2022, 7, 5))

api.events(occurredAfter=1658423412, occurredBefore=1658425412,
           limit=1, eventType='successful')
# Note: datetime objects are automatically converted to the UTC timezone
api.events(occurredAfter=datetime(2022, 7, 3), occurredBefore=datetime(2022, 7, 5),
           limit=1, eventType='successful')

# And more api endpoints supported...

Contributing

  1. Fork it (https://github.com/FastestMolasses/PyOpensea/fork)
  2. Create your feature branch (git checkout -b feature/fooBar)
  3. Commit your changes (git commit -am 'Add some fooBar')
  4. Push to the branch (git push origin feature/fooBar)
  5. Create a new Pull Request

Metadata

Release files for py-opensea-sdk 1.0.4

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

Source distribution (sdist)

Source distribution for py-opensea-sdk 1.0.4
File Size Uploaded
py-opensea-sdk-1.0.4.tar.gz 5.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for py-opensea-sdk 1.0.4
File Interpreter ABI Platform
py_opensea_sdk-1.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 12.8 kB

Release files / py-opensea-sdk-1.0.4.tar.gz

Download URL py-opensea-sdk-1.0.4.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d1d14494b987d5ded09c4494dec11be002b1b35ffb621df457c438977780d5db
BLAKE2b-256 checksum
How to use checksums
25446d3485da16f9abbe1b2283c70c8d266e332b884c6a45e948b621ccccb053
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.5

Release files / py_opensea_sdk-1.0.4-py3-none-any.whl

Download URL py_opensea_sdk-1.0.4-py3-none-any.whl
Size 7.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7b2867cafcd744a57614282b88a00958b478f686f7063e9308db88263461c2ec
BLAKE2b-256 checksum
How to use checksums
591ba0f82ffce30f8b46fa22e115461c6d8e04a7053e611ba994716732b88daf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.5

Release history Release notifications | RSS feed

This release

1.0.4 This release

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

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