Metadata And Catalog Reads
Native application path: gRPC for live data and edits; PMTiles, GeoParquet and COG through the CDN. Start there for browser gRPC-Web setup, signed private URLs and regeneration after changes. OGC API and GeoServices REST examples below are compatibility workflows.
This repo exposes stable, non-UI metadata/catalog reads through protocol-specific
clients. The server-owned parity matrix is tracked in
honua-io/honua-server#955; this SDK maps the stable read surfaces without
inventing a separate catalog model for every protocol.
Which Client To Use
| Need | SDK surface | Notes |
|---|---|---|
| Public standards catalog discovery | IHonuaOgcRecordsClient in Honua.Sdk.Catalogs (Honua.Sdk.Catalogs.Records) |
Use for landing, conformance, record collections, record search, record detail, paging, bbox/time/free-text filters, and raw JSON access. |
| Operator/control-plane discovery | IHonuaCatalogClient in Honua.Sdk.Admin.Catalog |
Uses admin service summaries and FeatureServer metadata for default service/layer discovery. Explicit groups, saved source descriptors and metadata filters require a server exposing the legacy metadata-resource API. Requires admin/control-plane auth. |
| STAC asset cataloging | IHonuaStacClient in Honua.Sdk.Catalogs (Honua.Sdk.Catalogs.Stac) |
Use for STAC catalog discovery, collections, item pages, item detail, GET/POST search, asset links, bbox/time filters, fields projection, paging, and raw JSON access. |
| Migration source assessment | Admin migration models and client extensions in Honua.Sdk.Admin |
Use for external GeoServices REST/GeoServer inventory artifacts, compatibility assessments, manifests, and readiness evidence. |
| Exact protocol capabilities | Native protocol clients | Use Honua.Sdk.GeoServices for FeatureServer metadata, Honua.Sdk.OgcFeatures for collections/queryables/items and the Honua.Sdk.OgcFeatures.Wfs types for capabilities and DescribeFeatureType, and Honua.Sdk.Scenes for scene metadata. |
OGC API Records Client
Honua.Sdk.Catalogs (under the Honua.Sdk.Catalogs.Records namespaces) is the
public OGC API Records catalog client. It intentionally mirrors
the existing REST client conventions in this repo:
AddHonuaOgcRecords(...)registersIHonuaOgcRecordsClient.- Auth options match the other REST clients: static credentials, per-request providers, request-aware access token providers, diagnostics, primary handler factories, retries, and timeout validation.
- HTTP failures raise
HonuaOgcRecordsException, preserving status, response body, and RFC 7807 problem details when present. GetRecordsPagesAsync(...)follows same-originnextlinks and rejects cross-origin next-page redirects.GetRecordsJsonAsync(...)andGetRecordJsonAsync(...)preserve raw JSON access for profile fields that are not yet promoted to typed properties.
using Honua.Sdk.Catalogs.Records;
using Honua.Sdk.Catalogs.Records.Models;
var collections = await recordsClient.ListCollectionsAsync(ct);
var page = await recordsClient.SearchAsync(
"default",
new OgcRecordsQuery
{
Query = "parks",
Types = ["service", "layer"],
Bbox = [-158.4, 21.2, -157.6, 21.9],
Datetime = "2026-05-01T00:00:00Z/..",
Limit = 25
},
ct);
await foreach (var recordsPage in recordsClient.GetRecordsPagesAsync("default", ct: ct))
{
foreach (var record in recordsPage.Records ?? [])
{
Console.WriteLine(record.Properties?["title"].GetString());
}
}
STAC Client
Honua.Sdk.Catalogs (under the Honua.Sdk.Catalogs.Stac namespaces) is the
protocol-native STAC asset catalog client added as the
child of honua-sdk-dotnet#146 in honua-sdk-dotnet#147. It stays separate
from Records because STAC has catalog/collection/item/search semantics, asset
links, item assets, fields projection, and search-body behavior that are not
the same as OGC API Records records.
AddHonuaStac(...)registersIHonuaStacClient.- Auth, retry, timeout, diagnostics, and primary handler options match the other REST clients.
SearchAsync(StacSearchQuery)uses GET/stac/search;SearchAsync(StacSearchRequest)POSTs JSON to/stac/search.GetItemsPagesAsync(...)andSearchPagesAsync(...)follow same-originnextlinks and reject cross-origin redirects.GetItemsJsonAsync(...),GetItemJsonAsync(...), andSearchJsonAsync(...)preserve raw JSON access for STAC extensions and profile-specific fields.
using Honua.Sdk.Catalogs.Stac;
using Honua.Sdk.Catalogs.Stac.Models;
var collections = await stacClient.ListCollectionsAsync(ct);
var search = await stacClient.SearchAsync(
new StacSearchQuery
{
Collections = ["imagery"],
Bbox = [-158.4, 21.2, -157.6, 21.9],
Datetime = "2026-05-01T00:00:00Z/..",
Filter = "cloud_cover < 10",
FilterLang = "cql2-text",
Fields = new StacFields
{
Include = ["id", "properties.datetime"],
Exclude = ["assets.thumbnail"]
},
Limit = 25
},
ct);
await foreach (var page in stacClient.SearchPagesAsync(new StacSearchRequest
{
Collections = ["imagery"],
Limit = 100
}, ct))
{
foreach (var item in page.Features ?? [])
{
Console.WriteLine($"{item.Id}: {item.Assets?.Count ?? 0} assets");
}
}
Parity Notes
- Records is standards-facing catalog discovery; it should link to concrete protocol resources instead of replacing FeatureServer, OGC Features, WFS, or scene metadata clients.
- Admin catalog remains the operator view. It can expose private metadata and control-plane resources that a public Records catalog should not expose.
- STAC parity is explicitly not hidden inside the Records client. The linked
child issue is
honua-sdk-dotnet#147; this SDK surface follows the stable routes and cross-SDK semantics fromhonua-io/honua-server#955. - Keep future endpoint additions aligned with
honua-io/honua-server#955so JS, Python, and .NET SDKs can share names, paging behavior, error behavior, auth forwarding, and fixtures.
Default SearchAsync, ListServicesAsync, GetServiceAsync, ListLayersAsync and
GetLayerAsync do not call /api/v1/admin/metadata/resources. Free-text queries
search the available canonical names and descriptions. Group/source-descriptor
kinds, tags, owner, namespace and creation/update sorting explicitly opt into
legacy metadata reads. On current servers without that API these operations
raise HonuaAdminApiException with the server status; they do not return an empty
catalog or rely on the metadataResources capability flag.