| 1 | import type * as sdb from "@distilled.cloud/aws/simpledb"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { RuntimeContext } from "../../RuntimeContext.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for `sdb:ListDomains`. |
| 8 | * |
| 9 | * Account-level operation — invoked with no resource argument. Lists the |
| 10 | * domain names in the current region, one page (up to 100 names) per call; |
| 11 | * pass the response's `NextToken` back to continue. Useful for the classic |
| 12 | * SimpleDB domain-sharding pattern where an application spreads items across |
| 13 | * many domains and discovers them at runtime. Provide the implementation |
| 14 | * with `Effect.provide(AWS.SimpleDB.ListDomainsHttp)`. |
| 15 | * ### Domain Introspection |
| 16 | * **Example:** List Domain Names |
| 17 | * ```typescript |
| 18 | * // init — account-level binding, no resource argument |
| 19 | * const listDomains = yield* AWS.SimpleDB.ListDomains(); |
| 20 | * |
| 21 | * // runtime |
| 22 | * const page = yield* listDomains({ MaxNumberOfDomains: 100 }); |
| 23 | * // page.DomainNames: ["users-shard-0", "users-shard-1", ...] |
| 24 | * ``` |
| 25 | * |
| 26 | * @binding |
| 27 | */ |
| 28 | export interface ListDomains extends Binding.Service< |
| 29 | ListDomains, |
| 30 | "AWS.SimpleDB.ListDomains", |
| 31 | () => Effect.Effect< |
| 32 | ( |
| 33 | request?: sdb.ListDomainsRequest, |
| 34 | ) => Effect.Effect< |
| 35 | sdb.ListDomainsResponse, |
| 36 | sdb.ListDomainsError, |
| 37 | RuntimeContext |
| 38 | > |
| 39 | > |
| 40 | > {} |
| 41 | export const ListDomains = Binding.Service<ListDomains>( |
| 42 | "AWS.SimpleDB.ListDomains", |
| 43 | ); |