# Workflow JSON output to workflow array of arrays input

**URL:** <https://cwl.discourse.group/t/workflow-json-output-to-workflow-array-of-arrays-input/100>\
**Category:** CWL Questions\
**Created:** [March 20, 2020, 9:20pm UTC](https://cwl.discourse.group/t/workflow-json-output-to-workflow-array-of-arrays-input/100 "2020-03-20T21:20:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![wshands](https://yyz2.discourse-cdn.com/free1/user_avatar/cwl.discourse.group/wshands/32/198_2.png) [@wshands](https://cwl.discourse.group/u/wshands)\
**Post date:** [March 20, 2020, 9:20pm UTC](https://cwl.discourse.group/t/workflow-json-output-to-workflow-array-of-arrays-input/100/1 "2020-03-20T21:20:48Z")

</div>

How can I take an output from a workflow step that is a file containing a JSON string of an array of arrays of File objects and use that as input to a second workflow step?  
E.g. the file contains:  
input.json:

```auto
[
     [ 'input_barcode_fastq': { 'class': 'File', 'path': '/bundle1_R2.fastq'},
         'input_fastq1': { 'class': 'File', 'path': '/bundle1_R1.fastq'},
         'input_fastq2': { 'class': 'File', 'path': '/bundle1_R3.fastq'}
     ],
     ...
     [ 'input_barcode_fastq': { 'class': 'File', 'path': '/bundle2__R2.fastq'},
        'input_fastq1': { 'class': 'File',...}...
     ]
]

```

and I want to have an input to the second workflow step something like:

```auto
inputs:
  array_of_sequence_file_bundles:
        type:
          type: array
          items:
            type: array
            items: File

```

Or is there a better way to do this?  
Thanks!

---

<div class="post-metadata">

**Author:** ![mrc](https://yyz2.discourse-cdn.com/free1/user_avatar/cwl.discourse.group/mrc/32/3_2.png) [@mrc](https://cwl.discourse.group/u/mrc)\
**Post date:** [March 30, 2020, 4:01pm UTC](https://cwl.discourse.group/t/workflow-json-output-to-workflow-array-of-arrays-input/100/2 "2020-03-30T16:01:54Z")

</div>

Hey Walter! Nice to hear from you again.

Do you know about the `cwl.output.json` trick?

[https://www.commonwl.org/v1.0/CommandLineTool.html#Output\_binding](https://www.commonwl.org/v1.0/CommandLineTool.html#Output_binding)
