Skip to main content

flagsmith-cli Python Implementation.

Project description

py-flagsmith-cli

PyPI version License Static Badge PyPI - Downloads

flagsmith-cli Python Implementation.

Homepage: https://github.com/belingud/py-flagsmith-cli

You can install with pip:

pip install py-flagsmith-cli

Recommand use pipx:

pipx install py-flagsmith-cli

And use in cmd:

pysmith -h

 Usage: pysmith [OPTIONS] COMMAND [ARGS]...

╭─ Options ────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --install-completion            Install completion for the current shell.                                    │
│ --show-completion               Show completion for the current shell, to copy it or customize the           │
│                                 installation.                                                                │
│ --help                -h        Show this message and exit.                                                  │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ───────────────────────────────────────────────────────────────────────────────────────────────────╮
│ get       Retrieve flagsmith features from the Flagsmith API and output them to file.                        │
│ showenv   Show the current flagsmith environment setup. Including environment id and api host.               │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Include two commands get and showenv.

pysmith get

pysmith get -h

 Usage: pysmith get [OPTIONS] [ENVIRONMENT]

 Retrieve flagsmith features from the Flagsmith API and output them to file.

 EXAMPLES
 $ pysmith get <ENVIRONMENT_API_KEY>

 $ FLAGSMITH_ENVIRONMENT=x pysmith get

 $ pysmith get <environment>

 $ pysmith get -o ./my-file.json

 $ pysmith get -a https://flagsmith.example.com/api/v1/

 $ pysmith get -i flagsmith_identity

 $ pysmith get -np

╭─ Arguments ──────────────────────────────────────────────────────────────────────────────────────────────────╮
│   environment      [ENVIRONMENT]  The flagsmith environment key to use, defaults to the environment variable │
│                                   FLAGSMITH_ENVIRONMENT                                                      │
│                                   [env var: FLAGSMITH_ENVIRONMENT]                                           │
│                                   [default: None]                                                            │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --output     -o       <text>  The file path output [default: None]                                           │
│ --api        -a       <text>  The API URL to fetch the feature flags from                                    │
│                               [default: https://edge.api.flagsmith.com/api/v1/]                              │
│ --identity   -i       <text>  The identity for which to fetch feature flags [default: None]                  │
│ --no-pretty  -np      <flag>  Do not prettify the output JSON                                                │
│ --entity     -e       <text>  The entity to fetch, this will either be the flags or an environment document  │
│                               used for Local Evaluation Mode. Refer to                                       │
│                               https://docs.flagsmith.com/clients/server-side.                                │
│                               [default: flags]                                                               │
│ --help       -h               Show this message and exit.                                                    │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

pysmith showenv

pysmith showenv -h

 Usage: pysmith showenv [OPTIONS]

 Show the current flagsmith environment setup. Including environment id and api host.

 EXAMPLES:

 $ pysmith showenv
 Current flagsmith env setup>>>
 flagsmith environment ID: <environment-id>
 flagsmith host: <api-host>

╭─ Options ────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --help  -h        Show this message and exit.                                                                │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Refer to:

  1. https://docs.flagsmith.com/clients/CLI
  2. https://github.com/Flagsmith/flagsmith-cli

License

FOSSA Status

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

py_flagsmith_cli-1.0.2.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

py_flagsmith_cli-1.0.2-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file py_flagsmith_cli-1.0.2.tar.gz.

File metadata

  • Download URL: py_flagsmith_cli-1.0.2.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.15.4 CPython/3.12.3 Darwin/23.5.0

File hashes

Hashes for py_flagsmith_cli-1.0.2.tar.gz
Algorithm Hash digest
SHA256 f87c4c63ad0517ef088abb60e16d4a17a9e396c1351610b8b5d099a08d25b222
MD5 9068a50b5eabc26191fc1847bbfd45f8
BLAKE2b-256 5a467cf4fb5922dfa15e22b64b5b607115e0a8df3ee901d68558db5af0e71190

See more details on using hashes here.

File details

Details for the file py_flagsmith_cli-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for py_flagsmith_cli-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 86e185d9a8e3970efb1bb88d69654105bbd4324c3900900bd2433667726a92d8
MD5 717b2ef0fa46c337662368c6c6aad840
BLAKE2b-256 f9955e8a9266bf8a88b5cb82e808c3cc53733284b011e92887899308eca45e7f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page