# key

## Call Signature

> **key**(): [`Column`](https://stage.docs.arkiv.network/typescript-sdk/api-reference/main/type-aliases/column/)\<`"key"`, `false`, `false`, `false`\>

Defined in: [src/schema/values.ts:388](https://github.com/Arkiv-Network/arkiv-sdk-js/blob/d464c8dce16c3b8c472479ac5aae9d14344eb067/src/schema/values.ts#L388)

A `key` column — a reference to another entity — indexed for equality once `.indexed()`.

### Returns

[`Column`](https://stage.docs.arkiv.network/typescript-sdk/api-reference/main/type-aliases/column/)\<`"key"`, `false`, `false`, `false`\>

## Call Signature

> **key**(`value`): [`KeyValue`](https://stage.docs.arkiv.network/typescript-sdk/api-reference/main/type-aliases/keyvalue/)

Defined in: [src/schema/values.ts:401](https://github.com/Arkiv-Network/arkiv-sdk-js/blob/d464c8dce16c3b8c472479ac5aae9d14344eb067/src/schema/values.ts#L401)

A reference to another entity.

References are **weak**: nothing checks that the target exists when you write it, and a
reference to a deleted or expired entity is allowed to dangle.

### Parameters

#### value

A 32-byte entity key, as `0x` hex or raw bytes.

`` `0x${string}` `` | `Uint8Array`\<`ArrayBufferLike`\>

### Returns

[`KeyValue`](https://stage.docs.arkiv.network/typescript-sdk/api-reference/main/type-aliases/keyvalue/)

### Throws

If the value is not exactly 32 bytes.

### Example

```ts
key(parentEntityKey)
```