Skip to content

Commit 0fc3a58

Browse files
Update core to version 9ee25b14
1 parent 6885d22 commit 0fc3a58

File tree

7 files changed

+22
-2
lines changed

7 files changed

+22
-2
lines changed

example/example.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ async def main():
5353
print(error)
5454
# [developer-docs.sdk.python.validate-secret-reference]-end
5555

56-
vault_id= os.getenv("OP_VAULT_ID")
56+
vault_id = os.getenv("OP_VAULT_ID")
5757
if vault_id is None:
5858
raise Exception("OP_VAULT_ID environment variable is not set")
5959

@@ -104,7 +104,9 @@ async def main():
104104

105105
# [developer-docs.sdk.python.resolve-secret]-start
106106
# Retrieves a secret from 1Password. Takes a secret reference as input and returns the secret to which it points.
107-
value = await client.secrets.resolve(f"op://{created_item.vault_id}/{created_item.id}/username")
107+
value = await client.secrets.resolve(
108+
f"op://{created_item.vault_id}/{created_item.id}/username"
109+
)
108110
print(value)
109111
# [developer-docs.sdk.python.resolve-secret]-end
110112

6.89 KB
Binary file not shown.
1.04 KB
Binary file not shown.
-8.69 KB
Binary file not shown.
10.3 KB
Binary file not shown.
9 KB
Binary file not shown.

src/onepassword/types.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -976,6 +976,8 @@ class VaultOverview(BaseModel):
976976
Represents a decrypted 1Password vault.
977977
"""
978978

979+
model_config = ConfigDict(populate_by_name=True)
980+
979981
id: str
980982
"""
981983
The vault's ID
@@ -984,6 +986,22 @@ class VaultOverview(BaseModel):
984986
"""
985987
The vault's title
986988
"""
989+
created_at: Annotated[
990+
datetime,
991+
BeforeValidator(parse_rfc3339),
992+
PlainSerializer(serialize_datetime_data),
993+
] = Field(alias="createdAt")
994+
"""
995+
The time the vault was created at
996+
"""
997+
updated_at: Annotated[
998+
datetime,
999+
BeforeValidator(parse_rfc3339),
1000+
PlainSerializer(serialize_datetime_data),
1001+
] = Field(alias="updatedAt")
1002+
"""
1003+
The time the vault was updated at
1004+
"""
9871005

9881006

9891007
class ItemListFilterByStateInner(BaseModel):

0 commit comments

Comments
 (0)