First open the help page, then select Appendix: Job Properties -> Job Information. The first item is $FFwfJob.jobName$. This will give you the full job name.
Since you only want part of the job name look in the help at:
Workflow Setup -> The Workflow Setup Tab -> Process Variable Operations.
You'll want to remove a substring with X=1 and Y = 6. The string is $FFwfJob.jobName.substring(1,6)$
This is the value that you will pass to your external script.
The Appendix lists all the other system values that are available to use within your workflows.
We are moving from Odystar to Freeflow Core, our system at the moment (not set up by myself i might add) allows you to create a Low Res File and a High Res File and then places them in a folder. We rename all our print files with the first 6 characters being the job number of the job. When Odystar creates the low res and the High Res Files it also creates a folder for each using the first 6 characters of the filename as the name of the folder, this is apparently possible in FreeFlow core with a script, im wondering if anyone could help me achieve it?