# Protobuf data encoding

**URL:** <https://forum.inductiveautomation.com/t/protobuf-data-encoding/97572>\
**Category:** General Discussion\
**Created:** [October 21, 2024, 9:52pm UTC](https://forum.inductiveautomation.com/t/protobuf-data-encoding/97572 "2024-10-21T21:52:29Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![tamerplc](https://avatars.discourse-cdn.com/v4/letter/t/d78d45/32.png) [@tamerplc](https://forum.inductiveautomation.com/u/tamerplc)\
**Post date:** [October 23, 2024, 10:53pm UTC](https://forum.inductiveautomation.com/t/protobuf-data-encoding/97572/7 "2024-10-23T22:53:44Z")

</div>

it's working after getting some guidance from Ignition support team 😀

1. Define the Protobuf schema that describes the structure of the data you want to serialize/deserialize. This schema file (`.proto`) defines the types and structure of the messages.

2. Generate Java code from the Protobuf schema using a Protobuf compiler (`protoc`) to generate Java classes from the `.proto` schema file.

- The `protoc` compiler reads the `.proto` file and outputs Java source files corresponding to the schema.

1. Compile the generated Java code using a Java compiler (`javac`).
2. Use the generated Java code by adding the compiled Java classes & JAR file to Ignition, then importing these classes within your script.
3. Now serialize/deserialize Protobuf messages using the generated code in your script.

---

_[View the full topic](https://forum.inductiveautomation.com/t/protobuf-data-encoding/97572)._
