# POST /flows method

**URL:** <https://discourse.nodered.org/t/post-flows-method/807>\
**Category:** General\
**Created:** [14 June 2018 11:55 UTC](https://discourse.nodered.org/t/post-flows-method/807 "2018-06-14T11:55:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ThanosMel](https://avatars.discourse-cdn.com/v4/letter/t/db5fbb/32.png) [@ThanosMel](https://discourse.nodered.org/u/ThanosMel)\
**Post date:** [14 June 2018 11:55 UTC](https://discourse.nodered.org/t/post-flows-method/807/1 "2018-06-14T11:55:10Z")

</div>

I want to update my flows remotely. So i am using an http get request to take the new flow and then using an http POST/flows request to set the new active flow configuration. The thing is that is that the new flow that i post is overriding my old flows what can i do?I dont want to use the put method because the flow is not yet created. Also when i am trying to use POST/flow method i am getting the following error : "missing nodes property at Object.addflow..." .I cannot understand the POST/flow method documentation.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [15 June 2018 09:49 UTC](https://discourse.nodered.org/t/post-flows-method/807/2 "2018-06-15T09:49:51Z")

</div>

Posting to `/flows` replaces the entire flow configuration.

If you want to add an flow, you need to PUT to `/flow`  
If you want to update an individual flow, you need to POST to `/flow/<flow-id>`

The format of the flow object is _different_ between the `/flows` api and the `/flow` api - whic is probably the cause of the error you are hitting.

If you do a GET of `/flow/<existing-flow-id>` you’ll see the format required by the `/flow` api.

---

<div class="post-metadata">

**Author:** ![ThanosMel](https://avatars.discourse-cdn.com/v4/letter/t/db5fbb/32.png) [@ThanosMel](https://discourse.nodered.org/u/ThanosMel)\
**Post date:** [15 June 2018 10:06 UTC](https://discourse.nodered.org/t/post-flows-method/807/3 "2018-06-15T10:06:02Z")

</div>

Oh well i got it working. I just added my flow to the “nodes”: […] element and it worked fine. Thanks for the help @knolleary!
