Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

submitTracking error 411 Length Required #50

Open
sandism opened this issue Apr 12, 2019 · 2 comments
Open

submitTracking error 411 Length Required #50

sandism opened this issue Apr 12, 2019 · 2 comments

Comments

@sandism
Copy link

sandism commented Apr 12, 2019

$api->submitTracking(array('params' => 
			array(
			'shop_id' => $shop,
			'receipt_id' => $receipt,
			'tracking_code' => $code,
			'carrier_name' => $carrier,
			)));

response

Fatal error: Uncaught Etsy\EtsyRequestException: [1]:### Invalid auth/bad request (got a 411, expected HTTP/1.1 20X or a redirect): Array ( ) <title>Error 411 (Length Required)!!1

@RobertVDK
Copy link

I am receiving the same issue. Any resolve to this?

@shopifychamp
Copy link
Contributor

Hi sandism,
You need to put post content in data index for post/put request. Please refer below code:

$return = $this->api->submitTracking(
       array(
            'params' => array(
                 "receipt_id"=> "16999999",	
            ),
           'data' => array(
                  "tracking_code"=>"9400109202020999999999",
                  "carrier_name"=> "4px",
            )
      )
);
print_r($return);

Please let me know if you need any help.

Thanks
Kshitij

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants