Skip to content

Commit

Permalink
feat: clean up create key model
Browse files Browse the repository at this point in the history
  • Loading branch information
johnson2427 committed May 2, 2024
1 parent a0b7526 commit 6b8b012
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions ape_aws/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ class KeyBaseModel(BaseModel):

class CreateKeyModel(KeyBaseModel):
description: str = Field(alias='Description')
policy: str | None = Field(default=None, required=False, alias='Policy')
policy: str | None = Field(default=None, alias='Policy')
key_usage: str = Field(default='SIGN_VERIFY', alias='KeyUsage')
key_spec: str = Field(default='ECC_SECG_P256K1', alias='KeySpec')
admins: list[str] | None
users: list[str] | None
admins: list[str] = []
users: list[str] = []
tags: list[dict[str, str]] | None = Field(default=None, alias='Tags')
multi_region: bool | None = Field(default=None, required=False, alias="MultiRegion")
multi_region: bool | None = Field(default=None, alias="MultiRegion")
origin: str = Field(alias='Origin')
ADMIN_KEY_POLICY: str = """{
"Version": "2012-10-17",
Expand Down Expand Up @@ -59,11 +59,11 @@ def to_aws_dict(self):


class CreateKey(CreateKeyModel):
origin: str = Field('AWS_KMS', alias='Origin')
origin: str = Field(default='AWS_KMS', alias='Origin')


class ImportKey(CreateKeyModel):
origin: str = Field('EXTERNAL', alias='Origin')
origin: str = Field(default='EXTERNAL', alias='Origin')


class DeleteKey(KeyBaseModel):
Expand Down

0 comments on commit 6b8b012

Please sign in to comment.