# Passing variables from Pre-Process to Post-Process scripts

**URL:** <https://community.dreamfactory.com/t/passing-variables-from-pre-process-to-post-process-scripts/4997>\
**Category:** Server-Side Scripting\
**Created:** [July 30, 2019, 12:09pm UTC](https://community.dreamfactory.com/t/passing-variables-from-pre-process-to-post-process-scripts/4997 "2019-07-30T12:09:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![charleslcso](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/charleslcso/32/1273_2.png) [@charleslcso](https://community.dreamfactory.com/u/charleslcso)\
**Post date:** [July 30, 2019, 12:09pm UTC](https://community.dreamfactory.com/t/passing-variables-from-pre-process-to-post-process-scripts/4997/1 "2019-07-30T12:09:25Z")

</div>

Hello, I’m new to DreamFactory but I’m starting to get the hang of it. I’m on Bitnami 2.14.1-13.

I’m playing with Scripts. Managed to get Pre-Process and Post-Process scripts working by following the examples in various places.

Now I’m thinking to pass a few variables created during the Pre-Process event, and have them available during the Post-Process event.

I tried to place a variable in

> $event[‘request’][‘payload’][‘var1’] = ‘abc’;

during Pre-Process, but it is no longer there in Post-Process.

Edit: after further reading I realise payload is not the right place to hold variables.

How should I approach this please?

Thanks alot!
