Files
py-healthchecks.io/src/healthchecks_io/schemas/integrations.py
2021-12-06 17:23:51 -06:00

18 lines
333 B
Python

"""
Schemas for integrations
https://healthchecks.io/docs/api/
"""
from typing import Dict
from pydantic import BaseModel
class Integration(BaseModel):
id: str
name: str
kind: str
@classmethod
def from_api_result(cls, integration_dict: Dict[str, str]) -> "Integration":
return cls(**integration_dict)