Skip to content

Latest commit

 

History

History
93 lines (58 loc) · 5.76 KB

File metadata and controls

93 lines (58 loc) · 5.76 KB

Users

(users)

Overview

Available Operations

get_encryption_certificate

Retrieve a short lived certificate with the public key for encrypting secrets.

Example Usage

from unstructured_client import UnstructuredClient


with UnstructuredClient() as uc_client:

    res = uc_client.users.get_encryption_certificate(request={})

    assert res.encryption_certificate_response is not None

    # Handle response
    print(res.encryption_certificate_response)

Parameters

Parameter Type Required Description
request operations.GetEncryptionCertificateRequest ✔️ The request object to use for the request.
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.
server_url Optional[str] An optional server URL to use.

Response

operations.GetEncryptionCertificateResponse

Errors

Error Type Status Code Content Type
errors.HTTPValidationError 422 application/json
errors.SDKError 4XX, 5XX */*

store_secret

After encrypting a secret locally, store it and get back a reference id.

Example Usage

from unstructured_client import UnstructuredClient


with UnstructuredClient() as uc_client:

    res = uc_client.users.store_secret(request={
        "encrypted_secret": {
            "encrypted_value": "<value>",
        },
    })

    assert res.secret_reference is not None

    # Handle response
    print(res.secret_reference)

Parameters

Parameter Type Required Description
request operations.StoreSecretRequest ✔️ The request object to use for the request.
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.
server_url Optional[str] An optional server URL to use.

Response

operations.StoreSecretResponse

Errors

Error Type Status Code Content Type
errors.HTTPValidationError 422 application/json
errors.SDKError 4XX, 5XX */*