Skip to content

Commit 2e2d4e0

Browse files
feat: rename SecretUpdateOptions to UpdateSecretOptions
1 parent 0734648 commit 2e2d4e0

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ pip install phase-dev
1111
## Import
1212

1313
```python
14-
from phase import Phase, CreateSecretsOptions, GetAllSecretsOptions, GetSecretOptions, SecretUpdateOptions, DeleteSecretOptions
14+
from phase import Phase, CreateSecretsOptions, GetAllSecretsOptions, GetSecretOptions, UpdateSecretOptions, DeleteSecretOptions
1515
```
1616

1717
## Initialize
@@ -82,7 +82,7 @@ if secret:
8282
Update an existing secret in a specified application and environment:
8383

8484
```python
85-
update_options = SecretUpdateOptions(
85+
update_options = UpdateSecretOptions(
8686
env_name="Development",
8787
app_name="Your App Name",
8888
key="API_KEY",
@@ -140,4 +140,4 @@ except ValueError as e:
140140

141141
## Note on Security
142142

143-
Never hard-code sensitive information like tokens or secrets directly in your code. Always use environment variables or secure configuration management to provide these values to your application.
143+
Never hard-code sensitive information like tokens or secrets directly in your code. Always use environment variables or secure configuration management to provide these values to your application.

src/phase/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
GetSecretOptions,
44
GetAllSecretsOptions,
55
CreateSecretsOptions,
6-
SecretUpdateOptions,
6+
UpdateSecretOptions,
77
DeleteSecretOptions,
88
PhaseSecret
99
)
@@ -13,7 +13,7 @@
1313
'GetSecretOptions',
1414
'GetAllSecretsOptions',
1515
'CreateSecretsOptions',
16-
'SecretUpdateOptions',
16+
'UpdateSecretOptions',
1717
'DeleteSecretOptions',
1818
'PhaseSecret'
1919
]

src/phase/phase.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class CreateSecretsOptions:
2626
secret_path: str = "/"
2727

2828
@dataclass
29-
class SecretUpdateOptions:
29+
class UpdateSecretOptions:
3030
env_name: str
3131
app_name: str
3232
key: str
@@ -107,7 +107,7 @@ def create_secrets(self, options: CreateSecretsOptions) -> str:
107107
)
108108
return "Success" if response.status_code == 200 else f"Error: {response.status_code}"
109109

110-
def update_secret(self, options: SecretUpdateOptions) -> str:
110+
def update_secret(self, options: UpdateSecretOptions) -> str:
111111
return self._phase_io.update(
112112
env_name=options.env_name,
113113
key=options.key,

0 commit comments

Comments
 (0)