# regen-api

## Description

* Regenerate an existing API located in the current working directory, following a Swagger schema update

## Syntax

`ern regen-api`

**Options**

`--skipVersion/-s`

* Skip the step to update api version and publish to npm.

`--bridgeVersion/-b`

* Specify version of the [Electrode Native Bridge](https://github.com/electrode-io/react-native-electrode-bridge/releases) to use.
* Target `--bridgeVersion` can be found using `yarn info react-native-electrode-bridge versions`

## Remarks

* This command is used for example, if you add new requests, events, or models to the schema and you want to regenerate the existing API based on this schema update and publish a new version of it.
* This command must be executed from within the root directory of an API project that was initially created using the `ern create-api` command.

## Related commands

[ern create-api](/cli-commands/create-api.md) | Create a new API project based on a Swagger schema\
[ern create-api-impl](/cli-commands/create-api-impl.md) | Create an implementation skeleton project for a specified API


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://native.electrode.io/cli-commands/regen-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
