The best way to control Claude Code, Codex and more from any computer or phone

main
ts 46 lines 1.47 KB
Raw
1 import type * as location from "@distilled.cloud/aws/location";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Map as LocationMap } from "./Map.ts";
5
6 /**
7 * `GetMapStyleDescriptor` request with `MapName` injected from the bound
8 * resource.
9 */
10 export interface GetMapStyleDescriptorRequest extends Omit<
11 location.GetMapStyleDescriptorRequest,
12 "MapName"
13 > {}
14
15 /**
16 * Retrieves the map's style descriptor document (the MapLibre/Mapbox GL style JSON).
17 *
18 * Runtime binding for the `GetMapStyleDescriptor` operation (IAM action
19 * `geo:GetMapStyleDescriptor`), scoped to one {@link LocationMap | Map}. Provide the implementation with
20 * `Effect.provide(AWS.Location.GetMapStyleDescriptorHttp)`.
21 *
22 * ### Serving Map Assets
23 * **Example:** Serve the Style Descriptor
24 * ```typescript
25 * const getStyle = yield* Location.GetMapStyleDescriptor(map);
26 *
27 * const style = yield* getStyle();
28 * // style.Blob → style JSON bytes, style.ContentType → "application/json"
29 * ```
30 *
31 * @binding
32 */
33 export interface GetMapStyleDescriptor extends Binding.Service<
34 GetMapStyleDescriptor,
35 "AWS.Location.GetMapStyleDescriptor",
36 (
37 map: LocationMap,
38 ) => Effect.Effect<
39 (
40 request?: GetMapStyleDescriptorRequest,
41 ) => Effect.Effect<location.GetMapStyleDescriptorResponse, location.GetMapStyleDescriptorError>
42 >
43 > {}
44 export const GetMapStyleDescriptor = Binding.Service<GetMapStyleDescriptor>(
45 "AWS.Location.GetMapStyleDescriptor",
46 );