first commit
This commit is contained in:
28
backend/app/schemas/router.py
Normal file
28
backend/app/schemas/router.py
Normal file
@@ -0,0 +1,28 @@
|
||||
from pydantic import BaseModel
|
||||
|
||||
class RouterCreate(BaseModel):
|
||||
name: str
|
||||
host: str
|
||||
port_rest: int = 443
|
||||
port_ssh: int = 22
|
||||
port_api: int = 8728
|
||||
verify_ssl: bool = False
|
||||
preferred_method: str = "auto"
|
||||
tags: str = ""
|
||||
|
||||
class RouterOut(BaseModel):
|
||||
id: int
|
||||
name: str
|
||||
host: str
|
||||
port_rest: int
|
||||
port_ssh: int
|
||||
port_api: int
|
||||
verify_ssl: bool
|
||||
preferred_method: str
|
||||
tags: str
|
||||
|
||||
class CredentialCreate(BaseModel):
|
||||
method: str # rest|ssh|api
|
||||
username: str
|
||||
secret: str
|
||||
extra_json: dict = {}
|
||||
Reference in New Issue
Block a user