Sign In

@uipath/common

Package Overview
Dependencies
Maintainers
17
Versions
72
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package version was removed
This package version has been unpublished, mostly likely due to security reasons
This package has malicious versions linked to the ongoing "Mini Shai-Hulud" supply chain attack.

Affected versions:

1.0.1
View campaign page

@uipath/common

Common infrastructure needed by uip tools.

unpublished
Source
npmnpm
Version
1.0.1
Version published
Weekly downloads
1.9K
91.52%
Maintainers
17
Weekly downloads
 
Created
Source

@uipath/common

Shared infrastructure for the UiPath CLI. Provides output formatting, logging, error handling, and telemetry.

Installation

npm install @uipath/common

Usage

Output Formatting

import { OutputFormatter } from "@uipath/common";

OutputFormatter.success({ Result: "Success", Code: "AssetList", Data: assets });
OutputFormatter.error({ Result: RESULTS.Failure, Message: "Not found", Instructions: "Check the ID" });

Supported formats: table, json, yaml, plain.

Error Handling

Go-style [error, data] tuple returns via catchError:

import { catchError } from "@uipath/common";

const [error, result] = await catchError(api.getData());
if (error) {
    OutputFormatter.error({ Result: RESULTS.Failure, Message: error.message, Instructions: "Retry" });
    return;
}

Logging

import { logger, LogLevel } from "@uipath/common";

logger.info("Fetching resources...");
logger.debug("Request payload:", payload);

// Override level at runtime
logger.setLevel(LogLevel.DEBUG);
MethodLevelStreamVisible by default
logger.debugDEBUGstdoutNo
logger.infoINFOstdoutYes
logger.warnWARNstdoutYes
logger.errorERRORstderrYes

Debug output is enabled via DEBUG env var (Node/Bun) or localStorage.debug (browser).

API

ExportDescription
OutputFormatterStructured output in table, JSON, YAML, or plain text
catchError(promise)Go-style error handling returning [error, data] tuples
loggerCross-platform logger with debug/info/warn/error levels
trackedActionCommander.js extension for automatic telemetry tracking
CommandWalkerCLI command introspection utility
OutputSinkAbstraction for output destinations

License

See the root repository for license information.

FAQs

Package last updated on 11 May 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts