Source code for pinn.api.health

"""
:copyright: (c) 2019 Pinn Technologies, Inc.
:license: MIT
"""

from ..requester import Requester
from ..errors import PinnError


[docs]def healthy(): """Perform a health check against the configured Pinn host. Returns: bool: True if host is available, False otherwise """ endpoint = '/health' try: Requester.get(endpoint) return True except PinnError: return False