Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@commercelayer/cli

Package Overview
Dependencies
Maintainers
6
Versions
187
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@commercelayer/cli - npm Package Compare versions

Comparing version 5.6.2 to 5.7.0

4

lib/commands/applications/add.d.ts

@@ -16,4 +16,4 @@ import { Command } from '@oclif/core';

};
catch(error: any): Promise<void>;
run(): Promise<void>;
catch(error: any): Promise<any>;
run(): Promise<any>;
}

@@ -11,4 +11,4 @@ import { Command } from '@oclif/core';

};
run(): Promise<void>;
run(): Promise<any>;
}
export declare const printCurrent: (app?: AppInfo) => string;

@@ -48,3 +48,3 @@ "use strict";

var _a;
if (!app || !app.key || (app.key === ''))
if (!(app === null || app === void 0 ? void 0 : app.key) || (app.key === ''))
return cli_core_1.clColor.italic.dim('No current application');

@@ -51,0 +51,0 @@ const mode = `${((app.mode === 'live') ? cli_core_1.clColor.api.live.greenBright : cli_core_1.clColor.api.test)(app.mode)}`;

@@ -19,3 +19,3 @@ import Command from '../../base';

static args: never[];
run(): Promise<void>;
run(): Promise<any>;
}

@@ -16,3 +16,3 @@ import Command from '../../base';

};
run(): Promise<import("@commercelayer/cli-core/lib/cjs/application").AppInfo>;
run(): Promise<any>;
}

@@ -18,4 +18,4 @@ import { Command, Config } from '@oclif/core';

};
catch(error: any): Promise<void>;
run(): Promise<void>;
catch(error: any): Promise<any>;
run(): Promise<any>;
}

@@ -22,0 +22,0 @@ declare const getApplicationInfo: (auth: AppAuth, accessToken: string) => Promise<AppInfo>;

@@ -133,3 +133,3 @@ "use strict";

slug: org.slug || '',
mode: mode,
mode,
kind: app.kind || '',

@@ -136,0 +136,0 @@ name: app.name || '',

@@ -16,3 +16,3 @@ import Command from '../../base';

};
run(): Promise<void>;
run(): Promise<any>;
}

@@ -7,4 +7,3 @@ "use strict";

const config_1 = require("../../config");
const login_1 = require("./login");
const login_2 = tslib_1.__importDefault(require("./login"));
const login_1 = tslib_1.__importStar(require("./login"));
const common_1 = require("../../common");

@@ -52,3 +51,3 @@ const current_1 = require("./current");

argv.push('-a', alias);
appInfo = await login_2.default.run(argv, this.config);
appInfo = await login_1.default.run(argv, this.config);
}

@@ -55,0 +54,0 @@ return appInfo;

@@ -15,3 +15,3 @@ import Command from '../../base';

};
run(): Promise<void>;
run(): Promise<any>;
}

@@ -45,3 +45,3 @@ "use strict";

catch (error) {
this.log(cli_core_1.clColor.msg.error.bold('FAILURE! ') + error.message);
this.log(cli_core_1.clColor.msg.error.bold('FAILURE! ') + String(error.message));
}

@@ -48,0 +48,0 @@ }

@@ -9,3 +9,3 @@ import { Command } from '@oclif/core';

};
run(): Promise<void>;
run(): Promise<any>;
}
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
/* eslint-disable @typescript-eslint/no-misused-promises */
const core_1 = require("@oclif/core");

@@ -32,6 +33,5 @@ const child_process_1 = require("child_process");

this.log();
this.log('Code: ' + code);
this.log('Signal: ' + signal);
this.log(`Code: ${code}`);
this.log(`Signal: ${signal}`);
this.log();
// eslint-disable-next-line no-process-exit, unicorn/no-process-exit
process.exit();

@@ -38,0 +38,0 @@ }

@@ -9,3 +9,3 @@ import { Command } from '@oclif/core';

static args: never[];
run(): Promise<void>;
run(): Promise<any>;
}

@@ -13,3 +13,3 @@ import { Command } from '@oclif/core';

}[];
run(): Promise<void>;
run(): Promise<any>;
}

@@ -11,3 +11,3 @@ import { Command } from '@oclif/core';

}[];
run(): Promise<void>;
run(): Promise<any>;
}

@@ -13,3 +13,3 @@ import { Command } from '@oclif/core';

}[];
run(): Promise<void>;
run(): Promise<any>;
}

@@ -7,3 +7,3 @@ import { Command } from '@oclif/core';

static args: never[];
run(): Promise<void>;
run(): Promise<any>;
}

@@ -8,3 +8,3 @@ import { Command } from '@oclif/core';

};
run(): Promise<string>;
run(): Promise<any>;
}

@@ -10,5 +10,5 @@ import { Command } from '@oclif/core';

static args: never[];
run(): Promise<void>;
run(): Promise<any>;
}
declare type PluginRelease = {
type PluginRelease = {
name: string;

@@ -15,0 +15,0 @@ plugin: string;

@@ -12,3 +12,3 @@ "use strict";

return '';
return scope[0] + ((scope.length > 1) ? ` ${cli_core_1.clColor.italic.dim('+' + (scope.length - 1))}` : '');
return scope[0] + ((scope.length > 1) ? ` ${cli_core_1.clColor.italic.dim('+' + String(scope.length - 1))}` : '');
}

@@ -15,0 +15,0 @@ return scope;

@@ -8,6 +8,7 @@ "use strict";

const hook = async function (opts) {
var _a, _b;
// Do not save fake commands output
if (opts.Command.id && (opts.Command.id.toLowerCase().endsWith('noc')))
if ((_a = opts.Command.id) === null || _a === void 0 ? void 0 : _a.toLowerCase().endsWith('noc'))
return;
if (opts.Command.name && (opts.Command.name.toLowerCase().endsWith('noc')))
if ((_b = opts.Command.name) === null || _b === void 0 ? void 0 : _b.toLowerCase().endsWith('noc'))
return;

@@ -14,0 +15,0 @@ // Save last results

@@ -122,5 +122,5 @@ "use strict";

this.error('Unable to refresh application access token');
opts.argv.push('--accessToken=' + tokenData.access_token);
opts.argv.push('--accessToken=' + String(tokenData.access_token));
}
};
exports.default = hook;

@@ -45,3 +45,3 @@ "use strict";

if (tgIndex > -1) {
plugin = plugin + '@' + opts.argv[tgIndex + 1];
plugin = `${plugin}@${opts.argv[tgIndex + 1]}`;
opts.argv.splice(tgIndex, 2);

@@ -48,0 +48,0 @@ }

import { Command, LoadOptions, Config as IConfig } from '@oclif/core/lib/interfaces';
import { Config } from '@oclif/core';
export declare class PatchedConfig extends Config {
static load(opts?: LoadOptions): Promise<IConfig | PatchedConfig>;
static load(opts?: LoadOptions): Promise<IConfig>;
runCommand<T = unknown>(id: string, argv?: string[], cachedCommand?: Command.Plugin): Promise<T>;
}

@@ -14,3 +14,5 @@ "use strict";

