kittycad.client
index
/home/runner/work/kittycad.py/kittycad.py/kittycad/client.py

 
Modules
       
attr
ssl

 
Classes
       
builtins.object
Client
AuthenticatedClient

 
class AuthenticatedClient(Client)
    AuthenticatedClient(base_url: str = 'https://api.kittycad.io', *, cookies: Dict[str, str] = NOTHING, headers: Dict[str, str] = NOTHING, timeout: float = 5.0, verify_ssl: Union[str, bool, ssl.SSLContext] = True, token: str) -> None
 
Client which has been authenticated for use on secured endpoints
 
 
Method resolution order:
AuthenticatedClient
Client
builtins.object

Methods defined here:
__eq__(self, other)
Method generated by attrs for class AuthenticatedClient.
__ge__(self, other)
Method generated by attrs for class AuthenticatedClient.
__gt__(self, other)
Method generated by attrs for class AuthenticatedClient.
__init__(self, base_url: str = 'https://api.kittycad.io', *, cookies: Dict[str, str] = NOTHING, headers: Dict[str, str] = NOTHING, timeout: float = 5.0, verify_ssl: Union[str, bool, ssl.SSLContext] = True, token: str) -> None
Method generated by attrs for class AuthenticatedClient.
__le__(self, other)
Method generated by attrs for class AuthenticatedClient.
__lt__(self, other)
Method generated by attrs for class AuthenticatedClient.
__ne__(self, other)
Method generated by attrs for class AuthenticatedClient.
__repr__(self)
Method generated by attrs for class AuthenticatedClient.
get_headers(self) -> Dict[str, str]
Get headers to be used in authenticated endpoints

Data and other attributes defined here:
__annotations__ = {'token': <class 'str'>}
__attrs_attrs__ = (Attribute(name='base_url', default='https://api... kw_only=True, inherited=False, on_setattr=None))
__hash__ = None

Methods inherited from Client:
get_cookies(self) -> Dict[str, str]
get_timeout(self) -> float
with_cookies(self, cookies: Dict[str, str]) -> 'Client'
Get a new client matching this one with additional cookies
with_headers(self, headers: Dict[str, str]) -> 'Client'
Get a new client matching this one with additional headers
with_timeout(self, timeout: float) -> 'Client'
Get a new client matching this one with a new timeout (in seconds)

Data descriptors inherited from Client:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

 
class Client(builtins.object)
    Client(base_url: str = 'https://api.kittycad.io', *, cookies: Dict[str, str] = NOTHING, headers: Dict[str, str] = NOTHING, timeout: float = 5.0, verify_ssl: Union[str, bool, ssl.SSLContext] = True) -&gt; None
 
A class for keeping track of data related to the API
 
  Methods defined here:
__eq__(self, other)
Method generated by attrs for class Client.
__ge__(self, other)
Method generated by attrs for class Client.
__gt__(self, other)
Method generated by attrs for class Client.
__init__(self, base_url: str = 'https://api.kittycad.io', *, cookies: Dict[str, str] = NOTHING, headers: Dict[str, str] = NOTHING, timeout: float = 5.0, verify_ssl: Union[str, bool, ssl.SSLContext] = True) -> None
Method generated by attrs for class Client.
__le__(self, other)
Method generated by attrs for class Client.
__lt__(self, other)
Method generated by attrs for class Client.
__ne__(self, other)
Method generated by attrs for class Client.
__repr__(self)
Method generated by attrs for class Client.
get_cookies(self) -> Dict[str, str]
get_headers(self) -> Dict[str, str]
Get headers to be used in all endpoints
get_timeout(self) -> float
with_cookies(self, cookies: Dict[str, str]) -> 'Client'
Get a new client matching this one with additional cookies
with_headers(self, headers: Dict[str, str]) -> 'Client'
Get a new client matching this one with additional headers
with_timeout(self, timeout: float) -> 'Client'
Get a new client matching this one with a new timeout (in seconds)

Data descriptors defined here:
__dict__
dictionary for instance variables (if defined)
__weakref__
list of weak references to the object (if defined)

Data and other attributes defined here:
__annotations__ = {'base_url': <class 'str'>, 'cookies': typing.Dict[str, str], 'headers': typing.Dict[str, str], 'timeout': <class 'float'>, 'verify_ssl': typing.Union[str, bool, ssl.SSLContext]}
__attrs_attrs__ = (Attribute(name='base_url', default='https://api... kw_only=True, inherited=False, on_setattr=None))
__hash__ = None

 
Data
        Dict = typing.Dict
Union = typing.Union