General Information
Connection Type
UI Documentation
Endpoints
List Connections
Get Connection
Create Connection
Update Connection
Delete Connection
List Connections
Endpoint
Request
Headers
| Header | Value |
|---|---|
| Authorization | Bearer |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
type query parameter is required to filter connections by type.
cURL Example
Get Connection
Endpoint
Request
Headers
| Header | Value |
|---|---|
| Authorization | Bearer |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
| connectionName | string | Yes | Connection name |
Response
Success Response (200 OK)
cURL Example
Create Connection
Endpoint
Request
Headers
| Header | Value |
|---|---|
| Authorization | Bearer |
| Content-Type | application/json |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
| connectionName | string | Yes | Connection name |
Request Body
Full JSON Body Example - Basic SSH Connection
Full JSON Body Example - Custom SSH Port
Request Body Fields
Common Fields
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| type | string | Yes | - | Connection type discriminator field. Identifies the connection type in API requests/responses. |
| name | string | Yes | - | Connection name (must match path parameter) |
| description | string | No | - | Connection description |
| deployToWorker | boolean | No | true | Whether to deploy to worker |
| enabled | boolean | No | true | Whether connection is enabled |
Linux Script-Specific Fields
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| hostName | string | Yes | - | Linux server hostname or IP address |
| sshPort | integer | No | 22 | SSH port number (default: 22) |
| username | string | Yes | - | SSH username |
| password | string | Yes | - | SSH password (secret field) |
Notes
hostName,username, andpasswordare required.sshPortdefaults to 22 (standard SSH port).- Connection uses SSH protocol for secure remote script execution.
- Password is stored securely and masked in responses.
Response
Success Response (200 OK)
cURL Example
Update Connection
Endpoint
Request
Headers
| Header | Value |
|---|---|
| Authorization | Bearer |
| Content-Type | application/json |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
| connectionName | string | Yes | Connection name (must match name in body) |
Request Body
Full JSON Body Example
Response
Success Response (200 OK)
Delete Connection
Endpoint
Request
Headers
| Header | Value |
|---|---|
| Authorization | Bearer |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
| connectionName | string | Yes | Connection name |
Response
Success Response (200 OK)
Notes and Warnings
-
SSH Protocol:
- Connection uses SSH (Secure Shell) protocol for secure remote access
- Standard SSH port is 22
- Supports password-based authentication
-
Hostname:
hostNamecan be a hostname or IP address- Ensure hostname resolves correctly or use IP address
-
Port:
sshPortdefaults to 22 (standard SSH port)- Use custom port if SSH server is configured on non-standard port
-
Authentication:
usernameandpasswordare required- Password is stored securely and masked in responses
- Consider using SSH key-based authentication (if supported)
-
Security:
- Use strong passwords
- Ensure SSH server is properly secured
- Consider using non-standard ports for additional security
- Use firewall rules to restrict SSH access
-
Script Execution:
- Scripts are executed on the remote Linux server
- Ensure user has necessary permissions to execute scripts
- Scripts run with the privileges of the specified user
-
Network:
- Ensure network connectivity between Apinizer worker and Linux server
- Firewall rules must allow SSH connections
- Consider VPN or private network for production
-
Performance:
- SSH connections have overhead
- Script execution time depends on script complexity and server performance
- Consider timeout settings for long-running scripts
-
Deployment: Connection changes require deployment to take effect. Set
deployToWorker: trueor deploy manually.
Related Documentation
- List Connections - List all connections
- Get Connection - Get a specific connection
- Create Connection - General connection creation guide
- Update Connection - General connection update guide
- Delete Connection - General connection deletion guide

