1.1.3 • Published 9 months ago

@flowcore/cli-plugin-types v1.1.3

Weekly downloads
-
License
MIT
Repository
github
Last release
9 months ago

Flowcore CLI Plugin - Types

A plugin for generating types/interfaces from sampling an existing event stream

Version oclif Build and Release

Usage

$ npm install -g @flowcore/cli-plugin-types
$ types COMMAND
running command...
$ types (--version)
@flowcore/cli-plugin-types/2.13.0 darwin-arm64 node-v20.15.0
$ types --help [COMMAND]
USAGE
  $ types COMMAND
...

Commands

types types STREAM

Get json schema from event type

USAGE
  $ types types STREAM --directory <value> [--profile <value>] [--first <value>] [--last <value>] [--random
    <value>] [--all]

ARGUMENTS
  STREAM  stream url to connect to

FLAGS
  --all                Sample all events
  --directory=<value>  (required) Directory to write the types to
  --first=<value>      Sample from the first messages
  --last=<value>       Sample from the latest messages
  --profile=<value>    Specify the configuration profile to use
  --random=<value>     Sample a number of random events

DESCRIPTION
  Get json schema from event type

EXAMPLES
  $ types types "https://flowcore.io/<org>/<data core>/*" --last 10

  $ types types "https://flowcore.io/<org>/<data core>/*" --first 10

  $ types types "https://flowcore.io/<org>/<data core>/*" --random 10

  $ types types "https://flowcore.io/<org>/<data core>/*" --all

See code: src/commands/types.ts

types types typescript STREAM

Get typescript types from event type

USAGE
  $ types types typescript STREAM --directory <value> [--profile <value>] [--first <value>] [--last <value>] [--random
    <value>] [--all]

ARGUMENTS
  STREAM  stream url to connect to

FLAGS
  --all                Sample all events
  --directory=<value>  (required) Directory to write the types to
  --first=<value>      Sample from the first messages
  --last=<value>       Sample from the latest messages
  --profile=<value>    Specify the configuration profile to use
  --random=<value>     Sample a number of random events

DESCRIPTION
  Get typescript types from event type

EXAMPLES
  $ types types typescript "https://flowcore.io/<org>/<data core>/*" --last 10

  $ types types typescript "https://flowcore.io/<org>/<data core>/*" --first 10

  $ types types typescript "https://flowcore.io/<org>/<data core>/*" --random 10

  $ types types typescript "https://flowcore.io/<org>/<data core>/*" --all

See code: src/commands/types/typescript.ts