Skip to main content

programKeyToID

programKeyToID(key): number

Defined in: src/utils/programs.ts:15

Decodes program ID from a program key

Parameters

key

`ag5zfmtoYW4tYWNhZGVteXI${string}CxIKU2NyYXRjaHBhZB${string}${string}`

Returns

number

Remarks

Program keys are (URL-safe) Base64 encoded strings that contain the program ID.

Credit to @L1quidH2O for the original implementation.