function · Browser and Node

# decodeMembershipCode

The secret, or null for a typo or a code made for another group.

`@toip-tools/anon-membership` · [View source](https://github.com/yourbuddyconner/toip-tools/blob/main/packages/anon-membership/src/encode.ts#L116)

Import:

```ts
import { decodeMembershipCode } from "@toip-tools/anon-membership";
```

## Declaration

Signature:

```ts
decodeMembershipCode(code: string, groupId: string): Field | null;
```

### Parameters

- **`code` (required)**: `string`
- **`groupId` (required)**: `string`

### Returns

`bigint | null`

[Usage guide](https://toip.tools/toolkit/anon-membership/#usage) · [Error handling](https://toip.tools/toolkit/anon-membership/#errors) · [All exports](https://toip.tools/toolkit/anon-membership/api/)

---

This is the Markdown version of https://toip.tools/toolkit/anon-membership/api/decodeMembershipCode/. An index of the documentation for AI assistants is at https://toip.tools/llms.txt.
