CtrlK
CommunityDocumentationLog inGet started
Tessl Logo

tessl/pypi-ldap3

tessl install tessl/pypi-ldap3@1.4.0

A strictly RFC 4510 conforming LDAP V3 pure Python client library

Agent Success

Agent success rate when using this tile

81%

Improvement

Agent success rate improvement when using this tile compared to baseline

1.08x

Baseline

Agent success rate without this tile

75%

task.mdevals/scenario-1/

LDAP Server Profile Loader

Builds an offline-friendly profile of an LDAP server by configuring a server descriptor, preloading schema and directory info, and returning a normalized summary. Metadata can come from a dependency-provided offline directory profile or from a local JSON definition file.

Capabilities

Builds server descriptor

  • Host, port, and security mode are preserved in the returned profile header. @test

Loads offline profile metadata

  • Supplying a known offline profile key (one of the dependency's bundled offline directory templates) returns vendor name, naming contexts, and at least one object class from the dependency-provided schema without performing network calls. @test

Loads definition file metadata

  • Providing a JSON server definition with schema and server info yields matching naming contexts and object class names in the profile summary. @test

Rejects missing metadata source

  • Requesting a profile without an offline profile key or a definition file path raises a descriptive error. @test

Implementation

@generates

API

from typing import TypedDict, List, Optional, Union
from pathlib import Path

class ServerProfile(TypedDict):
    host: str
    port: int
    secure: bool
    vendor: str
    naming_contexts: List[str]
    object_classes: List[str]


def load_server_profile(
    host: str,
    port: int,
    secure: bool = False,
    offline_profile: Optional[str] = None,
    definition_path: Optional[Union[str, Path]] = None,
) -> ServerProfile:
    ...

Dependencies { .dependencies }

ldap3 { .dependency }

Lightweight LDAP client used to configure server descriptors and preload schema/DSA information.

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
pypipkg:pypi/ldap3@1.4.x
tile.json