Nexeed
    • Introduction
    • User manual
      • Processing chains
      • Endpoints
    • Operations manual
      • Overview
      • System Architecture and Interfaces
      • System Requirements
        • datapublisher/datapublisher-service
      • Migration from Previous Versions
        • Tenant ID Migration Guide
      • Setup and Configuration
        • datapublisher-service
        • Helm Configuration
        • Environement Variables
      • Start and Shutdown
      • Regular Operations
      • Failure Handling
        • Common Outage Scenarios
      • Backup and Restore
      • Logging and Monitoring
        • Module Health Endpoints and K8S Probes
        • Observability & Metrics
      • Known Limitations
    • Developer documentation
      • Concepts
      • Getting started
      • How-to
        • Register your module
        • Provide your data
    • API documentation
    • Glossary
Data Publisher
  • Industrial Application System
  • Core Services
    • Block Management
    • Deviation Processor
    • ID Builder
    • Multitenant Access Control
    • Notification Service
    • Ticket Management
    • Web Portal
  • Shopfloor Management
    • Andon Live
    • Global Production Overview
    • KPI Reporting
    • Operational Routines
    • Shift Book
    • Shopfloor Management Administration
  • Product & Quality
    • Product Setup Management
    • Part Traceability
    • Process Quality
    • Setup Specs
  • Execution
    • Line Control
    • Material Management
    • Order Management
    • Packaging Control
    • Rework Control
  • Intralogistics
    • Stock Management
    • Transport Management
  • Machine & Equipment
    • Condition Monitoring
    • Device Portal
    • Maintenance Management
    • Tool Management
  • Enterprise & Shopfloor Integration
    • Archiving Bridge
    • Data Publisher
    • Engineering UI
    • ERP Connectivity
    • Gateway
    • Information Router
    • Master Data Management
    • Orchestrator

Nexeed Learning Portal

  • Data Publisher
  • Payload Transformation

Payload Transformation

Payload transformations in LiveDataJob allow you to modify the structure and content of messages using JSONata expressions. Enter your JSONata-compliant transformation expression in the LiveDataJob transformer field to reshape, filter, or restructure message payloads before they are sent to the target endpoint.

Examples

Extract Nested Fields

Extract specific nested fields from a complex message structure:

JSONata Expression:

$exists(document) ? ($ ~> | document | basicInfo |) : null

Input:

{
  "$type": "urn:bosch:nexeed:eventtype:entity:v1",
  "correlationId": "b011322b-781b-4c4d-b1fc-4adc8aa33459",
  "msgId": "a503661f-0190-4992-a93f-57bb04b53099",
  "msgSendTime": "2024-12-10T19:43:26.5493394+01:00",
  "msgSender": "mes-DataCollector_PDA2",
  "msgTopic": "mi/d/JS00/STAG/MES/pda/BCI/FeP/ProcessResult",
  "payload": {
    "$type": "urn:bosch:nexeed:CustomEntityEventPayload:v1",
    "EventId": "b011322b-781b-4c4d-b1fc-4adc8aa33459",
    "EventTime": "2024-12-10T19:43:26.5493394+01:00",
    "document": {
      "basicInfo": {
        "contextId": "b011322b-781b-4c4d-b1fc-4adc8aa33459",
        "identifier": "Part9044453x87391",
        "locationId": "00000000000100100001100010001",
        "nioBits": "0",
        "procNo": "1000",
        "resultDate": "2024-12-10T19:43:26.5493394+01:00",
        "resultState": "1",
        "typeNo": "1111111111",
        "typeVar": "00"
      }
    }
  }
}

Output:

{
  "contextId": "b011322b-781b-4c4d-b1fc-4adc8aa33459",
  "identifier": "Part9044453x87391",
  "locationId": "00000000000100100001100010001",
  "nioBits": "0",
  "procNo": "1000",
  "resultDate": "2024-12-10T19:43:26.5493394+01:00",
  "resultState": "1",
  "typeNo": "1111111111",
  "typeVar": "00"
}

This transformation uses the object transform operator (~>) to remove nested levels, keeping only the basicInfo content. If document doesn’t exist, it returns null.

Flatten Payload Structure

Access data from the payload and flatten the structure:

JSONata Expression:

{
  "eventId": payload.EventId,
  "eventTime": payload.EventTime,
  "partId": payload.document.basicInfo.identifier,
  "result": payload.document.basicInfo.resultState
}

Output:

{
  "eventId": "b011322b-781b-4c4d-b1fc-4adc8aa33459",
  "eventTime": "2024-12-10T19:43:26.5493394+01:00",
  "partId": "Part9044453x87391",
  "result": "1"
}

Reference Documentation

  • JSONata Documentation - Complete syntax and function reference

  • JSONata Exerciser - Interactive playground for testing expressions

Contents

© Robert Bosch Manufacturing Solutions GmbH 2023-2025, all rights reserved

Changelog Corporate information Legal notice Data protection notice Third party licenses