# What is the proper way to modify a project resource via the SDK?

**URL:** <https://forum.inductiveautomation.com/t/what-is-the-proper-way-to-modify-a-project-resource-via-the-sdk/68279>\
**Category:** Module Development\
**Tags:** sdk, ignition81\
**Created:** [January 5, 2023, 7:41pm UTC](https://forum.inductiveautomation.com/t/what-is-the-proper-way-to-modify-a-project-resource-via-the-sdk/68279 "2023-01-05T19:41:28Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![AMavros](https://avatars.discourse-cdn.com/v4/letter/a/94ad74/32.png) [@AMavros](https://forum.inductiveautomation.com/u/AMavros)\
**Post date:** [January 5, 2023, 7:41pm UTC](https://forum.inductiveautomation.com/t/what-is-the-proper-way-to-modify-a-project-resource-via-the-sdk/68279/1 "2023-01-05T19:41:28Z")

</div>

In the GatewayContext, what are the steps necessary to modify a json config? I've tried creating a ProjectResourceBuilder from the project resource I want to modify, and use its putData() function with the data key and new bytes, but when I retrieve it again afterwards to check, I don't see my changes made. I see RuntimeProjectBuilder class has a setResources function and RuntimeProject having an applyChanges function, should these be used instead or is there a better way?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [January 10, 2023, 5:13pm UTC](https://forum.inductiveautomation.com/t/what-is-the-proper-way-to-modify-a-project-resource-via-the-sdk/68279/2 "2023-01-10T17:13:54Z")

</div>

From the gateway, the only supported way is by pushing ChangeOperations.

See this thread for some inspiration:

> [@Autogenerate Views inside the Perspective View Folder Structure (Self Aware SCADA)](https://forum.inductiveautomation.com/t/autogenerate-views-inside-the-perspective-view-folder-structure-self-aware-scada/63204/34):
>
> ChangeOperation has various static methods to construct: [https://files.inductiveautomation.com/sdk/javadoc/ignition81/8.1.21/com/inductiveautomation/ignition/common/project/ChangeOperation.html#newCreateOp(com.inductiveautomation.ignition.common.project.resource.ProjectResource)](https://files.inductiveautomation.com/sdk/javadoc/ignition81/8.1.21/com/inductiveautomation/ignition/common/project/ChangeOperation.html#newCreateOp(com.inductiveautomation.ignition.common.project.resource.ProjectResource)) A ProjectManager can be retrieved from GatewayContext.
