Ryzenth 1.8.3__py3-none-any.whl → 1.8.5__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.
Ryzenth/__init__.py CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env python
2
2
  # -*- coding: utf-8 -*-
3
- # Copyright 2021-2025 (c) Randy W @xtdevs, @xtsea
3
+ # Copyright 2019-2025 (c) Randy W @xtdevs, @xtsea
4
4
  #
5
5
  # from : https://github.com/TeamKillerX
6
6
  # Channel : @RendyProjects
Ryzenth/__version__.py CHANGED
@@ -1,4 +1,4 @@
1
- __version__ = "1.8.3"
1
+ __version__ = "1.8.5"
2
2
  __author__ = "TeamKillerX"
3
3
  __title__ = "Ryzenth"
4
4
  __description__ = "Ryzenth Python API Wrapper"
Ryzenth/_asynchisded.py CHANGED
@@ -20,6 +20,7 @@
20
20
  import logging
21
21
 
22
22
  import httpx
23
+ from box import Box
23
24
 
24
25
  from Ryzenth.types import QueryParameter
25
26
 
@@ -30,8 +31,31 @@ class RyzenthXAsync:
30
31
  self.api_key = api_key
31
32
  self.base_url = base_url.rstrip("/")
32
33
  self.headers = {"x-api-key": self.api_key}
34
+ self.images = self.ImagesAsync(self)
35
+ self.obj = Box
33
36
 
34
- async def send_downloader(self, switch_name: str = None, params: QueryParameter = None, list_key=False):
37
+ class ImagesAsync:
38
+ def __init__(self, parent):
39
+ self.parent = parent
40
+
41
+ async def generate(self, params: QueryParameter):
42
+ url = f"{self.parent.base_url}/v1/flux/black-forest-labs/flux-1-schnell"
43
+ async with httpx.AsyncClient() as client:
44
+ try:
45
+ response = await client.get(url, params=params.dict(), headers=self.parent.headers, timeout=30)
46
+ response.raise_for_status()
47
+ return response.content
48
+ except httpx.HTTPError as e:
49
+ LOGS.error(f"[ASYNC] Error: {str(e)}")
50
+ return None
51
+
52
+ async def send_downloader(
53
+ self,
54
+ switch_name: str = None,
55
+ params: QueryParameter = None,
56
+ list_key=False,
57
+ dot_access=False
58
+ ):
35
59
  dl_dict = {
36
60
  "teraboxv4": "terabox-v4",
37
61
  "twitterv3": "twitter-v3",
@@ -66,14 +90,21 @@ class RyzenthXAsync:
66
90
  timeout=10
67
91
  )
68
92
  response.raise_for_status()
69
- return response.json()
93
+ return self.obj(response.json() or {}) if dot_access else response.json()
70
94
  except httpx.HTTPError as e:
71
95
  LOGS.error(f"[ASYNC] Error: {str(e)}")
72
96
  return None
73
97
 
74
- async def send_message(self, model: str = None, params: QueryParameter = None, list_key=False):
98
+ async def send_message(
99
+ self,
100
+ model: str = None,
101
+ params: QueryParameter = None,
102
+ list_key=False,
103
+ dot_access=False
104
+ ):
75
105
  model_dict = {
76
106
  "hybrid": "AkenoX-1.9-Hybrid",
107
+ "hybrid-english": "AkenoX-1.9-Hybrid-Englsih",
77
108
  "melayu": "lu-melayu",
78
109
  "nocodefou": "nocodefou",
79
110
  "mia": "mia-khalifah",
@@ -102,7 +133,7 @@ class RyzenthXAsync:
102
133
  timeout=10
103
134
  )
104
135
  response.raise_for_status()
105
- return response.json()
136
+ return self.obj(response.json() or {}) if dot_access else response.json()
106
137
  except httpx.HTTPError as e:
107
138
  LOGS.error(f"[ASYNC] Error: {str(e)}")
108
139
  return None
Ryzenth/_synchisded.py CHANGED
@@ -20,6 +20,7 @@
20
20
  import logging
21
21
 
22
22
  import httpx
