Record Type Commands
Commands for creating and managing Record Types and Custom Templates
The commands associated with Record Types are listed below. For more information on record types, including example usage, see the documentation

Commands

Keeper Command Reference

Whether using the interactive shell, CLI or JSON config file, Keeper supports the following commands, each command supports additional parameters and options.
To get help on a particular command, run:
help <command>

All commands associated with record types

Command
Explanation
record-type-info or rti
List record types or see information about a specific record type
record-type or rt
Add, edit, or delete custom record types
convert
Convert legacy records to record-typed records

record-type-info command:

Command: record-type-info or rti
Detail: List available record types. or details of a specific record type
Switches:
-lr, --list-record <RECORD TYPE OR ID (optional)>
  • If record type name or ID is not given, lists all record type names and IDs
  • if a record type name or ID is given, displays the record type's details and fields
-lf, --list-field <FIELD NAME> show information about a specified field type. Can use "*" to show all fields.
-e, --example generate example json for a record type or field. *Must use with -lr or -lf
--syntax-help display extended help on record type parameters
--format <{csv, json, table}> choose the format to output in
--output <OUTPUT FILE> output results to a given file *ignored if table format is used
Examples:
rti
rti -lr login
rti -lf name
rti -lf *
rti -lr passport -e
rti --syntax-help
rti --output logs/record-types.csv --format csv
  1. 1.
    show list of record types
  2. 2.
    show details of the login record type
  3. 3.
    show details of the name field type
  4. 4.
    show details of all field types
  5. 5.
    display an example of the passport record type
  6. 6.
    display extended syntax help text
  7. 7.
    write the record type information as a CSV to a file

record-type command:

Command: record-type or rt
Detail: Add, modify, or delete custom record types
Parameters:
Record type ID (if updating or deleting)
Switches:
-a, --action <{add, update, remove}> action to perform
  • add - create a new custom record type
  • update - modify an existing custom record type
  • remove - delete an existing custom record type
--data <DATA> JSON formatted definition of the record type
Format:
Record types utilize the following formatting:
{ "$id": <record type name>,
"fields": [
{ "$ref": <field type>},
{ "$ref": <field type>, "label": <foeld label(optional)>, required: <true/false (optional) }
] }
Example:
{
"$id":"My Record Type",
"fields": [
{
"$ref":"login",
"label":"AppLogin",
"required":true
},
{
"$ref":"name",
"label":"Your name"
},
{
"$ref":"address",
"required":true
}
]
}
  • See a list of all field types here
  • Use the following command to see a list of available field types: rti -lf *
Examples:
rt --action add --data '{"$id":"My Record Type", "fields": [{"$ref":"login","label":"AppLogin","required":true},{"$ref":"name","label":"Your name"},{"$ref":"address","required":true}]}'
rt 102 -a update --data '{"$id":"My Record Type", "fields": [{"$ref":"login","label":"AppLogin","required":true},{"$ref":"name","label":"Your name"}]}'
rt 102 -a remove
  1. 1.
    Add a new record type named "My Record Type"
  2. 2.
    Update the "My Record Type" record Type (which has an ID of 102 in this example). Here, the 'Address' field was removed
  3. 3.
    Remove the record type with Id 102

convert command:

Required Version: v16.5.9+
Command: convert
Detail: Convert legacy (General typed or untyped) records to typed records.
The convert command will only convert legacy, untyped records to typed records.
To convert the type of a typed record, use the edit command.
Parameters:
Pattern to match records in the current folder. Matches against UIDs and titles. Can use "?" to match any single character and "*" to match any number of characters
Switches:
-t, --record-type <RECORD TYPE OR ID > The type to convert records to
-q, --quiet Do not show info about matched and converted records
-u, --url <URL Pattern> Only converts records with URLs that match the given pattern. Can use "?" to match any single character and "*" to match any number of characters
-n, --dry-run Display the outcome of the conversion without converting any records
-r, --recursive apply conversion to all matching records in the current and child folders
--ignore-ownership convert records even if they are not owned by the current account
Examples:
convert Dtvb84zwkBmZgxrUByUfpg --record-type login
convert * --record-type login --recursive --dry-run
convert * -t login -r
convert *sql* -t databaseCredentials
convert *ssh-? -t sshKeys --recursive
  1. 1.
    Convert the untyped record with the given UID to a login type record
  2. 2.
    Perform a dry-run of conversion of all records in the vault and display what records would be converted. (will match all records if performed at the root directory)
  3. 3.
    Convert all untyped records in the vault to login type (if performed at the root directory)
  4. 4.
    Convert any untyped record that contains 'sql' in its name to a database credential
  5. 5.
    Convert any record that ends in ssh-<anything> to a sshKey type record
    1. 1.
      e.g convert a record titled "Github ssh-1" and a record titled "Github ssh-2"
Export as PDF
Copy link
On this page
Commands
record-type-info command:
record-type command:
convert command: