1.0.7 • Published 3 years ago

pxc-cli v1.0.7

Weekly downloads
8
License
ISC
Repository
-
Last release
3 years ago

pxc-cli

Overview

This repository centralizes scripts to do repetitive tasks using pxc-api. See npm page: https://www.npmjs.com/package/pxc-cli

Install

npm i -g pxc-cli 

Run

pxc-cli
or
npm run start

Install (for development purpose)

git clone git@gitlab.com:proxyclick/flow/js-libs/cli.git
cd cli
npm install
npm run build
npm link

Hint for development

Just extend the Script abstract class and provide script description, name and arguments definitions through constructor. Override the 'execute' method. Feel free to inspire from one of the existing implementation in 'src/scripts/impl'. The documentation is automatically generated (a pre-commit hook is set up) via the args definition you provide in your script.

Do not forget to bump package version and publish it (npm publish) once you're done (so that everyone could enjoy your modifications).

Scripts documentation :

The following documentation has been generated automatically.

copy-rr-settings

Copy remote registration settings from one location to a list of locations.

pxc-cli copy-rr-settings [<args>]  
or  
pxc-cli copy-rr-settings -f path-to-config.json  

Options

ArgumentAliasTypeDescription
originostringThe origin company id to copy settings from
destinationsdstring[]The destination (company ids) for the settings to be copied to
configFilefstringOptional - The json file to get these options from (instead of using command args)
baseUrlbstringThe Proyclick API base url (ex: https://api.proxyclick-local.com)
clientIdistringThe Proyclick API client id
clientSecretsstringThe Proyclick API client secret
helphbooleanOptional - Prints this usage guide

user-info

Get a user information.

pxc-cli user-info [<args>]  
or  
pxc-cli user-info -f path-to-config.json  

Options

ArgumentAliasTypeDescription
companyIdcstringThe company id of the user
userIdustringThe user id
configFilefstringOptional - The json file to get these options from (instead of using command args)
baseUrlbstringThe Proyclick API base url (ex: https://api.proxyclick-local.com)
clientIdistringThe Proyclick API client id
clientSecretsstringThe Proyclick API client secret
helphbooleanOptional - Prints this usage guide