1Create Connection

1Create Connection

Overview

This API creates a new Connection based on the provided JSON definition.

Method: POST

Request URL: {kyvos-url}/rest/v2/connections


Authorization

API Key: sessionid

This method authenticates requests using a session ID which acts like an API key.


BasicAuth: HTTP Authorization Scheme

This method authenticates requests using a username and password sent in the HTTP Authorization header.


Headers

Header Name

Type

Description

Possible Values

Header Name

Type

Description

Possible Values

Content-Type (Required)

String

Specifies media type of request body.

application/x-www-form-urlencoded

sessionid

String

The session ID is the token received from the login API.

Note: Session ID is required for token-based authentication.

–


Request Body

Parameter Name

Type

Description

Possible Values

Parameter Name

Type

Description

Possible Values

json (Required)

String

JSON definition of Connection which needs to be created.

Note: An example JSON definition is provided under the Resources section below.

–


Responses

200 Success

{ "code": 0, "message": "Connection added successfully." }

Status Code

Description

Status Code

Description

401

Authorization information is missing or invalid.

404

Connection, database, schema, or table not found.

412

Precondition failed. Required parameter missing.

500

Internal Server Error.


Resources

Below is an example of JSON structure which can be used as a reference for the json parameter in the request body.

{ "configuration":[ { "encrypted":"false", "name":"kyvos.connection.user", "value":"kyvos" }, { "encrypted":"false", "name":"kyvos.connection.version", "value":"" }, { "encrypted":"false", "name":"kyvos.connection.isEncryptedConnection", "value":"true" }, { "encrypted":"false", "name":"kyvos.connection.provider", "value":"GITLAB" }, { "encrypted":"true", "name":"kyvos.connection.password", "value":"Rw43Hf6KRjg4ZOFfkbTAkk7EZc/PBdmyX37d4QZ/a+g/2n6prTGDaVn6DDKb5TKsZqE7Z7hF5lxmvjK9SP7zuRdrb3n0jpJ1liSRe+Nbo9WfjdoccqV4I6jUkf6fSFT/dA==" }, { "encrypted":"false", "name":"kyvos.connection.properties.version", "value":"12" }, { "encrypted":"false", "name":"kyvos.connection.url", "value":"https://gitlab.intkyv.com/kyvos/kyvospushpullutility" }, { "encrypted":"false", "name":"kyvos.connection.name", "value":"TestConnection" }, { "encrypted":"false", "name":"kyvos.connection.authenticationtype", "value":"PAT" }, { "encrypted":"false", "name":"kyvos.connection.lastUpdateTimestamp", "value":"1778242779877" } ], "name":"TestConnection", "accessRights":"1" }

JSON Field Definitions

Field

Type

Description

Possible Values

Example

name

String

A unique name to identify your database connection. This name will be used to reference this connection in reports and other operations. Required

Any unique string without special characters

"MySalesDatabase"

accessRights

String

Permission level for users accessing this connection. Controls what users can do with this connection. Optional (defaults to "0")

"0" (Read Only), "1" (Read and Write), "-1" (Denied)

"0"

configuration

Array

List of connection properties that define how to connect to your database. Each property has a name, value, and encryption flag. Required

Array of property objects (see below)

[{...}]

configuration.name

String

The property name that identifies what this setting controls. These are predefined keys for different database types. Required 

"kyvos.connection.provider", "kyvos.connection.user", "kyvos.connection.password", "kyvos.connection.driver", "kyvos.connection.url", "kyvos.connection.isRead", "kyvos.connection.isEncryptedConnection", "kyvos.connection.version", "kyvos.connection.lastUpdateTimestamp", "kyvos.connection.name", "kyvos.connection.properties.version", "kyvos.connection.authenticationtype"

"kyvos.connection.provider"

configuration.value

String

The actual value for the property. For passwords, this will be encrypted. Required

Provider names: "AZURESQLDB", "MYSQL", "POSTGRES", "ORACLE", "SQLSERVER", "GITLAB", etc. Driver classes: "com.microsoft.sqlserver.jdbc.SQLServerDriver", etc.                                                              Database URLs, usernames, encrypted passwords, timestamps

"GITLAB"

configuration.encrypted

Boolean

Whether the property value should be encrypted for security. Used for passwords and sensitive data. Optional (defaults to "false")

"true" (encrypt value), "false" (plain text)

"true"

configuration.cryptography_algorithm

String

The encryption method to use when encrypted is true. Only needed for encrypted fields (only when encrypted=true).

"AES" or other supported algorithms

"AES"

Copyright Kyvos, Inc. 2026. All rights reserved.