Skip to main content

fragalysis-target-access-authenticator-python-client

PyPI - Version

release

A simple Python 3 client to simplify access to the authenticator, providing the following functions: -

def get_auth_target_access(username: str) -> set[str]:
    [...]
def get_auth_users(target_access_string: str) -> TasAuthUsersGetResponse:
    [...]
def get_auth_version() -> TasAuthVersionGetResponse:
    [...]
def get_auth_ping() -> TasAuthPingGetResponse:
    [...]

get_auth_users() (which needs authenticator 1.5.0 or later) returns a response rather than a bare set because, unlike get_auth_target_access(), it has to distinguish "the TAS has no members" from "we could not find out": -

response = ta_auth_connector.get_auth_users("lb32627-66")
if response.error:
    # We do not know who the members are - 'users' is empty but meaningless
    ...
else:
    # 'users' is the membership, and may legitimately be empty
    ...

The module requires two items, extracted from the environment: -

  • TA_AUTH_SERVICE - The service hostname. In cluster this might be http://auth.ta-authenticator.svc (an internal connection that is expected to comply with http:// protocol)
  • TA_AUTH_QUERY_KEY - A 'secret' key the service expects in request headers.

Usage

After installing from PyPI, access the ta_auth_connector functions directly via the connector module: -

import ta_auth_connector

ping_response: TasAuthPingGetResponse = ta_auth_connector.get_auth_ping()

Target access strings

A Target Access String (TAS) is the concatenation of a two-character code (lower case), proposal number, and visit number formatted as <code><proposal>-<visit>: -

  • lb12345-1
  • lb32627-66

Rules

Access to non-public Fragalysis Targets is limited to users who are members of the associated TAS. If a target belongs to lb32627-66 (and lb32627-66 is not a publicly visible target) you will not be permitted access to the material unless, according to ISPyB, you are a member of proposal 32627 and visit 66.

Also, although everyone can view publicly visible targets you are not permitted to alter or add material to the target unless you are a member of the corresponding proposal and visit. Everyone can see public targets, but only members of the TAS can edit.

The authenticator service

See: -


Metadata

Release files for xchem-ta-auth-client 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for xchem-ta-auth-client 1.1.0
File Size Uploaded
xchem_ta_auth_client-1.1.0.tar.gz 11.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for xchem-ta-auth-client 1.1.0
File Interpreter ABI Platform
xchem_ta_auth_client-1.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 19.9 kB

Release files / xchem_ta_auth_client-1.1.0.tar.gz

Download URL xchem_ta_auth_client-1.1.0.tar.gz
Size 11.1 kB
Tags Source
SHA-256 checksum
How to use checksums
fe805c05242eccc824bba88b6681ccfffbf6418c5d9f659f72499011e39031d0
BLAKE2b-256 checksum
How to use checksums
a0a83a787ba0c9702be80af88f87d7a0b6a0e778142aeebbda8691837218ce72
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 13, 2026.

Transparency log

Release files / xchem_ta_auth_client-1.1.0-py3-none-any.whl

Download URL xchem_ta_auth_client-1.1.0-py3-none-any.whl
Size 8.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f9164f2fc410d113ddfca9358ff722bd758e3e3021dca494ae2172e515f78d61
BLAKE2b-256 checksum
How to use checksums
5a5640026c538c2bc9db61a80307276815b2bc03e980b04cb2d16a69e343f215
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 13, 2026.

Transparency log

Release history Release notifications | RSS feed

1.2.0

2 release files

This release

1.1.0 This release

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page