Skip to content

Commit 84419fd

Browse files
committed
Update mcc_api.island schema to support fish sell price, cosmetic/fish ownership count, and remove deprecated fields
1 parent f103ee5 commit 84419fd

File tree

4 files changed

+38
-31
lines changed

4 files changed

+38
-31
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![🐍 PyPI](https://img.shields.io/pypi/v/mcc-api?label=🐍%20PyPI)](https://pypi.org/project/mcc-api/)
44
[![👑 Targeting Event API v1.6.0](https://img.shields.io/badge/👑_Targeting_Event_API-v1.6.0-red)](https://github.com/Noxcrew/mcchampionship-api/releases/tag/v1.6.0)
5-
[![🏝️ Targeting Island API v24.12.17](https://img.shields.io/badge/🏝️_Targeting_Island_API-v24.12.17-aqua)](https://github.com/Noxcrew/mccisland-api/releases/tag/v24.12.17)
5+
[![🏝️ Targeting Island API v25.02.10](https://img.shields.io/badge/🏝️_Targeting_Island_API-v25.02.10-aqua)](https://github.com/Noxcrew/mccisland-api/releases/tag/v25.02.10)
66

77
A helper library for the [MC Championship](https://mcchampionship.com) APIs
88
([Event](https://github.com/Noxcrew/mcchampionship-api), inspired by [derNiklaas's](https://github.com/derNiklaas)

docs/index.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ python_mcc_api
77
.. image:: https://img.shields.io/badge/👑_Targeting_Event_API-v1.6.0-red
88
:alt: 👑 Targeting Event API v1.6.0
99
:target: https://github.com/Noxcrew/mcchampionship-api/releases/tag/v1.6.0
10-
.. image:: https://img.shields.io/badge/🏝️_Targeting_Island_API-v24.12.17-aqua
11-
:alt: 🏝️ Targeting Island API v24.12.17
12-
:target: https://github.com/Noxcrew/mccisland-api/releases/tag/v24.12.17
10+
.. image:: https://img.shields.io/badge/🏝️_Targeting_Island_API-v25.02.10-aqua
11+
:alt: 🏝️ Targeting Island API v25.02.10
12+
:target: https://github.com/Noxcrew/mccisland-api/releases/tag/v25.02.10
1313

1414
A helper library for the `MC Championship <https://mcchampionship.com>`_ APIs
1515
(`Event <https://github.com/Noxcrew/mcchampionship-api>`_, inspired by `derNiklaas's <https://github.com/derNiklaas>`_

mcc_api/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"__version__"
55
]
66

7-
__version__ = "1.2.0"
7+
__version__ = "1.3.0"
88
__user_agent: t.Final[str] = f"python_mcc_api/{__version__} (https://github.com/JamesMCo/python_mcc_api)"
99

1010
# update version of package

mcc_api/island/types.py

+33-26
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,15 @@
9797
GraphQLNonNull(GraphQLBoolean),
9898
description="If this cosmetic can be colored using Chroma Packs."
9999
),
100+
"globalNumberOwned": GraphQLField(
101+
GraphQLString,
102+
description="The number of people who own this cosmetic.\n\n"
103+
"The exact number is only displayed if fewer than 1000 players own this cosmetic.\n"
104+
"Otherwise, either `1000+` or `10000+` will be returned, indicating the real value is higher "
105+
"than this number.\n"
106+
"Some cosmetics are excluded from ownership reporting, for these cosmetics `null` will be "
107+
"returned."
108+
),
100109
"isBonusTrophies": GraphQLField(
101110
GraphQLBoolean,
102111
description="If this cosmetic awards bonus trophies.\n\n"
@@ -143,34 +152,14 @@
143152
name="CrownLevel",
144153
description="A Crown Level and associated trophy data.",
145154
fields=lambda: {
146-
"evolution": GraphQLField(
147-
GraphQLNonNull(GraphQLInt),
148-
description="The zero-indexed evolution of the crown.",
149-
deprecation_reason="Use levelData instead."
150-
),
151155
"fishingLevelData": GraphQLField(
152156
GraphQLNonNull(level_data_type),
153157
description="The fishing level data."
154158
),
155-
"level": GraphQLField(
156-
GraphQLNonNull(GraphQLInt),
157-
description="The overall Crown Level.",
158-
deprecation_reason="Use levelData instead."
159-
),
160159
"levelData": GraphQLField(
161160
GraphQLNonNull(level_data_type),
162161
description="The overall level data."
163162
),
164-
"nextEvolutionLevel": GraphQLField(
165-
GraphQLInt,
166-
description="The next level that the crown will evolve, if any.",
167-
deprecation_reason="Use levelData instead."
168-
),
169-
"nextLevelProgress": GraphQLField(
170-
progression_data_type,
171-
description="The progress the player is making towards their next level, if any.",
172-
deprecation_reason="Use levelData instead."
173-
),
174163
"trophies": GraphQLField(
175164
GraphQLNonNull(trophy_data_type),
176165
description="The amount of trophies the player has.",
@@ -196,11 +185,6 @@
196185
GraphQLNonNull(GraphQLInt),
197186
description="The number of coins the player currently has."
198187
),
199-
"gems": GraphQLField(
200-
GraphQLNonNull(GraphQLInt),
201-
description="The number of gems the player currently has.",
202-
deprecation_reason="Deprecated for removal. Will always return 0 until removal."
203-
),
204188
"materialDust": GraphQLField(
205189
GraphQLNonNull(GraphQLInt),
206190
description="The number of material dust the player currently has."
@@ -218,7 +202,9 @@
218202

219203
fish_type = GraphQLObjectType(
220204
name="Fish",
221-
description="A fish.",
205+
description="A fish.\n\n"
206+
"Queries on this type that accept a weight as an argument will return `null` if this fish does not "
207+
"support the provided weight.",
222208
fields={
223209
"catchTime": GraphQLField(
224210
GraphQLNonNull(fish_catch_time_enum),
@@ -236,6 +222,18 @@
236222
GraphQLNonNull(GraphQLBoolean),
237223
description="If this fish is elusive."
238224
),
225+
"globalNumberCaught": GraphQLField(
226+
GraphQLString,
227+
description="The number of people who have caught this fish.\n\n"
228+
"The exact number is only displayed if fewer than 1000 players have caught this fish.\n"
229+
"Otherwise, either `1000+` or `10000+` will be returned, indicating the real value is higher "
230+
"than this number.",
231+
args={
232+
"weight": GraphQLArgument(
233+
GraphQLNonNull(fish_weight_enum)
234+
)
235+
}
236+
),
239237
"name": GraphQLField(
240238
GraphQLNonNull(GraphQLString),
241239
description="The name of the fish."
@@ -252,6 +250,15 @@
252250
GraphQLNonNull(fish_weight_enum)
253251
)
254252
}
253+
),
254+
"sellingPrice": GraphQLField(
255+
GraphQLInt,
256+
description="The number of A.N.G.L.R. Tokens given for selling this fish in a given weight.",
257+
args={
258+
"weight": GraphQLArgument(
259+
GraphQLNonNull(fish_weight_enum)
260+
)
261+
}
255262
)
256263
}
257264
)

0 commit comments

Comments
 (0)