pldpro_sdk.api_client.NodesApi
All URIs are relative to /v1
| Method | HTTP request | Description |
|---|---|---|
| check_auth_node_health | GET /nodes/auth/{uuid}/health | Verifica a saúde e conectividade de um AuthNode |
| create_auth_node_for_node | POST /nodes/{uuid}/auth | Cria um novo AuthNode para um node |
| create_auth_node_pub_key | POST /nodes/{uuid}/auth/pub-key | Cria/registra a chave pública de um AuthNode e faz o download do arquivo ZIP |
| create_node | POST /nodes | Cria um novo node |
| delete_auth_node | DELETE /nodes/auth/{uuid} | Remove um AuthNode e suas credenciais associadas |
| delete_node | DELETE /nodes/{uuid} | Remove um node do sistema |
| download_auth_node_user_public_key | GET /nodes/{node}/auth/{usuario}/pub-key | Faz o download da chave pública do usuário em um node |
| get_all_nodes | GET /nodes | Lista todos os nodes |
| get_auth_node | GET /nodes/auth/{uuid} | Obtém os detalhes de um AuthNode |
| get_auth_node_for_user_in_node | GET /nodes/{uuid}/auth/from-user | Recupera as credenciais (AuthNode) de um usuário em um node |
| get_auth_node_public_key | GET /nodes/auth/{uuid}/pub-key | Obtém a chave pública SSH do AuthNode |
| get_casos_node | GET /nodes/{uuid}/casos | Lista os casos associados a um node |
| get_node | GET /nodes/{uuid} | Obtém os detalhes de um node |
| get_node_from_name | GET /nodes/from-name | Retorna um Node |
| get_versoes_container | GET /nodes/auth/{uuid}/versions | Lista as versões disponíveis do PLDPro para um AuthNode |
| list_auth_nodes_by_node | GET /nodes/{uuid}/auth | Lista as credenciais (AuthNodes) associadas a um node |
| update_auth_node_credentials | PUT /nodes/auth/{uuid}/credentials | Atualiza as credenciais (senha) do AuthNode e recria as chaves |
check_auth_node_health
HostCheckResult check_auth_node_health(uuid)
Verifica a saúde e conectividade de um AuthNode
Realiza uma verificação de integridade das credenciais remotas associadas ao AuthNode identificado pelo UUID.
O retorno inclui o status atual, se o registro existe no banco, se há chaves SSH configuradas, se a conexão foi bem-sucedida e uma mensagem descritiva.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.host_check_result import HostCheckResult
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do AuthNode a ser verificado
try:
# Verifica a saúde e conectividade de um AuthNode
api_response = api_instance.check_auth_node_health(uuid)
print("The response of NodesApi->check_auth_node_health:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->check_auth_node_health: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do AuthNode a ser verificado |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Resultado da verificação de saúde do AuthNode/node remoto. | - |
| 404 | AuthNode não encontrado. | - |
| 400 | Erro ao verificar o estado do AuthNode/node remoto. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
create_auth_node_for_node
AuthNodeResponse create_auth_node_for_node(uuid, auth_node_request)
Cria um novo AuthNode para um node
Registra um novo AuthNode (credenciais de acesso remoto) para o node identificado pelo UUID no caminho.
O campo uuidNode do corpo da requisição é inferido a partir do parâmetro de caminho {uuid}.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.auth_node_request import AuthNodeRequest
from pldpro_sdk.api_client.models.auth_node_response import AuthNodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do node para o qual o AuthNode será criado.
auth_node_request = {usuario=usuario_remoto, workdir=/home/usuario_remoto/pldpro, password=SenhaSsh@2025, uuidNode=00000000-0000-0000-0000-000000000000} # AuthNodeRequest |
try:
# Cria um novo AuthNode para um node
api_response = api_instance.create_auth_node_for_node(uuid, auth_node_request)
print("The response of NodesApi->create_auth_node_for_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->create_auth_node_for_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do node para o qual o AuthNode será criado. | |
| auth_node_request | AuthNodeRequest |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | AuthNode criado com sucesso para o node informado. | - |
| 404 | Node não encontrado para o UUID informado. | - |
| 400 | Erro de validação ao criar o AuthNode (dados inválidos ou incompletos). | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
create_auth_node_pub_key
bytes create_auth_node_pub_key(uuid, auth_node_request_pub_key)
Cria/registra a chave pública de um AuthNode e faz o download do arquivo ZIP
Cria a chave pública associada a um AuthNode para o Node identificado pelo uuid,
sem necessidade de conexão direta com o servidor no momento da operação.
Após o processamento, o endpoint retorna um arquivo .zip para download contendo a chave pública gerada/associada.
O corpo da resposta é binário (application/zip) e o nome do arquivo é informado no header
Content-Disposition.
Além disso, o header Info contém os dados do AuthNodeResponse retornado pela operação,
serializado como string.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.auth_node_request_pub_key import AuthNodeRequestPubKey
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('550e8400-e29b-41d4-a716-446655440000') # UUID | UUID do Node ao qual o AuthNode será associado.
auth_node_request_pub_key = {usuario=xlibs, workdir=/home/usuario_remoto/pldpro} # AuthNodeRequestPubKey |
try:
# Cria/registra a chave pública de um AuthNode e faz o download do arquivo ZIP
api_response = api_instance.create_auth_node_pub_key(uuid, auth_node_request_pub_key)
print("The response of NodesApi->create_auth_node_pub_key:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->create_auth_node_pub_key: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | UUID do Node ao qual o AuthNode será associado. | |
| auth_node_request_pub_key | AuthNodeRequestPubKey |
Return type
bytes
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/zip, application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Arquivo ZIP contendo a chave pública SSH gerada ou registrada para o AuthNode. | * Content-Disposition - Define o nome do arquivo de saída para download. * Cache-Control - Indica que a resposta não deve ser armazenada em cache. * Pragma - Header complementar para desabilitar cache. * Expires - Define expiração imediata da resposta. * Info - Informações do AuthNode retornado pela operação, serializadas como string no header. Como se trata de header HTTP, não há garantia de estrutura JSON. * Content-Length - Tamanho, em bytes, do arquivo ZIP retornado. |
| 400 | Erro de validação da requisição ou falha ao criar/registrar a chave pública. | - |
| 404 | Node não encontrado para o UUID informado. | - |
| 500 | Erro interno ao processar a geração, associação ou download do arquivo ZIP. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
create_node
NodeResponse create_node(node_request)
Cria um novo node
Registra um novo node no sistema.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.node_request import NodeRequest
from pldpro_sdk.api_client.models.node_response import NodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
node_request = pldpro_sdk.api_client.NodeRequest() # NodeRequest |
try:
# Cria um novo node
api_response = api_instance.create_node(node_request)
print("The response of NodesApi->create_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->create_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| node_request | NodeRequest |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Node criado com sucesso. | - |
| 400 | Erro ao criar node | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete_auth_node
delete_auth_node(uuid)
Remove um AuthNode e suas credenciais associadas
Remove o AuthNode identificado pelo UUID informado, bem como as chaves SSH associadas ao usuário remoto para o node correspondente.
A operação não retorna corpo de resposta — apenas o status HTTP 204 No Content em caso de sucesso.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do AuthNode a ser removido.
try:
# Remove um AuthNode e suas credenciais associadas
api_instance.delete_auth_node(uuid)
except Exception as e:
print("Exception when calling NodesApi->delete_auth_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do AuthNode a ser removido. |
Return type
void (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 204 | AuthNode removido com sucesso (nenhum conteúdo retornado). | - |
| 404 | AuthNode não encontrado para o UUID informado. | - |
| 400 | Erro ao remover o AuthNode. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete_node
delete_node(uuid)
Remove um node do sistema
Desregistra o node identificado pelo UUID informado, removendo suas credenciais e informações
associadas do banco de dados.
A operação não retorna corpo de resposta — apenas o status HTTP 204 No Content em caso de sucesso.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do node a ser removido
try:
# Remove um node do sistema
api_instance.delete_node(uuid)
except Exception as e:
print("Exception when calling NodesApi->delete_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do node a ser removido |
Return type
void (empty response body)
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 204 | Node removido com sucesso (nenhum conteúdo retornado). | - |
| 404 | Node não encontrado. | - |
| 400 | Erro ao remover o node. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
download_auth_node_user_public_key
bytes download_auth_node_user_public_key(node, usuario)
Faz o download da chave pública do usuário em um node
Gera e baixa um arquivo .zip contendo a chave pública SSH (.pub) do usuário informado no node informado.
O retorno é um binário (application/zip) para download via header Content-Disposition.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
node = 'datacenter_cepel' # str | Nome do node onde a chave pública do usuário será obtida.
usuario = 'xlibs' # str | Nome do usuário remoto associado à chave pública.
try:
# Faz o download da chave pública do usuário em um node
api_response = api_instance.download_auth_node_user_public_key(node, usuario)
print("The response of NodesApi->download_auth_node_user_public_key:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->download_auth_node_user_public_key: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| node | str | Nome do node onde a chave pública do usuário será obtida. | |
| usuario | str | Nome do usuário remoto associado à chave pública. |
Return type
bytes
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/zip, application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Arquivo ZIP contendo a chave pública SSH solicitada. | * Content-Disposition - Define o nome do arquivo de saída para download. |
| 404 | Node, usuário ou arquivo de chave pública não encontrado. | - |
| 400 | Erro ao gerar ou recuperar o arquivo de chave pública. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_all_nodes
List[NodeResponse] get_all_nodes()
Lista todos os nodes
Retorna a lista completa de nodes cadastrados.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.node_response import NodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
try:
# Lista todos os nodes
api_response = api_instance.get_all_nodes()
print("The response of NodesApi->get_all_nodes:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_all_nodes: %s\n" % e)
Parameters
This endpoint does not need any parameter.
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Lista de nodes retornada com sucesso. | - |
| 400 | Erro ao listar nodes | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_auth_node
AuthNodeResponse get_auth_node(uuid)
Obtém os detalhes de um AuthNode
Retorna as informações completas de um AuthNode identificado pelo UUID informado,
incluindo usuário remoto, diretório de trabalho e timestamps de criação/atualização.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.auth_node_response import AuthNodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do AuthNode a ser consultado.
try:
# Obtém os detalhes de um AuthNode
api_response = api_instance.get_auth_node(uuid)
print("The response of NodesApi->get_auth_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_auth_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do AuthNode a ser consultado. |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | AuthNode retornado com sucesso. | - |
| 404 | AuthNode não encontrado para o UUID informado. | - |
| 400 | Erro ao consultar o AuthNode. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_auth_node_for_user_in_node
AuthNodeResponse get_auth_node_for_user_in_node(uuid, auth_node_user)
Recupera as credenciais (AuthNode) de um usuário em um node
Retorna o AuthNode correspondente ao usuário informado (authNodeUser)
para o node identificado pelo UUID no caminho.
O AuthNode representa um conjunto de credenciais (usuário, diretório de trabalho, chaves) para acesso remoto ao node.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.auth_node_response import AuthNodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do node no qual o AuthNode está cadastrado.
auth_node_user = 'xlibs' # str | Usuário remoto cujas credenciais (AuthNode) devem ser recuperadas.
try:
# Recupera as credenciais (AuthNode) de um usuário em um node
api_response = api_instance.get_auth_node_for_user_in_node(uuid, auth_node_user)
print("The response of NodesApi->get_auth_node_for_user_in_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_auth_node_for_user_in_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do node no qual o AuthNode está cadastrado. | |
| auth_node_user | str | Usuário remoto cujas credenciais (AuthNode) devem ser recuperadas. |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | AuthNode encontrado para o node e usuário informados. | - |
| 404 | Node ou AuthNode não encontrados para os parâmetros informados. | - |
| 400 | Erro de validação ao recuperar o AuthNode (parâmetros inválidos ou ausentes). | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_auth_node_public_key
List[str] get_auth_node_public_key(uuid)
Obtém a chave pública SSH do AuthNode
Retorna o conteúdo da chave pública SSH associada ao AuthNode identificado pelo UUID.
O conteúdo é retornado como uma lista de linhas do arquivo de chave pública.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do AuthNode cuja chave pública será retornada.
try:
# Obtém a chave pública SSH do AuthNode
api_response = api_instance.get_auth_node_public_key(uuid)
print("The response of NodesApi->get_auth_node_public_key:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_auth_node_public_key: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do AuthNode cuja chave pública será retornada. |
Return type
List[str]
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Conteúdo da chave pública SSH associada ao AuthNode. | - |
| 404 | AuthNode não encontrado ou diretório de chaves não localizado. | - |
| 400 | Erro ao obter a chave pública do AuthNode. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_casos_node
List[CasoResponse] get_casos_node(uuid)
Lista os casos associados a um node
Retorna a lista de casos vinculados ao node identificado pelo UUID.
Cada caso contém informações básicas como nome, caminhos locais e remotos, e o node relacionado.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.caso_response import CasoResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do node cujos casos serão listados
try:
# Lista os casos associados a um node
api_response = api_instance.get_casos_node(uuid)
print("The response of NodesApi->get_casos_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_casos_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do node cujos casos serão listados |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Lista de casos associados ao node. Se não houver casos, retorna uma lista vazia. | - |
| 404 | Node não encontrado. | - |
| 400 | Erro ao consultar os casos do node. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_node
NodeResponse get_node(uuid)
Obtém os detalhes de um node
Retorna as informações completas do node identificado pelo UUID informado.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.node_response import NodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do node a ser consultado
try:
# Obtém os detalhes de um node
api_response = api_instance.get_node(uuid)
print("The response of NodesApi->get_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do node a ser consultado |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Node retornado com sucesso. | - |
| 404 | Node não encontrado. | - |
| 400 | Erro ao consultar o node. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_node_from_name
NodeResponse get_node_from_name(name)
Retorna um Node
Retorna o node cadastrado a partir do nome.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.node_response import NodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
name = 'ampere-cepel' # str | Nome do nó de processamento cadastrado.
try:
# Retorna um Node
api_response = api_instance.get_node_from_name(name)
print("The response of NodesApi->get_node_from_name:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_node_from_name: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| name | str | Nome do nó de processamento cadastrado. |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Retorna o Node cadastrado. | - |
| 400 | Erro ao listar nodes | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_versoes_container
List[str] get_versoes_container(uuid)
Lista as versões disponíveis do PLDPro para um AuthNode
Retorna uma lista com as versões do PLDPro disponíveis para o AuthNode identificado pelo UUID informado.
A lista reflete as versões detectadas localmente no node remoto associado ao AuthNode, considerando o modo de execução (container ou nativo).
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do AuthNode cujas versões do PLDPro serão listadas
try:
# Lista as versões disponíveis do PLDPro para um AuthNode
api_response = api_instance.get_versoes_container(uuid)
print("The response of NodesApi->get_versoes_container:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->get_versoes_container: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do AuthNode cujas versões do PLDPro serão listadas |
Return type
List[str]
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Lista de versões do PLDPro encontradas para o AuthNode/node remoto. | - |
| 404 | AuthNode não encontrado. | - |
| 400 | Erro ao consultar as versões do PLDPro. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
list_auth_nodes_by_node
List[AuthNodeResponse] list_auth_nodes_by_node(uuid)
Lista as credenciais (AuthNodes) associadas a um node
Retorna a lista de AuthNodes vinculados ao node identificado pelo UUID informado.
Cada AuthNode representa um conjunto de credenciais (usuário, diretório de trabalho, chaves) para acesso remoto ao node.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.auth_node_response import AuthNodeResponse
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do node cujos AuthNodes serão listados.
try:
# Lista as credenciais (AuthNodes) associadas a um node
api_response = api_instance.list_auth_nodes_by_node(uuid)
print("The response of NodesApi->list_auth_nodes_by_node:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->list_auth_nodes_by_node: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do node cujos AuthNodes serão listados. |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Lista de AuthNodes associados ao node. Se não houver AuthNodes, retorna uma lista vazia. | - |
| 404 | Node não encontrado para o UUID informado. | - |
| 400 | Erro ao listar as credenciais (AuthNodes) do node. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
update_auth_node_credentials
HostCheckResult update_auth_node_credentials(uuid, credentials_update_request)
Atualiza as credenciais (senha) do AuthNode e recria as chaves
Força a atualização das credenciais de acesso (senha) associadas a um AuthNode identificado pelo UUID
e executa o processo de recriação das chaves de conexão remota para o node correspondente.
Retorna um objeto de verificação (HostCheckResult), indicando se a operação
teve sucesso, se o node/authNode existe no banco e se a conexão foi restabelecida.
Example
- Api Key Authentication (TenantIdAuth):
- Api Key Authentication (ApiKeyAuth):
import pldpro_sdk.api_client
from pldpro_sdk.api_client.models.credentials_update_request import CredentialsUpdateRequest
from pldpro_sdk.api_client.models.host_check_result import HostCheckResult
from pldpro_sdk.api_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to /v1
# See configuration.py for a list of all supported configuration parameters.
configuration = pldpro_sdk.api_client.Configuration(
host = "/v1"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: TenantIdAuth
configuration.api_key['TenantIdAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['TenantIdAuth'] = 'Bearer'
# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'
# Enter a context with an instance of the API client
with pldpro_sdk.api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = pldpro_sdk.api_client.NodesApi(api_client)
uuid = UUID('38400000-8cf0-11bd-b23e-10b96e4ef00d') # UUID | Identificador único do AuthNode cujas credenciais serão atualizadas
credentials_update_request = {password=Ssh@SenhaNova2025} # CredentialsUpdateRequest |
try:
# Atualiza as credenciais (senha) do AuthNode e recria as chaves
api_response = api_instance.update_auth_node_credentials(uuid, credentials_update_request)
print("The response of NodesApi->update_auth_node_credentials:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling NodesApi->update_auth_node_credentials: %s\n" % e)
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| uuid | UUID | Identificador único do AuthNode cujas credenciais serão atualizadas | |
| credentials_update_request | CredentialsUpdateRequest |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
HTTP response details
| Status code | Description | Response headers |
|---|---|---|
| 200 | Credenciais atualizadas e chaves recriadas (se necessário). | - |
| 400 | Requisição inválida (senha ausente ou inválida). | - |
| 500 | Erro ao atualizar credenciais ou ao recriar as chaves no node/AuthNode. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]