Actions120
- Authentication Actions
- Bloqueios Actions
- Get Motivos
- Get Bloqueio Faturamento
- Get Bloqueio Conta
- Get Bloqueio Carteira
- Get Bloqueio Compra Pedido
- Get Bloqueio Cotacao Compra
- Get Bloqueio Data Minima Vencimento
- Get Bloqueio Estoque Negativo
- Get Bloqueio Financiamento Pedido
- Get Bloqueio Frete Pago
- Get Bloqueio Limite Credito
- Get Bloqueio Limite Individual
- Get Bloqueio Manutencao Preventiva
- Get Bloqueio Margem
- Get Bloqueio Mes Reajuste
- Get Bloqueio Parcela Minima
- Get Bloqueio Saldo Atrasado
- Desaprovar Bloqueio
- Liberar Bloqueio
- Liberar Bloqueio Limite Credito
- Liberar Bloqueio Limite Individual
- Classificacao Actions
- Cliente Actions
- Instituição Financeira Actions
- Linha de Crédito Actions
- Máquina Actions
- Mecânico Actions
- Motorista Actions
- Negócio Actions
- Nota Fiscal Actions
- Oficina Actions
- Orçamento Actions
- Orçamento Balcão Actions
- Ordem de Serviço Actions
- Criar Ordem de Serviço Completa
- Consultar por ID
- Consultar por Código Externo
- Listar Agendamentos
- Listar Agendamentos por ID
- Listar Status do Lock
- Listar Ordens de Serviço
- Incluir Ordem de Serviço
- Listar Ordens de Serviço Geral
- Incluir Apontamento
- Incluir Despesa
- Incluir Peça
- Incluir Serviço
- Editar Peça
- Editar Serviço
- Editar Veículo
- Incluir Observação
- Ordem Serviço Tipo Actions
- Pedido Actions
- Política de Prazo Actions
- Política de Preço Actions
- Produto Actions
- Prospect Actions
- Saída Actions
- Serviço Actions
- Status Financiamento Actions
- Título Actions
- Veículo Cliente Actions
- Veículo Próprio Actions
- Vendas Actions
- Vendedor Actions
Ordem de Serviço → Incluir Peça
AI-generatedOverview
This node integrates with the Nuvem Solution API to perform various operations related to service orders and other business resources. Specifically, for the "Ordem de Serviço" (Service Order) resource and the "Incluir Peça" (Include Part) operation, it allows users to add a part to an existing service order by sending a JSON payload describing the part details.
This functionality is useful in scenarios where a service order needs to be updated with additional parts required for repair or maintenance tasks. For example, a mechanic or service manager can automate the inclusion of parts into service orders directly from their workflow, ensuring accurate tracking and inventory management.
Practical examples:
- Automatically adding replacement parts to a service order when a diagnostic step identifies needed components.
- Integrating with inventory systems to include parts in service orders as they are reserved or allocated.
- Streamlining workshop operations by programmatically updating service orders with parts information.
Properties
| Name | Meaning |
|---|---|
| Request Body | JSON body for the request. This should contain the details of the part to be included in the service order. The JSON structure depends on the API's expected format for including a part. |
Output
The node outputs the JSON response returned by the Nuvem Solution API after attempting to include the part in the service order. This typically contains confirmation details such as the created part record, status messages, or error information if the operation failed.
The output is structured as a JSON object reflecting the API response. There is no binary data output for this operation.
Dependencies
- Requires an API key credential for authenticating with the Nuvem Solution API.
- The node uses bearer token authentication obtained via the configured credentials.
- The base URL for the API and authentication tokens are managed internally.
- The user must provide valid JSON in the "Request Body" property matching the API specification for including a part in a service order.
Troubleshooting
- Invalid JSON in Request Body: If the JSON provided in the "Request Body" field is malformed, the API call will fail. Ensure the JSON syntax is correct before executing the node.
- Authentication Errors: If the API credentials are incorrect or expired, the node will throw authentication errors. Verify that the API key and other credentials are valid and have not expired.
- Unsupported Operation Error: If the operation name is misspelled or not supported, the node will throw an error indicating the operation is not supported.
- API Response Errors: The API may return errors due to invalid data, missing required fields, or business logic constraints. Review the API response message for details and adjust the request accordingly.
Links and References
- Nuvem Solution API Documentation (Assumed official API docs; replace with actual link if available)
- n8n Documentation on Creating Custom Nodes
- JSON validation tools such as JSONLint for verifying request body correctness.
Summary of execute() method logic for Resource "ordemServico" and Operation "incluirPeca":
- Reads input items.
- Retrieves API credentials and obtains an access token.
- For each input item:
- Checks if resource is "ordemServico" and operation is "incluirPeca".
- Parses the "requestBody" parameter as JSON.
- Sends a POST request to the endpoint
/erp/oficina/ordensServico/pecawith the parsed JSON body. - Collects the API response.
- Returns all responses as JSON array output.
This design enables batch processing of multiple parts inclusion requests in one execution.