This documentation provides the usage of RowID CLI.
Install this package as a global dependency:
# npm
npm i -g rowid-cli
# Yarn
yarn global add rowid-cli
# pnpm
pnpm add -g rowid-cli
RowID CLI provides the following commands:
This command generates a 32-character unique ID that is almost impossible to duplicate. You may pass the -r
/ --randomness
option to specify the number of randomness, a larger number will generate a longer ID, with less chance of collision.
This command encodes the timestamp into a ID without randomness.
This command decodes the ID into a Date.
This command generates a ID based on the input. Since the number
argument is optional, you may omit it.
This command verifies if the ID is valid and natural.
This command generates randomness.
After installing the CLI and running it once, you may customize its behavior by editing the .rowid.json
file located in the current user's home directory. For type checking, please reference to the schema.json
file included in the root directory of the CLI project.
{
"$schema": "/path/to/cli/schema.json"
}