jlevers / selling-partner-api

A PHP client library for Amazon's Selling Partner API
BSD 3-Clause "New" or "Revised" License
402 stars 189 forks source link

Help on sending tracking numbers to amazon #795

Open katzendrama opened 4 days ago

katzendrama commented 4 days ago

Hi! I am just trying to set my FBM orders as fulfilled via the selling-partner-api.

My goal is to just set an Order as fulfilled with an carrier (e.g. DHL) with an tracking number (e.g. 003404999999999).

Im not able to identify the right API for this. It could be OrdersAPI, shipping API or MerchantFulfilllmentAPI.

Im trying for weeks to find a solution. I would be happy if someone could help me :)

Thanks!

My starting point of code is this:

public function setShipped(AuftragsFulfillment $auftragsFulfillment, $amazon_id)
{

    $connector = SellingPartnerApi::seller(
        clientId: $this->amazon_clientid,
        clientSecret: $this->amazon_clientsecret,
        refreshToken: $this->amazon_refreshtoken,
        endpoint: Endpoint::EU
    );

    /*
            'tracking_info' => [
                'company' => $auftragsFulfillment->getVersandmethode() , -> DHL / Deutsche Post 
                'number' => $auftragsFulfillment->getVerfolgungsnummer(), -> 003404... / A0034567...
            ],
    */

}

`

christian71-stack commented 4 days ago

Look at the Mainpage of this Repository. https://github.com/jlevers/selling-partner-api#working-with-dtos