import { EXTERNAL_PROVIDER_CONTRACT_VERSION } from "../src/index.mjs";

export const geliosPositionsCurrentExample = Object.freeze({
  providerManifest: {
    schemaVersion: EXTERNAL_PROVIDER_CONTRACT_VERSION,
    id: "gelios.positions.current",
    providerId: "gelios",
    version: "1.0.0",
    ontology: {
      packageId: "gelios",
      revision: "ontology.gelios.v1",
    },
    l2Template: {
      id: "gelios.positions.current.l2.v1",
      version: "1.0.0",
    },
    capabilities: [
      { id: "gelios.units.current.read", classification: "read" },
    ],
    dataProductIds: ["fleet.positions.current.v1"],
  },
  connection: {
    schemaVersion: EXTERNAL_PROVIDER_CONTRACT_VERSION,
    id: "gelios.sample-fleet",
    providerId: "gelios",
    tenantId: "sample-tenant",
    credentialRef: { owner: "ndc_l2_credentials", reference: "ndc-credref:provider-example-0001" },
    scope: {
      capabilityIds: ["gelios.units.current.read"],
      fieldPolicyId: "gelios.positions.current.fields.v1",
    },
  },
  collectionProfile: {
    schemaVersion: EXTERNAL_PROVIDER_CONTRACT_VERSION,
    id: "gelios.positions.realtime",
    connectionId: "gelios.sample-fleet",
    mode: "realtime",
    schedule: { intervalMs: 10000 },
    capabilityIds: ["gelios.units.current.read"],
    dataProductId: "fleet.positions.current.v1",
  },
  dataProduct: {
    schemaVersion: EXTERNAL_PROVIDER_CONTRACT_VERSION,
    id: "fleet.positions.current.v1",
    version: "1.0.0",
    delivery: { mode: "snapshot+patch" },
    semanticTypes: ["map.moving_object"],
    fields: [
      "course_degrees",
      "display_name",
      "elevation_meters",
      "geometry",
      "hdop",
      "horizontal_accuracy_meters",
      "object_kind",
      "operational_status",
      "position_source",
      "position_valid",
      "quality_flags",
      "satellite_count",
      "speed_kph",
    ],
    access: { audience: "internal" },
  },
  foundryBinding: {
    schemaVersion: EXTERNAL_PROVIDER_CONTRACT_VERSION,
    id: "fleet.operations-map.moving-objects",
    dataProductId: "fleet.positions.current.v1",
    applicationId: "11111111-1111-4111-8111-111111111111",
    pageId: "map",
    templateId: "map",
    slotId: "points",
    semanticType: "map.moving_object",
  },
});
