Receiving transloadit JSON response as a string instead of Object

Archived from the Transloadit support forum. Originally posted on March 18, 2014; details may be outdated, see our docs for current behavior. Original thread

Hello,

I’m trying to create a web app using Transloadit to upload the images on a form, and as the documentation mentions, after the upload finishes, the form get’s submitted and I receive the object on the POST object (so good so far).

But when I check on the transloadit object it seams like it is a string so I can’t access the objects in it.

 transloadit: '{
        "ok": "ASSEMBLY_COMPLETED",
        "message": "The assembly was successfully completed.",
        "assembly_id": "REDACTED",
        "parent_id": null,
        "assembly_url": "http://api2.nidba.transloadit.com/assemblies/REDACTED",
        "bytes_received": 33829,
        "bytes_expected": 33829,

And there continues, as you can see the transloadit attribute is a String no an object, on the examples I’ve seen that’s not the case. Anyway, if i try to use the JSON.parse(); function the parsing goes wrong , I see things like this:

 results: {
        thumb: [
            [
                Object
            ]
        ]
    }

I’m I missing something on my config ? here’s what i’m doing:

$(function() {

                        $('#create-gallery').transloadit({

                            wait: true,
                            triggerUploadOnFileSelection: true,

                            params: {
                                auth: { key: "my key" },
                                steps: {
                                    thumb: {
                                        robot: "/image/resize",
                                        width: 125,
                                        height: 125,
                                        resize_strategy: "pad"
                                    }
                                }
                            }
                        });
                    });

Thanks in advance, here’s a gist with the entire response object https://gist.github.com/kevinblanco/9628156