Skip to main content

mr tag create

Create a new tag. --name is required and must be unique; --description is optional free-form text. On success prints a confirmation line with the new ID; pass the global --json flag to emit the full record for scripting (e.g., piping the new ID into follow-up commands).

Usage

mr tag create

Examples

Create a tag with just a name

mr tag create --name "urgent"

Create with a description and capture the ID via jq

ID=$(mr tag create --name "archived" --description "archived items" --json | jq -r .ID)

Flags

FlagTypeDefaultDescription
--namestring``Tag name (required) (required)
--descriptionstring``Tag description

Inherited global flags

FlagTypeDefaultDescription
--jsonboolfalseOutput raw JSON
--no-headerboolfalseOmit table headers
--pageint1Page number for list commands (default page size: 50)
--quietboolfalseOnly output IDs
--serverstringhttp://localhost:8181mahresources server URL (env: MAHRESOURCES_URL)

Output

Created Tag object with ID (uint), Name (string), Description (string), CreatedAt, UpdatedAt

Exit Codes

0 on success; 1 on any error

See Also