Skip to main content

across-client

Unit test and smoke test

The across-client is the NASA-ACROSS library used to access and manipulate the across-server data. What separates this package from the autogenerated sdk is that it also levarages the across-tools package to give users a single interface for all of their cross-observatory science needs.

Access

To access our observatory data (telescopes, instruments, schedues, etc) on the across-server, users DO NOT require any authentication. But if an observatory user-group wants to use the API to publish their planned/completed observing schedules they are required to register, and obtain client credentials through the website.

Installation

This repository can be installed on python (version >=3.10) environments.

#activate your python environment (conda, mamba, venv... etc)
git clone https://github.com/NASA-ACROSS/across-client.git
cd across-client
python -m pip install .

or the latest released version with pip

python -m pip install across-client

Usage

Below is a small example on how to utilize the client to access JWST Nircam performed observations. For more examples on how to access observatory science data or use our observatory tools endpoints, please go to our examples folder.

from datetime import datetime
from across.client import Client

# client credentials are only required for publishing schedules
ACROSS_SERVER_ID: str = "..."
ACROSS_SERVER_SECRET: str = "..."

client = Client(client_id=ACROSS_SERVER_ID, client_secret=ACROSS_SERVER_SECRET)

nircam = client.instrument.get_many(name="nircam")[0]

nircam_observations = client.observation.get_many(
   instrument_ids=[nircam.id],
   status="performed",
   date_range_begin=datetime(...),
   date_range_end=datetime(...),
)

Running the Client in Development

If you are running a development instance of the ACROSS software system, it is straightforward to point your client installation to your local ACROSS core-server instance.

  1. Follow the server installation instructions here.
  2. Copy or duplicate the .env.example file in the root directory of this repository and rename it to .env. Important: This overrides the client's host from the default production server to your local instance by setting the ACROSS_SERVER_HOST and ACROSS_SERVER_PORT variables to the local server's host and port, which by default is host: http://localhost and port: 8000.
  3. Instantiate a new Client object, see the example below, and it should now be set up to interface with your local development server!

Using this local setup, you can test submitting schedules to ACROSS. The local server provides a seeded service account with schedule write permissions. Simply instantiate the client using these credentials and you can post a schedule to your local server:

from across.client import Client


ACROSS_SERVER_ID = "961fbb3b-dd5e-45ff-a282-41033e43933d"
ACROSS_SERVER_SECRET = "prehibernationweek"

client = Client(
   client_id=ACROSS_SERVER_ID,
   client_secret=ACROSS_SERVER_SECRET,
)
created_schedule_id = client.schedule.post(...)

schedule = client.schedule.get(created_schedule_id)

print(schedule)

For ease of use, these ACROSS_SERVER_ID and ACROSS_SERVER_SECRET variables are part of the .env.example file.

Contributing

Found a bug? Want to make a feature request? Or create a pull request? Navigate to our Contributing document for more instructions!

Open Science at NASA

Notice

NASA Docket No. GSC-19,469-1, and identified as "Astrophysics Cross-Observatory Science Support (ACROSS) System

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.“

Copyright © 2025 United States Government as represented by the Administrator of the National Aeronautics and Space Administration and The Penn State Research Foundation. All rights reserved. This software is licensed under the Apache 2.0 License.

Metadata

Release files for across-client 1.4.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 across-client 1.4.0
File Size Uploaded Provenance Actions
across_client-1.4.0.tar.gz 320.7 kB With provenance Details for across_client-1.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for across-client 1.4.0
File Interpreter ABI Platform Actions
across_client-1.4.0-py3-none-any.whl Python 3 none any Details for across_client-1.4.0-py3-none-any.whl

Total release size: 345.7 kB

Release files / across_client-1.4.0.tar.gz

Download URL across_client-1.4.0.tar.gz
Size 320.7 kB
Tags Source
SHA-256 checksum
How to use checksums
27b0a8c0ce99f2f81b00df2855957a02e7990e87af57c62a7cea948fa847231f
BLAKE2b-256 checksum
How to use checksums
edc0e6a0e38cc852d43b221f18989d58c77301beb2379c2c03adebf454d2a3a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 23, 2026.

Transparency log

Release files / across_client-1.4.0-py3-none-any.whl

Download URL across_client-1.4.0-py3-none-any.whl
Size 25.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
656417fd12846045dfe41ecb748392fb5a10c009a15ca19dced25bde4133c3bf
BLAKE2b-256 checksum
How to use checksums
d5b49a67700b9a187b355a2635f6b55d0c6344d51aaf8099c5e8a10239254984
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 23, 2026.

Transparency log

Security for across-client 1.4.0

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for across_client-1.4.0.tar.gz

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 Nov 23, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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