class PatchedConfig extends core_1.Config {
static async load(opts = (module.parent && module.parent.parent && module.parent.parent.filename) || __dirname) {
static async load(opts) {
var _a, _b;
if (opts === void 0) { opts = ((_b = (_a = module.parent) === null || _a === void 0 ? void 0 : _a.parent) === null || _b === void 0 ? void 0 : _b.filename) || __dirname; }
// Handle the case when a file URL string is passed in such as 'import.meta.url'; covert to file path.

@@ -48,3 +50,3 @@ if (typeof opts === 'string' && opts.startsWith('file://')) {

const result = (await command.run(argv, this));
const postrunHook = await this.runHook('postrun', { Command: command, result: result, argv });
const postrunHook = await this.runHook('postrun', { Command: command, result, argv });
if (postrunHook.failures[0])

@@ -51,0 +53,0 @@ throw new errors_1.CLIError(postrunHook.failures[0].error);

import * as Interfaces from '@oclif/core/lib/interfaces';
export declare function run(argv?: string[], options?: Interfaces.LoadOptions): Promise<unknown>;
export declare function run(argv?: string[], options?: Interfaces.LoadOptions): Promise<void>;

@@ -6,3 +6,2 @@ "use strict";

const util_1 = require("util");
const url_2 = require("url");
const config_1 = require("./config");

@@ -19,10 +18,10 @@ const help_1 = require("@oclif/core/lib/help");

async function run(argv = process.argv.slice(2), options) {
var _a;
var _a, _b, _c;
// Handle the case when a file URL string or URL is passed in such as 'import.meta.url'; covert to file path.
if (options && ((typeof options === 'string' && options.startsWith('file://')) || options instanceof url_2.URL)) {
if (options && ((typeof options === 'string' && options.startsWith('file://')) || options instanceof url_1.URL)) {
options = (0, url_1.fileURLToPath)(options);
}
// return Main.run(argv, options)
const config = await config_1.PatchedConfig.load(options || (module.parent && module.parent.parent && module.parent.parent.filename) || __dirname);
if (config.topicSeparator !== ':' && !((_a = argv[0]) === null || _a === void 0 ? void 0 : _a.includes(':')))
const config = await config_1.PatchedConfig.load(options || ((_b = (_a = module.parent) === null || _a === void 0 ? void 0 : _a.parent) === null || _b === void 0 ? void 0 : _b.filename) || __dirname);
if (config.topicSeparator !== ':' && !((_c = argv[0]) === null || _c === void 0 ? void 0 : _c.includes(':')))
argv = (0, help_1.standardizeIDFromArgv)(argv, config);

@@ -29,0 +28,0 @@ let [id, ...argvSlice] = argv;

@@ -1,1 +0,1 @@

{"version":"5.6.2","commands":{"noc":{"id":"noc","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"organization":{"name":"organization","type":"option","hidden":true,"required":false,"multiple":false},"accessToken":{"name":"accessToken","type":"option","hidden":true,"required":false,"multiple":false}},"args":[]},"applications:add":{"id":"applications:add","description":"add a new Commerce Layer application to CLI config","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:add"],"examples":["$ commercelayer applications:add -o <organizationSlug> -i <clientId> -s <clientSecret> -a <applicationAlias>"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","required":true,"multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"clientId":{"name":"clientId","type":"option","char":"i","description":"application client_id","required":true,"multiple":false},"clientSecret":{"name":"clientSecret","type":"option","char":"s","description":"application client_secret","required":false,"multiple":false},"scope":{"name":"scope","type":"option","char":"S","description":"access token scope (market, stock location)","required":false,"multiple":true},"email":{"name":"email","type":"option","char":"e","description":"customer email","multiple":false,"dependsOn":["password"]},"password":{"name":"password","type":"option","char":"p","description":"customer secret password","multiple":false,"dependsOn":["email"]},"alias":{"name":"alias","type":"option","char":"a","description":"the alias you want to associate to the application","required":true,"multiple":false}},"args":[]},"applications:current":{"id":"applications:current","description":"show the current application","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:current"],"examples":["$ commercelayer applications:current","$ commercelayer app:current --info"],"flags":{"info":{"name":"info","type":"boolean","hidden":true,"allowNo":false,"exclusive":["organization","live"]},"json":{"name":"json","type":"boolean","char":"j","description":"show info in JSON format","allowNo":false,"dependsOn":["info"]}},"args":[]},"applications":{"id":"applications","description":"show a list of all (logged in) available CLI applications","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:list","applications:list","app:available","applications:available","apps"],"examples":["$ commercelayer applications","$ cl applications"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"extra":{"name":"extra","type":"boolean","char":"X","description":"show applications extra info","hidden":true,"allowNo":false},"sort":{"name":"sort","type":"boolean","char":"S","description":"sort applications by Organization and Application name","allowNo":false}},"args":[]},"applications:info":{"id":"applications:info","description":"show application details","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:info"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"json":{"name":"json","type":"boolean","char":"j","description":"show info in JSON format","allowNo":false}},"args":[]},"applications:login":{"id":"applications:login","description":"execute login to a Commerce Layer application","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:login"],"examples":["$ commercelayer applications:login -o <organizationSlug> -i <clientId> -s <clientSecret> -a <applicationAlias>"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","required":true,"multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"clientId":{"name":"clientId","type":"option","char":"i","description":"application client_id","required":true,"multiple":false},"clientSecret":{"name":"clientSecret","type":"option","char":"s","description":"application client_secret","required":false,"multiple":false},"scope":{"name":"scope","type":"option","char":"S","description":"access token scope (market, stock location)","required":false,"multiple":true},"email":{"name":"email","type":"option","char":"e","description":"customer email","multiple":false,"dependsOn":["password"]},"password":{"name":"password","type":"option","char":"p","description":"customer secret password","multiple":false,"dependsOn":["email"]},"alias":{"name":"alias","type":"option","char":"a","description":"the alias you want to associate to the application","required":true,"multiple":false}},"args":[]},"applications:logout":{"id":"applications:logout","description":"remove an application from CLI local configuration","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:logout","app:remove","applications:remove"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"revoke":{"name":"revoke","type":"boolean","char":"r","description":"revoke current access token","allowNo":false}},"args":[]},"applications:scope":{"id":"applications:scope","description":"switch scope of current application","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:scope"],"examples":["$ commercelayer <%= command.id %> market:1234","$ cl app:scope market:1234"],"flags":{"alias":{"name":"alias","type":"option","char":"a","description":"the alias you want to associate to the application","required":false,"multiple":false}},"args":[{"name":"scope","description":"the application scope","required":true}]},"applications:switch":{"id":"applications:switch","description":"switch applications","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:switch"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]}},"args":[]},"applications:token":{"id":"applications:token","description":"get a new access token from Commerce Layer API","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","hidden":true,"aliases":["app:token"],"examples":["$ commercelayer applications:token","$ commercelayer app:token --info"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"save":{"name":"save","type":"boolean","char":"s","description":"save access token","allowNo":false},"info":{"name":"info","type":"boolean","char":"i","description":"show access token info","allowNo":false},"shared":{"name":"shared","type":"option","char":"S","description":"organization shared secret","hidden":true,"multiple":false,"exclusive":["save"]},"minutes":{"name":"minutes","type":"option","char":"M","description":"minutes to token expiration [2, 120]","hidden":true,"multiple":false,"dependsOn":["shared"]}},"args":[]},"cli:update":{"id":"cli:update","description":"Update Commerce Layer CLI","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["upgrade","latest"],"examples":["<%= config.bin %> <%= command.id %> --version=<version-or-tag>"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"Update CLI to a specific version or tag","required":false,"multiple":false}},"args":[]},"cli:version":{"id":"cli:version","description":"Show installed version of Commerce Layer CLI","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["version"],"examples":["<%= config.bin %> <%= command.id %>"],"flags":{},"args":[]},"config:default":{"id":"config:default","description":"reset CLI configuration to default values","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"F","description":"mandatory flag to avoid unintentional config changes","hidden":true,"required":false,"allowNo":false}},"args":[]},"config:del":{"id":"config:del","description":"delete a CLI configuration parameter","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"F","description":"mandatory flag to avoid unintentional config changes","hidden":true,"required":false,"allowNo":false}},"args":[{"name":"param","description":"configuration parameter name","required":true}]},"config:get":{"id":"config:get","description":"get a CLI configuration parameter","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"param","description":"configuration parameter name","required":true}]},"config:set":{"id":"config:set","description":"set a CLI configuration parameter","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"F","description":"mandatory flag to avoid unintentional config changes","hidden":true,"required":false,"allowNo":false}},"args":[{"name":"param","description":"configuration parameter name","required":true},{"name":"value","description":"value to be saved in configuration file","required":true}]},"config:show":{"id":"config:show","description":"show current CLI configuration","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"plugins:available":{"id":"plugins:available","description":"show all available Commerce Layer CLI plugins","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"examples":["$ commercelayer plugins:available"],"flags":{"hidden":{"name":"hidden","type":"boolean","char":"H","description":"show also enabled but hidden plugins","hidden":true,"allowNo":false}},"args":[]}}}
{"version":"5.7.0","commands":{"noc":{"id":"noc","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"organization":{"name":"organization","type":"option","hidden":true,"required":false,"multiple":false},"accessToken":{"name":"accessToken","type":"option","hidden":true,"required":false,"multiple":false}},"args":[]},"applications:add":{"id":"applications:add","description":"add a new Commerce Layer application to CLI config","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:add"],"examples":["$ commercelayer applications:add -o <organizationSlug> -i <clientId> -s <clientSecret> -a <applicationAlias>"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","required":true,"multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"clientId":{"name":"clientId","type":"option","char":"i","description":"application client_id","required":true,"multiple":false},"clientSecret":{"name":"clientSecret","type":"option","char":"s","description":"application client_secret","required":false,"multiple":false},"scope":{"name":"scope","type":"option","char":"S","description":"access token scope (market, stock location)","required":false,"multiple":true},"email":{"name":"email","type":"option","char":"e","description":"customer email","multiple":false,"dependsOn":["password"]},"password":{"name":"password","type":"option","char":"p","description":"customer secret password","multiple":false,"dependsOn":["email"]},"alias":{"name":"alias","type":"option","char":"a","description":"the alias you want to associate to the application","required":true,"multiple":false}},"args":[]},"applications:current":{"id":"applications:current","description":"show the current application","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:current"],"examples":["$ commercelayer applications:current","$ commercelayer app:current --info"],"flags":{"info":{"name":"info","type":"boolean","hidden":true,"allowNo":false,"exclusive":["organization","live"]},"json":{"name":"json","type":"boolean","char":"j","description":"show info in JSON format","allowNo":false,"dependsOn":["info"]}},"args":[]},"applications":{"id":"applications","description":"show a list of all (logged in) available CLI applications","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:list","applications:list","app:available","applications:available","apps"],"examples":["$ commercelayer applications","$ cl applications"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"extra":{"name":"extra","type":"boolean","char":"X","description":"show applications extra info","hidden":true,"allowNo":false},"sort":{"name":"sort","type":"boolean","char":"S","description":"sort applications by Organization and Application name","allowNo":false}},"args":[]},"applications:info":{"id":"applications:info","description":"show application details","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:info"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"json":{"name":"json","type":"boolean","char":"j","description":"show info in JSON format","allowNo":false}},"args":[]},"applications:login":{"id":"applications:login","description":"execute login to a Commerce Layer application","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:login"],"examples":["$ commercelayer applications:login -o <organizationSlug> -i <clientId> -s <clientSecret> -a <applicationAlias>"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","required":true,"multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"clientId":{"name":"clientId","type":"option","char":"i","description":"application client_id","required":true,"multiple":false},"clientSecret":{"name":"clientSecret","type":"option","char":"s","description":"application client_secret","required":false,"multiple":false},"scope":{"name":"scope","type":"option","char":"S","description":"access token scope (market, stock location)","required":false,"multiple":true},"email":{"name":"email","type":"option","char":"e","description":"customer email","multiple":false,"dependsOn":["password"]},"password":{"name":"password","type":"option","char":"p","description":"customer secret password","multiple":false,"dependsOn":["email"]},"alias":{"name":"alias","type":"option","char":"a","description":"the alias you want to associate to the application","required":true,"multiple":false}},"args":[]},"applications:logout":{"id":"applications:logout","description":"remove an application from CLI local configuration","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:logout","app:remove","applications:remove"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"revoke":{"name":"revoke","type":"boolean","char":"r","description":"revoke current access token","allowNo":false}},"args":[]},"applications:scope":{"id":"applications:scope","description":"switch scope of current application","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:scope"],"examples":["$ commercelayer <%= command.id %> market:1234","$ cl app:scope market:1234"],"flags":{"alias":{"name":"alias","type":"option","char":"a","description":"the alias you want to associate to the application","required":false,"multiple":false}},"args":[{"name":"scope","description":"the application scope","required":true}]},"applications:switch":{"id":"applications:switch","description":"switch applications","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["app:switch"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]}},"args":[]},"applications:token":{"id":"applications:token","description":"get a new access token from Commerce Layer API","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","hidden":true,"aliases":["app:token"],"examples":["$ commercelayer applications:token","$ commercelayer app:token --info"],"flags":{"organization":{"name":"organization","type":"option","char":"o","description":"organization slug","multiple":false},"domain":{"name":"domain","type":"option","char":"d","description":"api domain","hidden":true,"required":false,"multiple":false,"dependsOn":["organization"]},"kind":{"name":"kind","type":"option","char":"k","description":"application kind","multiple":false,"options":["integration","sales_channel"]},"mode":{"name":"mode","type":"option","char":"m","description":"execution mode","multiple":false,"options":["test","live"]},"live":{"name":"live","type":"boolean","description":"live execution mode","allowNo":false,"exclusive":["mode"]},"id":{"name":"id","type":"option","description":"application id","multiple":false},"alias":{"name":"alias","type":"option","char":"a","description":"the alias associated to the application","multiple":false,"exclusive":["id"]},"appkey":{"name":"appkey","type":"option","description":"CLI application key","hidden":true,"multiple":false,"exclusive":["alias","id","mode","kind"]},"save":{"name":"save","type":"boolean","char":"s","description":"save access token","allowNo":false},"info":{"name":"info","type":"boolean","char":"i","description":"show access token info","allowNo":false},"shared":{"name":"shared","type":"option","char":"S","description":"organization shared secret","hidden":true,"multiple":false,"exclusive":["save"]},"minutes":{"name":"minutes","type":"option","char":"M","description":"minutes to token expiration [2, 120]","hidden":true,"multiple":false,"dependsOn":["shared"]}},"args":[]},"cli:update":{"id":"cli:update","description":"Update Commerce Layer CLI","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["upgrade","latest"],"examples":["<%= config.bin %> <%= command.id %> --version=<version-or-tag>"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"Update CLI to a specific version or tag","required":false,"multiple":false}},"args":[]},"cli:version":{"id":"cli:version","description":"Show installed version of Commerce Layer CLI","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":["version"],"examples":["<%= config.bin %> <%= command.id %>"],"flags":{},"args":[]},"config:default":{"id":"config:default","description":"reset CLI configuration to default values","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"F","description":"mandatory flag to avoid unintentional config changes","hidden":true,"required":false,"allowNo":false}},"args":[]},"config:del":{"id":"config:del","description":"delete a CLI configuration parameter","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"F","description":"mandatory flag to avoid unintentional config changes","hidden":true,"required":false,"allowNo":false}},"args":[{"name":"param","description":"configuration parameter name","required":true}]},"config:get":{"id":"config:get","description":"get a CLI configuration parameter","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"param","description":"configuration parameter name","required":true}]},"config:set":{"id":"config:set","description":"set a CLI configuration parameter","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"F","description":"mandatory flag to avoid unintentional config changes","hidden":true,"required":false,"allowNo":false}},"args":[{"name":"param","description":"configuration parameter name","required":true},{"name":"value","description":"value to be saved in configuration file","required":true}]},"config:show":{"id":"config:show","description":"show current CLI configuration","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"plugins:available":{"id":"plugins:available","description":"show all available Commerce Layer CLI plugins","strict":true,"pluginName":"@commercelayer/cli","pluginAlias":"@commercelayer/cli","pluginType":"core","aliases":[],"examples":["$ commercelayer plugins:available"],"flags":{"hidden":{"name":"hidden","type":"boolean","char":"H","description":"show also enabled but hidden plugins","hidden":true,"allowNo":false}},"args":[]}}}
{
"name": "@commercelayer/cli",
"description": "Commerce Layer CLI",
"version": "5.6.2",
"version": "5.7.0",
"author": "Pierluigi Viti <pierluigi@commercelayer.io>",

@@ -41,3 +41,3 @@ "bin": {

"devPlugins": [
"@withfig/oclif"
"@fig/complete-oclif"
],

@@ -73,3 +73,3 @@ "aliases": {

"description": "Core CLI commands",
"hidden": true
"hidden": false
}

@@ -88,19 +88,18 @@ },

"@commercelayer/cli-dev": "^0.1.10",
"@commercelayer/eslint-config-ts": "^0.1.4",
"@fig/complete-oclif": "^3.0.0",
"@oclif/test": "^2.2.6",
"@types/chai": "^4.3.3",
"@oclif/test": "^2.2.10",
"@types/chai": "^4.3.4",
"@types/configstore": "^4.0.0",
"@types/inquirer": "^8.2.4",
"@types/lodash": "^4.14.186",
"@types/mocha": "^9.1.1",
"@types/node": "^18.11.4",
"@types/inquirer": "^8.2.5",
"@types/lodash": "^4.14.189",
"@types/mocha": "^10.0.0",
"@types/node": "^18.11.9",
"@types/update-notifier": "^5.1.0",
"chai": "^4.3.6",
"eslint": "^5.16.0",
"eslint-config-oclif": "^3.1.0",
"eslint-config-oclif-typescript": "^0.2.0",
"mocha": "^9.2.2",
"chai": "^4.3.7",
"eslint": "^8.27.0",
"mocha": "^10.1.0",
"nyc": "^15.1.0",
"ts-node": "^10.9.1",
"typescript": "^4.8.4"
"typescript": "^4.9.3"
},

