Socket
Book a DemoInstallSign in
Socket

@apimatic/cli

Package Overview
Dependencies
Maintainers
5
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@apimatic/cli

The official CLI for APIMatic.

1.1.0-alpha.21
alpha
latest
Source
npmnpm
Version published
Weekly downloads
22
-76.34%
Maintainers
5
Weekly downloads
 
Created
Source

@apimatic/cli

apimatic is in Alpha.

The official CLI for APIMatic.

oclif Version Downloads/week License

Getting Started

To get started with APIMatic's CLI using a step by step wizard, run the following command:

$ apimatic portal:quickstart

Usage

$ npm install -g @apimatic/cli
$ apimatic COMMAND
running command...
$ apimatic (--version)
@apimatic/cli/1.1.0-alpha.21 win32-x64 node-v23.4.0
$ apimatic --help [COMMAND]
USAGE
  $ apimatic COMMAND
...

Commands

apimatic api:transform

Transform API specifications from one format to another. Supports 10+ different formats including OpenApi/Swagger, RAML, WSDL and Postman Collections.

USAGE
  $ apimatic api:transform --format <value> [--file <value>] [--url <value>] [-d <value>] [-f] [-k <value>]

FLAGS
  -d, --destination=<value>  [default: ./] directory to download transformed file to
  -f, --force                overwrite changes without asking for user consent.
  -k, --auth-key=<value>     override current authentication state with an authentication key.
      --file=<value>         path to the API specification file to transform
      --format=<value>       (required) specification format to transform API specification into
                             APIMATIC|WADL2009|WSDL|SWAGGER10|SWAGGER20|SWAGGERYAML|OAS3|OPENAPI3YAML|APIBLUEPRINT|RAML|
                             RAML10|POSTMAN10|POSTMAN20|GRAPHQLSCHEMA
      --url=<value>          URL to the API specification file to transform. Can be used in place of the --file option
                             if the API specification is publicly available.

