Reference

This section describes the public objects and endpoint functions exposed by the current codebase.

Transaction endpoint summary

Operation HTTP request Module Sync API Async API If-Match
Retrieve item GET /collections/{collection_id}/items/{feature_id} get_feature sync_detailed asyncio_detailed n/a
Create item POST /collections/{collection_id}/items post_feature sync, sync_detailed asyncio, asyncio_detailed n/a
Replace item PUT /collections/{collection_id}/items/{feature_id} update_feature sync, sync_detailed asyncio, asyncio_detailed required
Patch item PATCH /collections/{collection_id}/items/{feature_id} patch_feature sync, sync_detailed asyncio, asyncio_detailed optional
Delete item DELETE /collections/{collection_id}/items/{feature_id} delete_feature sync, sync_detailed asyncio, asyncio_detailed required

Client classes

stac_transaction_api_client.Client stores the base URL and HTTP configuration. stac_transaction_api_client.AuthenticatedClient adds an authorization token, using Bearer as the default prefix and Authorization as the default header name.

Both classes support:

  • headers and cookies applied to requests;
  • timeout;
  • TLS verification through verify_ssl;
  • redirect handling through follow_redirects;
  • extra httpx.Client and httpx.AsyncClient constructor arguments through httpx_args;
  • sync and async context-manager use;
  • injection of an existing httpx.Client or httpx.AsyncClient.

Detailed responses

Detailed endpoint functions return stac_transaction_api_client.types.Response[T]. It contains:

Field Type Meaning
status_code http.HTTPStatus HTTP response status
content bytes Raw response body
headers mutable mapping HTTP response headers
parsed T | None Parsed endpoint-specific result

Successful item bodies are converted to pystac.Item. Error bodies handled by mutation endpoints use stac_transaction_api_client.models.Exception, which has a required code, an optional description, and allows additional fields.

Current PySTAC body types

  • post_feature: pystac.Item | pystac.ItemCollection | Unset.
  • update_feature: pystac.Item | Unset.
  • patch_feature: Mapping[str, Any] | pystac.Item | Unset.

These types represent the upstream contract's single-item, bulk-item, and partial-item payloads while retaining PySTAC convenience for complete items.

For generated signatures and docstrings, see API objects.