Moved files around for uploading to PyPI.
This commit is contained in:
parent
b1afa6a302
commit
78604b4099
|
@ -1,2 +1,2 @@
|
|||
aiohttp
|
||||
#Requirements for PyPI
|
||||
asyncio
|
||||
|
|
|
@ -0,0 +1,26 @@
|
|||
# Rulings
|
||||
|
||||
Documentation for a rulings object. These docs will likely not be as detailed as the official Scryfall Documentation, and you should reference that for more information.
|
||||
|
||||
>In the event that a key isn't found or has been changed, you can access the full JSON output with the `scryfallJson` variable (`card.scryfallJson`).
|
||||
|
||||
## Attributes
|
||||
All attributes are listed assuming the following
|
||||
`rule = scrython.rulings.<Class>()` is the current usage.
|
||||
|
||||
|Name|Data type returned|Description|
|
||||
|:---:|:---:|:---:|
|
||||
|`object()`|String|Returns the type of object it is. (card, error, etc)|
|
||||
|`had_more()`|Bool| If true, this ruling object has more rules than it currently displays.|
|
||||
|`data()`|List|A list of ruling objects.
|
||||
|`data_length()`|Integer|The length of the `data` list.|
|
||||
|`ruling_object()`|String|The type of object for a given ruling. Requires an integer as a parameter, which acts as a tuple.|
|
||||
|`ruling_source()`|String|The source of the ruling. Requires an integer as a parameter, which acts as a tuple.|
|
||||
|`ruling_published_at()`|String|The date when the ruling was published. Requires an integer as a parameter, which acts as a tuple.|
|
||||
|`ruling_comment()`|String|The effective ruling. Requires an integer as a parameter, which acts as a tuple.|
|
||||
|
||||
Example usage:
|
||||
|
||||
rule = scrython.rulings.Id(id="0f91d225-788e-42fc-9d01-8668f672b717")
|
||||
rule.ruling_comment(5)
|
||||
>>>"If you control multiple As Foretolds, you may cast one spell for each of them paying {0}."
|
|
@ -0,0 +1,66 @@
|
|||
# Rulings Classes
|
||||
|
||||
## `rulings.Id()`
|
||||
Gets the ruling of a card by the Scryfall Id.
|
||||
|
||||
**Parameters:**
|
||||
|
||||
| Param |Required [y/n]| Input type | Description |
|
||||
| :---: | :---: | :---: |:---: |
|
||||
|id|Yes|String|The id of the card you want rulings for.|
|
||||
|
||||
**Attributes:**
|
||||
The same listed in the `rulings` documentation.
|
||||
|
||||
Example usage:
|
||||
|
||||
rule = scrython.rulings.Id(id='31412335-110c-449a-9c2f-bff8763a6504')
|
||||
|
||||
## `rulings.Mtgo()`
|
||||
Gets the ruling of a card by the Mtgo Id.
|
||||
|
||||
**Parameters:**
|
||||
|
||||
|Param|Required [y/n]|Input type|Description|
|
||||
|:---:|:---:|:---:|:---:|
|
||||
|id|Yes|String|The Mtgo id of the card you want rulings for.|
|
||||
|
||||
**Attributes:**
|
||||
The same listed in the `rulings` documentation.
|
||||
|
||||
Example usage:
|
||||
|
||||
rule = scrython.rulings.Mtgo(id="24811")
|
||||
|
||||
## `rulings.Multiverse()`
|
||||
Gets the ruling of a card by the Multiverse Id.
|
||||
|
||||
**Parameters:**
|
||||
|
||||
|Param|Required [y/n]|Input type|Description|
|
||||
|:---:|:---:|:---:|:---:|
|
||||
|id|Yes|String|The Multiverse Id of the card you want rulings for.|
|
||||
|
||||
**Attributes:**
|
||||
The same listed in the `rulings` documentation.
|
||||
|
||||
Example usage:
|
||||
|
||||
rule = scrython.rulings.Multiverse(id="124451")
|
||||
|
||||
## `rulings.Code()`
|
||||
Gets the ruling of a card by the set code and collector number.
|
||||
|
||||
**Parameters:**
|
||||
|
||||
|Param|Required [y/n]|Input type|Description|
|
||||
|:---:|:---:|:---:|:---:|
|
||||
|code|Yes|String|The 3 letter set code of the card.|
|
||||
|collector_number|Yes|String|The collector number of the card.|
|
||||
|
||||
**Attributes:**
|
||||
The same listed in the `rulings` documentation.
|
||||
|
||||
Example usage:
|
||||
|
||||
rule = scrython.rulings.Code(code='CSP', collector_number='142')
|
17
setup.py
17
setup.py
|
@ -1,13 +1,24 @@
|
|||
from distutils.core import setup
|
||||
from setuptools import setup
|
||||
|
||||
requirements = []
|
||||
with open('requirements.txt') as f:
|
||||
requirements = f.read().splitlines()
|
||||
|
||||
readme = ''
|
||||
with open('README.md') as f:
|
||||
readme = f.read()
|
||||
|
||||
setup(
|
||||
name='scrython',
|
||||
packages=['scrython']
|
||||
packages=['scrython'],
|
||||
version='0.1.0',
|
||||
description='A wrapper for using the Scryfall API.',
|
||||
long_description=readme
|
||||
url='https://github.com/NandaScott/Scrython',
|
||||
download_url='https://github.com/NandaScott/Scrython/archive/0.1.0.tar.gz',
|
||||
author='Nanda Scott',
|
||||
author_email='nanda1123@gmail.com',
|
||||
license='MIT',
|
||||
keywords=['Scryfall', 'magic', 'the gathering', 'scrython', 'wrapper']
|
||||
keywords=['Scryfall', 'magic', 'the gathering', 'scrython', 'wrapper'],
|
||||
install_requires=requirements
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue