Skip to content

Commit cdfb080

Browse files
committed
Introduce HTTPClient to encapsulate the different mgmt keys needs
1 parent bef0cb4 commit cdfb080

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+1380
-972
lines changed

descope/_auth_base.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,10 @@
22
from descope.auth import Auth
33

44

5+
# XXX in the future we can remove this class entirely and have auth methods be base HTTPBase instead
56
class AuthBase:
67
"""Base class for classes having auth"""
78

89
def __init__(self, auth: Auth):
910
self._auth = auth
11+
self._http = auth.http_client

descope/_http_base.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
from __future__ import annotations
2+
3+
from descope.http_client import HTTPClient
4+
5+
6+
class HTTPBase:
7+
"""Base class for classes that only need HTTP access."""
8+
9+
def __init__(self, http_client: HTTPClient):
10+
self._http = http_client

0 commit comments

Comments
 (0)