# ksuid

Generates a KSUID from the current time and 16 random bytes.

## Signatures

```ts
export declare const ksuid: Effect.Effect<Ksuid, Cause.IllegalArgumentError, DateTimes | RandomValues>;
```

## Why

Time and entropy remain explicit Effect services; timestamps outside KSUID's 32-bit seconds field fail with `IllegalArgumentError`.

## Ownership and lifetime

The Effect acquires no persistent resources and uses DateTimes and RandomValues only for the invocation.

## Examples

```ts
import { ksuid } from "@typed/id/Ksuid"
import { DateTimes } from "@typed/id/DateTimes"
import { RandomValues } from "@typed/id/RandomValues"
import { Effect, Layer } from "effect"
const id = Effect.provide(ksuid, Layer.merge(DateTimes.Default, RandomValues.Default))
```
