I am trying to set this up using php7 and guzzle for my rest API. when i send the request in curl using cli to the debug url i get a nice json response

```
{
  "hitParsingResult": [ {
    "valid": true,
    "parserMessage": [ ],
    "hit": "/debug/collect?v=1\u0026t=pageview\u0026tid=UA-1234567-1\u0026uid=UA-1234567-1\u0026dh=test.domain.com\u0026dp=/api/user/verify/flow"
  } ],
  "parserMessage": [ {
    "messageType": "INFO",
    "description": "Found 1 hit in the request."
  } ]
}

```

but if i send it to prod url i get weird response everytime

```
GIF89a▒▒▒▒▒,D;

```

does anyone know how to solve this?

this is what i run on cli

```
curl -X POST -d 'v=1&t=pageview&tid=UA-xxxxxxxxx-1&uid=UA-xxxxxxxxx-1&dh=test.domain.com&dp=%2Fiwsapi%2Fuser%2Fverify%2Fflow' https://www.google-analytics.com/debug/collect

```

for non debug mode i just remove the the debug

```
curl -X POST -d 'v=1&t=pageview&tid=UA-xxxxxxxxx-1&uid=UA-xxxxxxxxx-1&dh=test.domain.com&dp=%2Fiwsapi%2Fuser%2Fverify%2Fflow' https://www.google-analytics.com/collect

```

In guzzle i am building it like so

```
$promise = $guzzle->post("/debug/collect", [
                                'proxy' => [
                                    'http'  => 'http://proxy:8080',
                                    'https'  => 'http://proxy:8080', 
                                ],
                                'form_params'=>[
                                    'v'=>1,
                                    't'=>'pageview',
                                    'tid'=>GOOGLE_ID,
                                    'uid'=>$_SERVER['HTTP_CTVFNTUSERNAME'],
                                    'dh'=>WWWHOST,
                                    'dp'=>$_SERVER['REQUEST_URI'],
                                    //'dt'=>'homepage'
                                ]
                            ]);

```