@8base/api-cli 中文文档教程
8base-api-cli
8base API 命令行界面 (CLI)
Table of Contents
- Installation
- Usage
- Commands
- auth:confirm
- auth:login
- auth:logout
- auth:sicolo
- auth:signup
- auth:whoami
- config
- config:get
- config:set
- schema:export
- schema:import
- tables:drop
- tables:fill
Installation
Globally
全局安装 CLI
$ yarn global add @8base/api-cli
现在您可以在任何地方使用以下命令运行
$ 8base-api-cli
Locally
CLI 将 CLI 本地安装到您的 node_modules
文件夹中
$ yarn add @8base/api-cli --dev
您应该能够运行 CLI 使用
$ node_modules/.bin/8base-api-cli
Usage
之前你应该设置API 端点
8base-api-cli config:set --name=url --value=https://api.8base.com
Usage: 8base-api-cli <command> [options]
Commands:
8base-api-cli auth:confirm Confirm with passed credentials.
8base-api-cli auth:login Login with passed credentials.
8base-api-cli auth:logout Logout and clear saved credentials.
8base-api-cli auth:sicolo Sign up, confirm and login with passed credentials.
8base-api-cli auth:signup Sign up with passed credentials.
8base-api-cli auth:whoami Display the current auth parameters.
8base-api-cli config Display a config.
8base-api-cli config:get Display a config value with passed name.
8base-api-cli config:set Set a config value with passed name.
8base-api-cli schema:export Export tables to the schema file.
8base-api-cli schema:import Import tables by passed schema file.
8base-api-cli tables:drop Drop all user tables.
8base-api-cli tables:fill Fill all user tables with mock data.
Options:
--help Show help [boolean]
--version Show version number [boolean]
Commands
auth:confirm
使用传递的凭据进行确认。
Options:
--email [string] [required]
--code [string] [required]
--password [string] [required]
--save [boolean] [default: true]
auth:login
使用传递的凭据登录。
Options:
--email [string] [required]
--password [string] [required]
--save [boolean] [default: true]
auth:logout
注销并清除保存的凭据。
auth:sicolo
使用传递的凭据注册、确认和登录。
Options:
--email [string] [required]
--password [string] [required]
--firstName [string] [default: "Ivan"]
--lastName [string] [default: "Ivanov"]
--organization [string] [default: "8base"]
--host [string] [default: "imap.yandex.ru"]
--save [boolean] [default: true]
auth:signup
使用传递的凭据注册。
Options:
--email [string] [required]
--password [string] [required]
--firstName [string] [default: "Ivan"]
--lastName [string] [default: "Ivanov"]
--organization [string] [default: "8base"]
auth:whoami
显示当前的授权参数。
config
显示配置。
config:get
显示具有传递名称的配置值。
Options:
--name [string] [required]
config:set
使用传递的名称设置配置值。
Options:
--name [string] [required]
--value [string] [required]
schema:export
将表导出到模式文件。
Options:
--file [string] [required] [default: "./EXPORT.json"]
schema:import
通过传递的模式文件导入表。
Options:
--file [string] [required] [default: "./IMPORT.json"]
tables:drop
删除所有用户表。
tables:fill
用模拟数据填充所有用户表。
8base-api-cli
The 8base API Command Line Interface (CLI)
Table of Contents
- Installation
- Usage
- Commands
- auth:confirm
- auth:login
- auth:logout
- auth:sicolo
- auth:signup
- auth:whoami
- config
- config:get
- config:set
- schema:export
- schema:import
- tables:drop
- tables:fill
Installation
Globally
Install CLI globally with
$ yarn global add @8base/api-cli
Now you can run CLI using following command anywhere
$ 8base-api-cli
Locally
Install CLI locally to your node_modules
folder with
$ yarn add @8base/api-cli --dev
You should be able to run CLI with
$ node_modules/.bin/8base-api-cli
Usage
Before usage you should set API endpoint
8base-api-cli config:set --name=url --value=https://api.8base.com
Usage: 8base-api-cli <command> [options]
Commands:
8base-api-cli auth:confirm Confirm with passed credentials.
8base-api-cli auth:login Login with passed credentials.
8base-api-cli auth:logout Logout and clear saved credentials.
8base-api-cli auth:sicolo Sign up, confirm and login with passed credentials.
8base-api-cli auth:signup Sign up with passed credentials.
8base-api-cli auth:whoami Display the current auth parameters.
8base-api-cli config Display a config.
8base-api-cli config:get Display a config value with passed name.
8base-api-cli config:set Set a config value with passed name.
8base-api-cli schema:export Export tables to the schema file.
8base-api-cli schema:import Import tables by passed schema file.
8base-api-cli tables:drop Drop all user tables.
8base-api-cli tables:fill Fill all user tables with mock data.
Options:
--help Show help [boolean]
--version Show version number [boolean]
Commands
auth:confirm
Confirm with passed credentials.
Options:
--email [string] [required]
--code [string] [required]
--password [string] [required]
--save [boolean] [default: true]
auth:login
Login with passed credentials.
Options:
--email [string] [required]
--password [string] [required]
--save [boolean] [default: true]
auth:logout
Logout and clear saved credentials.
auth:sicolo
Sign up, confirm and login with passed credentials.
Options:
--email [string] [required]
--password [string] [required]
--firstName [string] [default: "Ivan"]
--lastName [string] [default: "Ivanov"]
--organization [string] [default: "8base"]
--host [string] [default: "imap.yandex.ru"]
--save [boolean] [default: true]
auth:signup
Sign up with passed credentials.
Options:
--email [string] [required]
--password [string] [required]
--firstName [string] [default: "Ivan"]
--lastName [string] [default: "Ivanov"]
--organization [string] [default: "8base"]
auth:whoami
Display the current auth parameters.
config
Display a config.
config:get
Display a config value with passed name.
Options:
--name [string] [required]
config:set
Set a config value with passed name.
Options:
--name [string] [required]
--value [string] [required]
schema:export
Export tables to the schema file.
Options:
--file [string] [required] [default: "./EXPORT.json"]
schema:import
Import tables by passed schema file.
Options:
--file [string] [required] [default: "./IMPORT.json"]
tables:drop
Drop all user tables.
tables:fill
Fill all user tables with mock data.
你可能也喜欢
- 23mofang-react-native-autoheight-webview 中文文档教程
- 6vd-xiaofeng-ggm 中文文档教程
- @10stars/styleguide-ts 中文文档教程
- @17media/eslint-config-17media 中文文档教程
- @1hive/contract-helpers-test 中文文档教程
- @1mmunity/discord-bot-base 中文文档教程
- @2030/eslint-config-typescript 中文文档教程
- @2bit/types-osc-min 中文文档教程
- @36node-fcp/ecs-api-sdk-js 中文文档教程
- @3asoft/web-crypto-ts 中文文档教程