23
+ from box import Box
23
24
 
24
25
  from Ryzenth.types import QueryParameter
25
26
 
@@ -30,8 +31,35 @@ class RyzenthXSync:
30
31
  self.api_key = api_key
31
32
  self.base_url = base_url.rstrip("/")
32
33
  self.headers = {"x-api-key": self.api_key}
34
+ self.images = self.ImagesSync(self)
35
+ self.obj = Box
33
36
 
34
- def send_downloader(self, switch_name: str = None, params: QueryParameter = None, list_key=False):
37
+ class ImagesSync:
38
+ def __init__(self, parent):
39
+ self.parent = parent
40
+
41
+ def generate(self, params: QueryParameter):
42
+ url = f"{self.parent.base_url}/v1/flux/black-forest-labs/flux-1-schnell"
43
+ try:
44
+ response = httpx.get(
45
+ url,
46
+ params=params.dict(),
47
+ headers=self.parent.headers,
48
+ timeout=30
49
+ )
50
+ response.raise_for_status()
51
+ return response.content
52
+ except httpx.HTTPError as e:
53
+ LOGS.error(f"[SYNC] Error fetching from images {e}")
54
+ return None
55
+
56
+ def send_downloader(
57
+ self,
58
+ switch_name: str = None,
59
+ params: QueryParameter = None,
60
+ list_key=False,
61
+ dot_access=False
62
+ ):
35
63
  dl_dict = {
36
64
  "teraboxv4": "terabox-v4",
37
65
  "twitterv3": "twitter-v3",
@@ -64,14 +92,21 @@ class RyzenthXSync:
64
92
  timeout=10
65
93
  )
66
94
  response.raise_for_status()
67
- return response.json()
95
+ return self.obj(response.json() or {}) if dot_access else response.json()
68
96
  except httpx.HTTPError as e:
69
97
  LOGS.error(f"[SYNC] Error fetching from downloader {e}")
70
98
  return None
71
99
 
72
- def send_message(self, model: str = None, params: QueryParameter = None, list_key=False):
100
+ def send_message(
101
+ self,
102
+ model: str = None,
103
+ params: QueryParameter = None,
104
+ list_key=False,
105
+ dot_access=False
106
+ ):
73
107
  model_dict = {
74
108
  "hybrid": "AkenoX-1.9-Hybrid",
109
+ "hybrid-english": "AkenoX-1.9-Hybrid-Englsih",
75
110
  "melayu": "lu-melayu",
76
111
  "nocodefou": "nocodefou",
77
112
  "mia": "mia-khalifah",
@@ -99,7 +134,7 @@ class RyzenthXSync:
99
134
  timeout=10
100
135
  )
101
136
  response.raise_for_status()
102
- return response.json()
137
+ return self.obj(response.json() or {}) if dot_access else response.json()
103
138
  except httpx.HTTPError as e:
104
139
  LOGS.error(f"[SYNC] Error fetching from akenox: {e}")
105
140
  return None
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Ryzenth
3
- Version: 1.8.3
3
+ Version: 1.8.5
4
4
  Summary: Ryzenth Python Wrapper For Perfomance
5
5
  Author: TeamKillerX
6
6
  License: MIT
@@ -53,6 +53,13 @@ Dynamic: requires-python
53
53
  Dynamic: summary
54
54
 
55
55
  # Ryzenth Library