@@ -110,12 +109,12 @@ "dependencies": {

"@commercelayer/js-auth": "^2.3.0",
"@commercelayer/sdk": "4.16.0",
"@oclif/core": "^1.19.1",
"@oclif/plugin-autocomplete": "^1.3.4",
"@oclif/plugin-help": "5.1.15",
"@oclif/plugin-not-found": "^2.3.6",
"@oclif/plugin-plugins": "^2.1.5",
"@commercelayer/sdk": "4.17.0",
"@oclif/core": "^1.20.4",
"@oclif/plugin-autocomplete": "^1.3.6",
"@oclif/plugin-help": "5.1.19",
"@oclif/plugin-not-found": "^2.3.9",
"@oclif/plugin-plugins": "^2.1.7",
"configstore": "^5.0.1",
"inquirer": "^8.2.5",
"lodash": "^4.17.21",
"tslib": "^2.4.0",
"tslib": "^2.4.1",
"update-notifier": "^5.1.0"

@@ -128,5 +127,8 @@ },

"posttest": "eslint . --ext .ts --config .eslintrc",
"build": "rm -rf lib && tsc -b",
"test": "nyc --extension .ts mocha --forbid-only \"test/**/*.test.ts\"",
"readme": "cl-cli-dev readme --multi && git add README.md && git add docs/*"
"readme": "cl-cli-dev readme --multi && git add README.md && git add docs/*",
"lint": "eslint src --ext .ts --config .eslintrc",
"lint:fix": "eslint src --fix"
}
}

@@ -70,2 +70,3 @@ # Commerce Layer CLI

* [`commercelayer autocomplete`](docs/autocomplete.md) - Display autocomplete installation instructions.
* [`commercelayer cli`](docs/cli.md) - Core CLI commands.
* [`commercelayer help`](docs/help.md) - Display help for commercelayer.

@@ -72,0 +73,0 @@ * [`commercelayer plugins`](docs/plugins.md) - Manage CLI plugins.

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc