@geolens/sdk 1.6.0 → 1.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -132,12 +132,24 @@ export type AddDatasetsResponse = {
132
132
  * AdminApiKeyCreateRequest
133
133
  */
134
134
  export type AdminApiKeyCreateRequest = {
135
+ /**
136
+ * Expires At
137
+ *
138
+ * Optional expiry timestamp (RFC 3339, timezone-aware). Omit or null for a non-expiring key; expired keys stop authenticating.
139
+ */
140
+ expires_at?: string | null;
135
141
  /**
136
142
  * Name
137
143
  *
138
144
  * Human-readable label for the API key (e.g. 'CI pipeline', 'QGIS desktop').
139
145
  */
140
146
  name: string;
147
+ /**
148
+ * Scope
149
+ *
150
+ * Privilege scope (#875). 'full' impersonates the owner completely, the pre-existing behavior. 'read_only' authenticates GET, HEAD and OPTIONS requests only; any other method is refused with 403. A service-account key minted for an application is the usual case for 'read_only'.
151
+ */
152
+ scope?: 'full' | 'read_only';
141
153
  /**
142
154
  * User Id
143
155
  *
@@ -155,6 +167,12 @@ export type AdminApiKeyListItem = {
155
167
  * Timestamp when the key was created.
156
168
  */
157
169
  created_at: string;
170
+ /**
171
+ * Expires At
172
+ *
173
+ * Expiry timestamp; null means the key does not expire.
174
+ */
175
+ expires_at?: string | null;
158
176
  /**
159
177
  * Fingerprint
160
178
  *
@@ -185,6 +203,12 @@ export type AdminApiKeyListItem = {
185
203
  * Human-readable label.
186
204
  */
187
205
  name: string;
206
+ /**
207
+ * Scope
208
+ *
209
+ * Privilege scope: 'full' or 'read_only' (#875).
210
+ */
211
+ scope: string;
188
212
  /**
189
213
  * User Id
190
214
  *
@@ -493,10 +517,22 @@ export type AnalysisMaterializeRequest = {
493
517
  * Buffer distance in meters (buffer only)
494
518
  */
495
519
  distance_meters?: number | null;
520
+ /**
521
+ * Join Dataset Id
522
+ *
523
+ * Dataset to join against; each source feature gains a count of the features from it that intersect (spatial_join only)
524
+ */
525
+ join_dataset_id?: string | null;
526
+ /**
527
+ * Join Fields
528
+ *
529
+ * Columns to copy from the intersecting join feature, prefixed 'join_' in the output. Ties break on the lowest join-layer gid (spatial_join only)
530
+ */
531
+ join_fields?: Array<string> | null;
496
532
  /**
497
533
  * Mask
498
534
  *
499
- * GeoJSON Polygon or MultiPolygon geometry in EPSG:4326 (clip only)
535
+ * GeoJSON Polygon or MultiPolygon geometry in EPSG:4326 (clip and select_by_location)
500
536
  */
501
537
  mask?: {
502
538
  [key: string]: unknown;
@@ -504,13 +540,13 @@ export type AnalysisMaterializeRequest = {
504
540
  /**
505
541
  * Mask Dataset Id
506
542
  *
507
- * Polygon dataset whose unioned features form the clip mask (clip only; alternative to mask)
543
+ * Polygon dataset supplying the second layer: the area clipped to, selected against, or overlaid with. For clip and select_by_location it is the alternative to `mask`; for intersect it is REQUIRED and `mask` is rejected, because an overlay carries the second layer's attributes onto its output and a drawn polygon has none.
508
544
  */
509
545
  mask_dataset_id?: string | null;
510
546
  /**
511
547
  * Operation
512
548
  */
513
- operation: 'buffer' | 'centroid' | 'clip' | 'dissolve';
549
+ operation: 'buffer' | 'centroid' | 'clip' | 'dissolve' | 'spatial_join' | 'measure' | 'select_by_location' | 'intersect';
514
550
  /**
515
551
  * Title
516
552
  */
@@ -546,10 +582,22 @@ export type AnalysisPreviewRequest = {
546
582
  * Buffer distance in meters (buffer only)
547
583
  */
548
584
  distance_meters?: number | null;
585
+ /**
586
+ * Join Dataset Id
587
+ *
588
+ * Dataset to join against; each source feature gains a count of the features from it that intersect (spatial_join only)
589
+ */
590
+ join_dataset_id?: string | null;
591
+ /**
592
+ * Join Fields
593
+ *
594
+ * Columns to copy from the intersecting join feature, prefixed 'join_' in the output. Ties break on the lowest join-layer gid (spatial_join only)
595
+ */
596
+ join_fields?: Array<string> | null;
549
597
  /**
550
598
  * Mask
551
599
  *
552
- * GeoJSON Polygon or MultiPolygon geometry in EPSG:4326 (clip only)
600
+ * GeoJSON Polygon or MultiPolygon geometry in EPSG:4326 (clip and select_by_location)
553
601
  */
554
602
  mask?: {
555
603
  [key: string]: unknown;
@@ -557,13 +605,13 @@ export type AnalysisPreviewRequest = {
557
605
  /**
558
606
  * Mask Dataset Id
559
607
  *
560
- * Polygon dataset whose unioned features form the clip mask (clip only; alternative to mask)
608
+ * Polygon dataset supplying the second layer: the area clipped to, selected against, or overlaid with. For clip and select_by_location it is the alternative to `mask`; for intersect it is REQUIRED and `mask` is rejected, because an overlay carries the second layer's attributes onto its output and a drawn polygon has none.
561
609
  */
562
610
  mask_dataset_id?: string | null;
563
611
  /**
564
612
  * Operation
565
613
  */
566
- operation: 'buffer' | 'centroid' | 'clip';
614
+ operation: 'buffer' | 'centroid' | 'clip' | 'spatial_join' | 'measure' | 'select_by_location' | 'intersect';
567
615
  };
568
616
  /**
569
617
  * AnalysisPreviewResponse
@@ -585,6 +633,12 @@ export type AnalysisPreviewResponse = {
585
633
  geojson: {
586
634
  [key: string]: unknown;
587
635
  };
636
+ /**
637
+ * Match Count
638
+ *
639
+ * Exact total across the WHOLE source, not just the previewed features. What it counts is per-operation, so read it against the operation you sent rather than as one number: select_by_location gives the selected source features and intersect gives the output pieces, and for both of those it IS the output total; spatial_join gives intersecting source/join PAIRS, which is NOT the output total, because the join keeps every source row (use source_feature_count for that operation). Null for operations that report no such total, and when the count could not be computed within the query budget
640
+ */
641
+ match_count?: number | null;
588
642
  /**
589
643
  * Source Feature Count
590
644
  *
@@ -600,12 +654,24 @@ export type AnalysisPreviewResponse = {
600
654
  * ApiKeyCreateRequest
601
655
  */
602
656
  export type ApiKeyCreateRequest = {
657
+ /**
658
+ * Expires At
659
+ *
660
+ * Optional expiry timestamp (RFC 3339, timezone-aware). Omit or null for a non-expiring key; expired keys stop authenticating.
661
+ */
662
+ expires_at?: string | null;
603
663
  /**
604
664
  * Name
605
665
  *
606
666
  * Human-readable label for the API key
607
667
  */
608
668
  name: string;
669
+ /**
670
+ * Scope
671
+ *
672
+ * Privilege scope (#875). 'full' impersonates the owner completely, the pre-existing behavior. 'read_only' authenticates GET, HEAD and OPTIONS requests only; any other method is refused with 403.
673
+ */
674
+ scope?: 'full' | 'read_only';
609
675
  };
610
676
  /**
611
677
  * ApiKeyCreateResponse
@@ -615,6 +681,12 @@ export type ApiKeyCreateResponse = {
615
681
  * Created At
616
682
  */
617
683
  created_at: string;
684
+ /**
685
+ * Expires At
686
+ *
687
+ * Expiry timestamp; null means the key does not expire
688
+ */
689
+ expires_at?: string | null;
618
690
  /**
619
691
  * Fingerprint
620
692
  *
@@ -635,6 +707,12 @@ export type ApiKeyCreateResponse = {
635
707
  * Name
636
708
  */
637
709
  name: string;
710
+ /**
711
+ * Scope
712
+ *
713
+ * Privilege scope: 'full' or 'read_only' (#875)
714
+ */
715
+ scope: string;
638
716
  };
639
717
  /**
640
718
  * ApiKeyListItem
@@ -644,6 +722,12 @@ export type ApiKeyListItem = {
644
722
  * Created At
645
723
  */
646
724
  created_at: string;
725
+ /**
726
+ * Expires At
727
+ *
728
+ * Expiry timestamp; null means the key does not expire
729
+ */
730
+ expires_at?: string | null;
647
731
  /**
648
732
  * Fingerprint
649
733
  *
@@ -666,6 +750,12 @@ export type ApiKeyListItem = {
666
750
  * Name
667
751
  */
668
752
  name: string;
753
+ /**
754
+ * Scope
755
+ *
756
+ * Privilege scope: 'full' or 'read_only' (#875)
757
+ */
758
+ scope: string;
669
759
  };
670
760
  /**
671
761
  * ApiKeyListResponse
@@ -2865,10 +2955,14 @@ export type DatasetResponse = {
2865
2955
  * Start of temporal coverage
2866
2956
  */
2867
2957
  data_vintage_start?: string | null;
2958
+ /**
2959
+ * Provenance for an analysis output. Null for a dataset that was not derived, and also for a requester who cannot access the source dataset — the two are deliberately indistinguishable.
2960
+ */
2961
+ derived_from?: DerivedFromResponse | null;
2868
2962
  /**
2869
2963
  * Extent Bbox
2870
2964
  *
2871
- * Bounding box [minx, miny, maxx, maxy]
2965
+ * Bounding box [west, south, east, north] per RFC 7946 §5.2. west > east on an antimeridian-crossing extent.
2872
2966
  */
2873
2967
  extent_bbox?: Array<number> | null;
2874
2968
  /**
@@ -3195,6 +3289,52 @@ export type DbfTruncationDetail = {
3195
3289
  */
3196
3290
  truncated: string;
3197
3291
  };
3292
+ /**
3293
+ * DerivedFromResponse
3294
+ *
3295
+ * Provenance for an analysis output: what it came from, and how.
3296
+ *
3297
+ * fix(#765 review): declared as a model rather than ``dict[str, Any]``. The
3298
+ * dict spelled itself into the checked-in OpenAPI as bare
3299
+ * ``additionalProperties: true``, so both generated SDKs lost the shape — the
3300
+ * TypeScript one degraded to an index signature and the Python one to an
3301
+ * empty additional-properties container. The stable shape was documented in
3302
+ * prose and mirrored by hand in the frontend types while the SDKs, which is
3303
+ * where most consumers actually meet it, could not use it type-safely.
3304
+ *
3305
+ * ``params`` stays untyped on purpose: it is the operation's own parameter
3306
+ * dict, so its keys differ per operation (``distance_meters`` for a buffer,
3307
+ * ``mask_source``/``mask_dataset_id`` for a clip), and it is additionally
3308
+ * REDACTED per requester — ``visible_derived_from`` drops any embedded
3309
+ * dataset id the caller cannot see. A union of per-operation models would
3310
+ * describe a shape the redaction is free to punch holes in.
3311
+ */
3312
+ export type DerivedFromResponse = {
3313
+ /**
3314
+ * Created At
3315
+ */
3316
+ created_at: string;
3317
+ /**
3318
+ * Dataset Id
3319
+ *
3320
+ * The dataset this one was derived from
3321
+ */
3322
+ dataset_id: string;
3323
+ /**
3324
+ * Operation
3325
+ *
3326
+ * Analysis operation that produced it
3327
+ */
3328
+ operation: string;
3329
+ /**
3330
+ * Params
3331
+ *
3332
+ * Operation parameters, minus any dataset reference the requester cannot access
3333
+ */
3334
+ params: {
3335
+ [key: string]: unknown;
3336
+ };
3337
+ };
3198
3338
  /**
3199
3339
  * DetectEmbeddingDimsResponse
3200
3340
  *
@@ -4291,7 +4431,7 @@ export type JobStatusResponse = {
4291
4431
  /**
4292
4432
  * Warnings
4293
4433
  */
4294
- warnings?: Array<ReservedRenameWarning | DbfTruncationCollisionWarning>;
4434
+ warnings?: Array<ReservedRenameWarning | DbfTruncationCollisionWarning | MercatorClipWarning>;
4295
4435
  };
4296
4436
  /**
4297
4437
  * KeywordCreate
@@ -5521,6 +5661,10 @@ export type MapSummaryResponse = {
5521
5661
  * Name
5522
5662
  */
5523
5663
  name: string;
5664
+ /**
5665
+ * Thumbnail Updated At
5666
+ */
5667
+ thumbnail_updated_at?: string | null;
5524
5668
  /**
5525
5669
  * Thumbnail Url
5526
5670
  */
@@ -5622,6 +5766,44 @@ export type MapUpdate = {
5622
5766
  * MapVisibility
5623
5767
  */
5624
5768
  export type MapVisibility = 'private' | 'internal' | 'public';
5769
+ /**
5770
+ * MercatorClipDetail
5771
+ *
5772
+ * fix(#888): how much geometry the Web Mercator clamp destroyed.
5773
+ *
5774
+ * The clamp is a box, not a latitude cutoff: longitude -180 to 180 and
5775
+ * latitude -85.06 to 85.06. Either bound can be the one that cost the user
5776
+ * geometry, so clients must not present this as a latitude-only problem
5777
+ * (fix(#899 codex r1)).
5778
+ *
5779
+ * ``dropped_features`` lost their geometry entirely (a valid point at lat
5780
+ * -89.95 becomes ``MULTIPOINT EMPTY``); ``clipped_features`` survived in
5781
+ * reduced form.
5782
+ */
5783
+ export type MercatorClipDetail = {
5784
+ /**
5785
+ * Clip Skipped
5786
+ */
5787
+ clip_skipped?: boolean;
5788
+ /**
5789
+ * Clipped Features
5790
+ */
5791
+ clipped_features: number;
5792
+ /**
5793
+ * Dropped Features
5794
+ */
5795
+ dropped_features: number;
5796
+ };
5797
+ /**
5798
+ * MercatorClipWarning
5799
+ */
5800
+ export type MercatorClipWarning = {
5801
+ details: MercatorClipDetail;
5802
+ /**
5803
+ * Kind
5804
+ */
5805
+ kind: 'mercator_clip';
5806
+ };
5625
5807
  /**
5626
5808
  * MetadataAssistRequest
5627
5809
  *
@@ -7171,12 +7353,34 @@ export type RasterPreviewResponse = {
7171
7353
  };
7172
7354
  /**
7173
7355
  * RasterTileToken
7356
+ *
7357
+ * A raster tile template, signed like its vector sibling.
7358
+ *
7359
+ * fix(#688): the raster shape used to carry no signature at all, so a client
7360
+ * following the API contract literally received an *unauthenticated* template
7361
+ * for a private raster. MapLibre issues the tile image requests itself and
7362
+ * attaches no `X-Api-Key`, so an API-key-only client could not render one —
7363
+ * the workarounds were `setTransformRequest` (not available to every consumer)
7364
+ * or `?api_key=` in the tile URL, which puts a non-expiring unscoped
7365
+ * credential into tile URLs, server logs, and saved client project files.
7366
+ *
7367
+ * `tile_url` now arrives with `sig`/`exp`/`scope` already in its query string,
7368
+ * so the template is self-sufficient and expires. The three are also returned
7369
+ * as fields, mirroring `VectorTileToken`, for clients that rebuild the URL.
7174
7370
  */
7175
7371
  export type RasterTileToken = {
7176
7372
  /**
7177
7373
  * Bounds
7178
7374
  */
7179
7375
  bounds: Array<number> | null;
7376
+ /**
7377
+ * Exp
7378
+ */
7379
+ exp: number;
7380
+ /**
7381
+ * Expires In
7382
+ */
7383
+ expires_in: number;
7180
7384
  /**
7181
7385
  * Format
7182
7386
  */
@@ -7193,6 +7397,14 @@ export type RasterTileToken = {
7193
7397
  * Minzoom
7194
7398
  */
7195
7399
  minzoom: number;
7400
+ /**
7401
+ * Scope
7402
+ */
7403
+ scope: string;
7404
+ /**
7405
+ * Sig
7406
+ */
7407
+ sig: string;
7196
7408
  /**
7197
7409
  * Tile Size
7198
7410
  */
@@ -24342,46 +24554,6 @@ export type ClusterTileEndpointTilesClustersTablePathZxyPbfGetResponses = {
24342
24554
  */
24343
24555
  200: unknown;
24344
24556
  };
24345
- export type RasterAuthCheckTilesRasterAuthCheckGetData = {
24346
- body?: never;
24347
- path?: never;
24348
- query: {
24349
- /**
24350
- * Dataset Id
24351
- */
24352
- dataset_id: string;
24353
- };
24354
- url: '/tiles/raster-auth-check/';
24355
- };
24356
- export type RasterAuthCheckTilesRasterAuthCheckGetErrors = {
24357
- /**
24358
- * Bad request — invalid query parameters or payload
24359
- */
24360
- 400: ProblemDetail;
24361
- /**
24362
- * Not found
24363
- */
24364
- 404: ProblemDetail;
24365
- /**
24366
- * Validation error
24367
- */
24368
- 422: ProblemDetail;
24369
- /**
24370
- * Internal server error
24371
- */
24372
- 500: ProblemDetail;
24373
- /**
24374
- * Service unavailable — the database could not serve the request
24375
- */
24376
- 503: ProblemDetail;
24377
- };
24378
- export type RasterAuthCheckTilesRasterAuthCheckGetError = RasterAuthCheckTilesRasterAuthCheckGetErrors[keyof RasterAuthCheckTilesRasterAuthCheckGetErrors];
24379
- export type RasterAuthCheckTilesRasterAuthCheckGetResponses = {
24380
- /**
24381
- * Successful Response
24382
- */
24383
- 200: unknown;
24384
- };
24385
24557
  export type RasterTileProxyTilesRasterProxyDatasetIdZxyFmtGetData = {
24386
24558
  body?: never;
24387
24559
  path: {