56
+ [![Open Source Love](https://badges.frapsoft.com/os/v2/open-source.png?v=103)](https://github.com/TeamKillerX/Ryzenth)
57
+ [![Maintenance](https://img.shields.io/badge/Maintained%3F-Yes-green)](https://github.com/TeamKillerX/Ryzenth/graphs/commit-activity)
58
+ [![GitHub Forks](https://img.shields.io/github/forks/TeamKillerX/Ryzenth?&logo=github)](https://github.com/TeamKillerX/Ryzenth)
59
+ [![License](https://img.shields.io/badge/License-GPL-pink)](https://github.com/TeamKillerX/Ryzenth/blob/main/LICENSE)
60
+ [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://makeapullrequest.com)
61
+ [![Ryzenth - Version](https://img.shields.io/pypi/v/Ryzenth?style=round)](https://pypi.org/project/Ryzenth)
62
+ [![pre-commit.ci status](https://results.pre-commit.ci/badge/github/TeamKillerX/Ryzenth/main.svg)](https://results.pre-commit.ci/latest/github/TeamKillerX/Ryzenth/main)
56
63
 
57
64
  **Ryzenth** is a powerful and flexible Python SDK for interacting with the new **Ryzenth API** a successor to the AkenoX API supporting both synchronous and asynchronous workflows out of the box.
58
65
 
@@ -0,0 +1,11 @@
1
+ Ryzenth/__init__.py,sha256=Xkdo2DrOr9eOGlRdLUC9blzsuHHGIC9WrzGs1j83d3I,944
2
+ Ryzenth/__version__.py,sha256=ODPSox1NrHL0AAM5MIJe7C0__Hxs6rf5MyMl4lHEn5A,118
3
+ Ryzenth/_asynchisded.py,sha256=6h5qh9vGr9MECtf6YgXW__Hr87Rig2C9mDuqPX5JIQ4,5022
4
+ Ryzenth/_synchisded.py,sha256=hJK-M3ovoH2i1SA-hSI7_veVzk_QD_OstLlBYRbUW7Q,4845
5
+ Ryzenth/ryzenth_client.py,sha256=fN_0BcK0ao6-CTpe5bRCT9jQD7Krr_Q8-Xlf-aFqdZY,1225
6
+ Ryzenth/types/__init__.py,sha256=Uq5xqwfI5f-QwEnDRycQFJ5_yJbwzZwsM4cqgo_Wpbw,985
7
+ ryzenth-1.8.5.dist-info/licenses/LICENSE,sha256=C73aiGSgoCAVNzvAHs-TROaf5vV8yCj9nqpGrmfNHHo,1068
8
+ ryzenth-1.8.5.dist-info/METADATA,sha256=_GA0RN1G6hBby4_cyzs10NTxJJgriwxcU66xlKsvotA,4143
9
+ ryzenth-1.8.5.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
10
+ ryzenth-1.8.5.dist-info/top_level.txt,sha256=0vIhjOjoQuCxLeZO0of8VCx2jsri-bLHV28nh8wWDnc,8
11
+ ryzenth-1.8.5.dist-info/RECORD,,
@@ -1,11 +0,0 @@
1
- Ryzenth/__init__.py,sha256=-_DvsIrYN1rtnUJzhhgRjdCspuD26jh_AbQBtDkmoyo,944
2
- Ryzenth/__version__.py,sha256=If0AyuBSroe8Pv0wRejh5VqDLnuaW4c2SDdS63OqUEM,118
3
- Ryzenth/_asynchisded.py,sha256=JxNw0lAmzhnWh2WjeKPHETu6N8MorJv3rdEfWai8zxg,3989
4
- Ryzenth/_synchisded.py,sha256=kLKL9b5dyMt_j5ew4Of5Y5hkFSDvmA43XjnmjT2Iab0,3797
5
- Ryzenth/ryzenth_client.py,sha256=fN_0BcK0ao6-CTpe5bRCT9jQD7Krr_Q8-Xlf-aFqdZY,1225
6
- Ryzenth/types/__init__.py,sha256=Uq5xqwfI5f-QwEnDRycQFJ5_yJbwzZwsM4cqgo_Wpbw,985
7
- ryzenth-1.8.3.dist-info/licenses/LICENSE,sha256=C73aiGSgoCAVNzvAHs-TROaf5vV8yCj9nqpGrmfNHHo,1068
8
- ryzenth-1.8.3.dist-info/METADATA,sha256=eYxGY-jCsrG4xQQ0g3QBFE-RoyOK1ppfcXz0DMofWME,3262
9
- ryzenth-1.8.3.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
10
- ryzenth-1.8.3.dist-info/top_level.txt,sha256=0vIhjOjoQuCxLeZO0of8VCx2jsri-bLHV28nh8wWDnc,8
11
- ryzenth-1.8.3.dist-info/RECORD,,