tf2-sku-to-name 1.0.6__py3-none-any.whl → 2.0.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,106 @@
1
+ Metadata-Version: 2.4
2
+ Name: tf2-sku-to-name
3
+ Version: 2.0.0
4
+ Summary: A python library that parses TF2 item SKU to the item's name and vice versa.
5
+ Home-page: https://github.com/purplebarber/tf2-sku
6
+ Author: Purple Barber
7
+ License: MIT
8
+ Keywords: tf2,tf2-sku,team fortress 2,sku,parser
9
+ Classifier: Programming Language :: Python :: 3
10
+ Classifier: Programming Language :: Python :: 3.6
11
+ Classifier: Programming Language :: Python :: 3.7
12
+ Classifier: Programming Language :: Python :: 3.8
13
+ Classifier: Programming Language :: Python :: 3.9
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: License :: OSI Approved :: MIT License
17
+ Classifier: Operating System :: OS Independent
18
+ Requires-Python: >=3.6
19
+ Description-Content-Type: text/markdown
20
+ License-File: LICENSE
21
+ Requires-Dist: requests
22
+ Dynamic: author
23
+ Dynamic: classifier
24
+ Dynamic: description
25
+ Dynamic: description-content-type
26
+ Dynamic: home-page
27
+ Dynamic: keywords
28
+ Dynamic: license
29
+ Dynamic: license-file
30
+ Dynamic: requires-dist
31
+ Dynamic: requires-python
32
+ Dynamic: summary
33
+
34
+ # tf2-sku
35
+
36
+ A Python library for parsing Team Fortress 2 item SKUs to item names and vice versa.
37
+
38
+ ## Features
39
+ - Convert SKUs to item names
40
+ - Convert item names to SKUs
41
+
42
+ ## Installation
43
+
44
+ ```bash
45
+ pip install tf2-sku-to-name
46
+ ```
47
+
48
+ ## Quick Start
49
+
50
+ ```python
51
+ from sku import Sku
52
+
53
+ # Convert SKU to name
54
+ sku = "5021;6"
55
+ name = Sku.sku_to_name(sku)
56
+ print(name) # Output: Mann Co. Supply Crate Key
57
+
58
+ # Convert name to SKU
59
+ name = "Burning Flames Team Captain"
60
+ sku = Sku.name_to_sku(name)
61
+ print(sku) # Output: 378;5;u13
62
+
63
+ # Working with item objects
64
+ from sku import itemClass
65
+
66
+ item = itemClass()
67
+ item.Defindex = 424
68
+ item.Quality = 11
69
+ item.Killstreak = 3
70
+
71
+ sku = Sku.object_to_sku(item)
72
+ print(sku) # Output: 424;11;kt-3
73
+ ```
74
+
75
+ ## Advanced Usage
76
+
77
+ ### Schema Management
78
+
79
+ The library automatically manages TF2 schema data:
80
+
81
+ ```python
82
+ from sku import get_schema, update_schema
83
+
84
+ # Get the current schema instance
85
+ schema = get_schema()
86
+
87
+ # Access schema data
88
+ item = schema.get_item_by_defindex(5021)
89
+ print(item['item_name']) # Mann Co. Supply Crate Key
90
+
91
+ # Force update schema (by default uses autobot.tf)
92
+ update_schema()
93
+
94
+ # Or use Steam API (requires API key)
95
+ update_schema(api_key="YOUR_STEAM_API_KEY", use_autobot=False)
96
+ ```
97
+
98
+ ## Installation
99
+ ```bash
100
+ pip install tf2-sku-to-name
101
+ ```
102
+
103
+ ## Acknowledgements
104
+ [TF2Autobot's node-tf2-schema](https://github.com/TF2Autobot/node-tf2-schema) for the original JavaScript implementation\
105
+ [idinium96's tf2autobot](https://github.com/TF2Autobot/tf2autobot) for the item name schema\
106
+ Inspired by [Nicklason's node-tf2-sku](https://github.com/Nicklason/node-tf2-sku) and [TryHardDo's TF2Sku](https://github.com/TryHardDo/TF2Sku/tree/master)
@@ -0,0 +1,9 @@
1
+ sku/__init__.py,sha256=77dSD2mzT1jgk-OYCWpuHVBTBCmWMdqfbwCONzmd2s0,377
2
+ sku/models.py,sha256=9jQimlGwJrJRmAY5o9PTKfdgp5kRajjMcH-Xp3GA35k,804
3
+ sku/parser.py,sha256=f-myoUIpbNyAT9tUct0gsZSG14VKnZA9IV6SllsTvKA,26650
4
+ sku/schema.py,sha256=MxfQGo8dAm5O_YZ0uzicQwULSz-4khoz_-l04i6uEZ8,25051
5
+ tf2_sku_to_name-2.0.0.dist-info/licenses/LICENSE,sha256=oZXGpA1oKt4L1lkrblMbut3_ClR3etussSbI0pBkL38,1070
6
+ tf2_sku_to_name-2.0.0.dist-info/METADATA,sha256=vMREIUXo44PBZcUhbWTWCKksodvujdKiwPTeZgCSh2c,2723
7
+ tf2_sku_to_name-2.0.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
8
+ tf2_sku_to_name-2.0.0.dist-info/top_level.txt,sha256=2ekTXVLQ1fHUW3ge6PK7EaoEwkUy0tnsaDvoNkPXfNw,4
9
+ tf2_sku_to_name-2.0.0.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.37.1)
2
+ Generator: setuptools (80.9.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5