1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-11-25 22:12:29 +02:00
Files
OpenIntegrations/docs/en/md/SSH/Common-methods/Get-settings-via-agent.mdx

68 lines
1.7 KiB
Plaintext
Raw Normal View History

2025-09-23 10:13:09 +03:00
---
sidebar_position: 8
description: Get settings (via agent) and other functions to work with SSH in the Open Integration Package, a free open-source integration library for 1C:Enterprise 8, OneScript and CLI
keywords: [1C, 1С, 1С:Enterprise, 1С:Enterprise 8.3, API, Integration, Services, Exchange, OneScript, CLI, SSH]
---
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
# Get settings (via agent)
Gets connection settings with SSH Agent authentication
`Function GetSettingsViaAgent(Val Host, Val Port, Val Login) Export`
| Parameter | CLI option | Type | Required | Description |
|-|-|-|-|-|
| Host | --host | String | ✔ | SSH host |
| Port | --port | Number | ✔ | SSH port |
| Login | --user | String | ✔ | SSH username |
Returns: Structure Of KeyAndValue - Connection configuration
<br/>
2025-09-29 09:32:14 +03:00
```bsl title="1C:Enterprise/OneScript code example"
2025-09-30 20:25:53 +03:00
Host = "172.33.0.13";
Port = "2222";
Login = "bayselonarrend";
Result = OPI_SSH.GetSettingsViaAgent(Host, Port, Login);
2025-09-29 09:32:14 +03:00
```
2025-09-23 10:13:09 +03:00
2025-10-07 19:27:04 +03:00
<Tabs>
<TabItem value="bash" label="Bash" default>
```bash
oint ssh GetSettingsViaAgent \
--host "172.33.0.13" \
--port "2222" \
--user "bayselonarrend"
```
</TabItem>
<TabItem value="bat" label="CMD/Bat" default>
```batch
oint ssh GetSettingsViaAgent ^
--host "172.33.0.13" ^
--port "2222" ^
--user "bayselonarrend"
```
</TabItem>
</Tabs>
2025-09-23 10:13:09 +03:00
2025-10-07 19:27:04 +03:00
```json title="Result"
{
"auth_type": "agent",
"host": "172.33.0.13",
"port": 2222,
"username": "bayselonarrend"
}
```