Skip to content

Importing Schemas

Instead of defining a manifest and its entities manually, Negroni can generate them by importing an external schema. This is useful when migrating existing data models or bootstrapping a manifest from an API specification or database.

Import Methods

Method Source
CDM Manifest A CDM-format JSON manifest file
Database Schema A live connection to an existing database
OpenAPI 3.0 An OpenAPI 3.0 specification file
Swagger 2.0 A Swagger 2.0 specification file
Postman Collection A Postman collection export file

Access all import options from the toolbar by clicking Import Import or via the manifest Navigator's right-click context menu.


Importing a CDM Manifest

  1. Click Import Import on the toolbar and select CDM Manifest.
  2. Upload or paste the CDM manifest JSON file.
  3. Review the entities and manifest details detected from the file.
  4. Click Import to create the manifest and its entities.

Importing from a Database Schema

  1. Click Import Import on the toolbar and select Database Schema.
  2. On the next step, choose one of two methods:

Connect to Database

Use this option to discover schemas directly from a live database connection.

Supported database types:

  • PostgreSQL
  • MySQL
  • Cassandra
  • MongoDB

Steps:

  1. Select the Connect to Database tab.
  2. Choose the Connection Type and enter the connection details:
  3. Host, port, database name, username, and password
  4. For Cassandra: Keyspace and Contact Points
  5. Optionally, provide a Connection String to override host/port/database
  6. Click Test Connection to verify the connection before proceeding.
  7. Click Next. Negroni reads the database schema and displays the available schemas.
  8. Select the schemas to import as entities.
  9. Click Import to generate a manifest.

Import Schema

Use this option to import a database schema from a file previously exported by Negroni (for example, a generated database schema export).

Supported file types: .zip, .sql

Steps:

  1. Select the Import Schema tab.
  2. Upload or drag and drop a .zip or .sql schema file.
  3. Click Import to generate a manifest.

Importing from an OpenAPI 3.0 Specification

  1. Click Import Import on the toolbar and select OpenAPI Schema.
  2. Upload or paste the OpenAPI 3.0 specification.
  3. Click Import.

Importing from a Swagger 2.0 Specification

  1. Click Import Import on the toolbar and select Swagger Schema.
  2. Upload or paste the Swagger 2.0 specification.
  3. Click Import.

Importing from a Postman Collection

  1. Click Import Import on the toolbar and select Postman Collection.
  2. Upload the collection JSON.
  3. Click Import.

After Importing

  • Add/modify entities
  • Configure build settings
  • Export as Martini package / CDM schema / database schema