Skip to main content

gRPC client for Aserto Directory service instances

Project description

Aserto Directory gRPC client

This is an automatically generated client for interacting with Aserto's Directory service using the gRPC protocol.

Installation

Using Pip

pip install aserto-directory

Using Poetry

poetry add aserto-directory

Usage

import grpc
from aserto.directory.reader.v2 import ReaderStub, GetObjectTypesRequest

with grpc.secure_channel(
    target="directory.prod.aserto.com:8443",
    credentials=grpc.ssl_channel_credentials(),
) as channel:
    reader = ReaderStub(channel)

    # List all object types in the directory
    response = reader.GetObjectTypes(
        GetObjectTypesRequest(),
        metadata=(
            ("authorization", f"basic {ASERTO_DIRECTORY_API_KEY}"),
            ("aserto-tenant-id", ASERTO_TENANT_ID),
        ),
    )

    for object_type in response.results:
        print("Object Type:", object_type.name)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aserto-directory-0.30.0rc1.tar.gz (69.6 kB view details)

Uploaded Source

Built Distribution

aserto_directory-0.30.0rc1-py3-none-any.whl (121.0 kB view details)

Uploaded Python 3

File details

Details for the file aserto-directory-0.30.0rc1.tar.gz.

File metadata

  • Download URL: aserto-directory-0.30.0rc1.tar.gz
  • Upload date:
  • Size: 69.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.12 CPython/3.7.12 Darwin/23.0.0

File hashes

Hashes for aserto-directory-0.30.0rc1.tar.gz
Algorithm Hash digest
SHA256 8ed32b84d23dedad035dde54276eda1fc1e32cee5f58fd0c28d0ba588ea36682
MD5 8ca081eaea6c4eb44683284275ae6310
BLAKE2b-256 a2e9df10b69794fa1e6de4e94cace8d551ca631b82b28bbadf6b66323d6e1215

See more details on using hashes here.

File details

Details for the file aserto_directory-0.30.0rc1-py3-none-any.whl.

File metadata

File hashes

Hashes for aserto_directory-0.30.0rc1-py3-none-any.whl
Algorithm Hash digest
SHA256 86d6ca31fc7f37fb8675148d21994d85cac9e8144588ec974a200b45158af39e
MD5 06bf80f7855a79982f9e8e7a547d1e14
BLAKE2b-256 79605e85bd999aada9f51f336614a04519dc3a47cb47aa57555ede30520f944f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page