DESCRIPTION
  Transform API specifications from one format to another. Supports [10+ different
  formats](https://www.apimatic.io/transformer/#supported-formats) including OpenApi/Swagger, RAML, WSDL and Postman
  Collections.

EXAMPLES
  $ apimatic api:transform --format=OPENAPI3YAML --file="./specs/sample.json" --destination="D:/"

  $ apimatic api:transform --format=RAML --url="https://petstore.swagger.io/v2/swagger.json"  --destination="D:/"

See code: src/commands/api/transform.ts

apimatic api:validate

Validate the syntactic and semantic correctness of an API specification

USAGE
  $ apimatic api:validate [--file <value>] [--url <value>] [-k <value>]

FLAGS
  -k, --auth-key=<value>  override current authentication state with an authentication key.
      --file=<value>      Path to the API specification file to validate
      --url=<value>       URL to the specification file to validate. Can be used in place of the --file option if the
                          API specification is publicly available.

DESCRIPTION
  Validate the syntactic and semantic correctness of an API specification

EXAMPLES
  $ apimatic api:validate --file="./specs/sample.json"

  $ apimatic api:validate --url=https://petstore.swagger.io/v2/swagger.json

See code: src/commands/api/validate.ts

apimatic auth:login

Login using your APIMatic credentials or an API Key

USAGE
  $ apimatic auth:login [-k <value>]

FLAGS
  -k, --auth-key=<value>  Sets authentication key for all commands.

DESCRIPTION
  Login using your APIMatic credentials or an API Key

EXAMPLES
  $ apimatic auth:login

  $ apimatic auth:login --auth-key={api-key}

See code: src/commands/auth/login.ts

apimatic auth:logout

Clears the local login credentials.

USAGE
  $ apimatic auth:logout

DESCRIPTION
  Clears the local login credentials.

EXAMPLES
  $ apimatic auth:logout

See code: src/commands/auth/logout.ts

apimatic auth:status

View the currently logged in user.

USAGE
  $ apimatic auth:status

DESCRIPTION
  View the currently logged in user.

EXAMPLES
  $ apimatic auth:status

See code: src/commands/auth/status.ts

apimatic autocomplete [SHELL]

Display autocomplete installation instructions.

USAGE
  $ apimatic autocomplete [SHELL] [-r]

ARGUMENTS
  SHELL  (zsh|bash|powershell) Shell type

FLAGS
  -r, --refresh-cache  Refresh cache (ignores displaying instructions)

DESCRIPTION
  Display autocomplete installation instructions.

EXAMPLES
  $ apimatic autocomplete

  $ apimatic autocomplete bash

  $ apimatic autocomplete zsh

  $ apimatic autocomplete powershell

  $ apimatic autocomplete --refresh-cache

See code: @oclif/plugin-autocomplete

apimatic help [COMMAND]

Display help for apimatic.

USAGE
  $ apimatic help [COMMAND...] [-n]

ARGUMENTS
  COMMAND...  Command to show help for.

FLAGS
  -n, --nested-commands  Include all nested commands in the output.

DESCRIPTION
  Display help for apimatic.

See code: @oclif/plugin-help

apimatic portal:copilot

Configure API Copilot for your API Documentation portal

USAGE
  $ apimatic portal:copilot [-i <value>] [--disable] [-f] [-k <value>]

FLAGS
  -f, --force             overwrite changes without asking for user consent.
  -i, --input=<value>     [default: ./] path to the parent directory containing the 'src' directory, which includes API
                          specifications and configuration files.
  -k, --auth-key=<value>  override current authentication state with an authentication key.
      --disable           marks the API Copilot as disabled in the configuration

DESCRIPTION
  Configure API Copilot for your API Documentation portal

  Displays available API Copilots associated with your account and allows you to select which one to integrate with your
  portal. Each APIMatic account includes one Copilot by default. The selected Copilot will be added to your
  APIMATIC-BUILD.json file

EXAMPLES
  $ apimatic portal:copilot --input="./"

  $ apimatic portal:copilot --input="./" --disable

See code: src/commands/portal/copilot.ts

apimatic portal:generate

Generate an API Documentation portal. Requires an input directory containing API specifications, a config file and optionally, markdown guides. For details, refer to the documentation

USAGE
  $ apimatic portal:generate [-i <value>] [-d <value>] [-f] [--zip] [-k <value>]

FLAGS
  -d, --destination=<value>  [default: <input>/portal] path where the portal will be generated.
  -f, --force                overwrite changes without asking for user consent.
  -i, --input=<value>        [default: ./] path to the parent directory containing the 'src' directory, which includes
                             API specifications and configuration files.
  -k, --auth-key=<value>     override current authentication state with an authentication key.
      --zip                  download the generated portal as a .zip archive

DESCRIPTION
  Generate an API Documentation portal. Requires an input directory containing API specifications, a config file and
  optionally, markdown guides. For details, refer to the [documentation](https://docs.apimatic.io/platform-api/#/http/gu
  ides/generating-on-prem-api-portal/build-file-reference)

EXAMPLES
  $ apimatic portal:generate

  $ apimatic portal:generate --input="./" --destination="./portal"

See code: src/commands/portal/generate.ts

apimatic portal:quickstart

Create your first API Portal using APIMatic's Docs as Code offering.

USAGE
  $ apimatic portal:quickstart

DESCRIPTION
  Create your first API Portal using APIMatic's Docs as Code offering.

EXAMPLES
  $ apimatic portal:quickstart

See code: src/commands/portal/quickstart.ts

apimatic portal:recipe:new

Add an API Recipe to your API Documentation portal.

USAGE
  $ apimatic portal:recipe:new [--name <value>] [-i <value>]

FLAGS
  -i, --input=<value>  [default: ./] path to the parent directory containing the 'src' directory, which includes API
                       specifications and configuration files.
      --name=<value>   name for the recipe

DESCRIPTION
  Add an API Recipe to your API Documentation portal.

  To learn more about API Recipes, visit:
  https://docs.apimatic.io/platform-api/#/http/guides/generating-on-prem-api-portal/api-recipes

EXAMPLES
  $ apimatic portal:recipe:new

  $ apimatic portal:recipe:new --name="My API Recipe" --input="./"

See code: src/commands/portal/recipe/new.ts

apimatic portal:serve

Generate and deploy a Docs as Code portal with hot reload.

USAGE
  $ apimatic portal:serve [-p <value>] [-i <value>] [-d <value>] [-o] [--no-reload] [-k <value>]

FLAGS
  -d, --destination=<value>  [default: <input>/portal] path where the portal will be generated.
  -i, --input=<value>        [default: ./] path to the parent directory containing the 'src' directory, which includes
                             API specifications and configuration files.
  -k, --auth-key=<value>     override current authentication state with an authentication key.
  -o, --open                 Open the portal in the default browser.
  -p, --port=<value>         [default: 3000] port to serve the portal.
      --no-reload            Disable hot reload.

DESCRIPTION
  Generate and deploy a Docs as Code portal with hot reload.

EXAMPLES
  $ apimatic portal:serve

  $ apimatic portal:serve --input="./" --destination="./portal" --port=3000 --open --no-reload

See code: src/commands/portal/serve.ts

apimatic portal:toc:new

Generate a Table of Contents (TOC) file for your API documentation portal

USAGE
  $ apimatic portal:toc:new [-d <value>] [-i <value>] [-f] [--expand-endpoints] [--expand-models]

FLAGS
  -d, --destination=<value>  [default: <input>/src/content] path where the 'toc.yml' will be generated.
  -f, --force                overwrite changes without asking for user consent.
  -i, --input=<value>        [default: ./] path to the parent directory containing the 'src' directory, which includes
                             API specifications and configuration files.
      --expand-endpoints     include individual entries for each endpoint in the generated 'toc.yml'. Requires a valid
                             API specification in the working directory.
      --expand-models        include individual entries for each model in the generated 'toc.yml'. Requires a valid API
                             specification in the working directory.

DESCRIPTION
  Generate a Table of Contents (TOC) file for your API documentation portal

  This command generates a new Table of Contents (TOC) file used in the
  generation of your API documentation portal.

  The output is a YAML file with the .yml extension.

  To learn more about the TOC file and APIMatic build directory structure, visit:
  https://docs.apimatic.io/platform-api/#/http/guides/generating-on-prem-api-portal/overview-generating-api-portal

EXAMPLES
  $ apimatic portal:toc:new --destination="./src/content/"

  $ apimatic portal:toc:new --input="./"

  $ apimatic portal:toc:new --input="./" --destination="./src/content/"

See code: src/commands/portal/toc/new.ts

apimatic sdk:generate

Generate an SDK for your API

USAGE
  $ apimatic sdk:generate --platform csharp|java|php|python|ruby|typescript|go [--spec <value>] [-d <value>] [-f]
    [--zip] [-k <value>]

FLAGS
  -d, --destination=<value>  [default: ./sdk/<platform>] path where the sdk will be generated.
  -f, --force                overwrite changes without asking for user consent.
  -k, --auth-key=<value>     override current authentication state with an authentication key.
      --platform=<option>    (required) language platform for sdk
                             <options: csharp|java|php|python|ruby|typescript|go>
      --spec=<value>         [default: ./src/spec] path to the folder containing the API specification file.
      --zip                  download the generated SDK as a .zip archive

DESCRIPTION
  Generate an SDK for your API

EXAMPLES
  $ apimatic sdk:generate --platform=java

  $ apimatic sdk:generate --platform=csharp --spec="./src/spec"

See code: src/commands/sdk/generate.ts

Keywords

apimatic

FAQs

Package last updated on 18 Aug 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.