Giter Club home page Giter Club logo

Comments (3)

jlevers avatar jlevers commented on August 11, 2024

The GetMyFeesEstimateRequest object has to be passed data when it is constructed (as do most models). For example:

use SellingPartnerApi\Api;
use SellingPartnerApi\Model\Fees;

$feesEstimateRequest = new Fees\GetMyFeesEstimateRequest([
    "fees_estimate_request" => new Fees\FeesEstimateRequest([
        "marketplace_id" => "ATVPDKIKX0DER",
        "price_to_estimate_fees" => new Fees\PriceToEstimateFees([
            "listing_price" => new Fees\MoneyType([
                "currency_code" => "USD",
                "amount" => "21.99",
            ]),
            "shipping_price" => new Fees\MoneyType([
                "currency_code" => "USD",
                "amount" => "4.23",
            ]),
            "identifier" => "some_unique_value",
    ]),
]);

$api = new Api\FeesApi();
$response = $api->getMyFeesEstimateForSKU("your_sku", $feesEstimateRequest);

(I haven't tested that code snippet, but it should at least be close enough to correct to get you up and running.)

As you can see on its documentation page, the GetMyFeesEstimateRequest model has an inner attribute called fees_estimate_request, which should be an instance of the FeesEstimateRequest model. Then that model has some inner attributes, some of which are other models...you can keep clicking through the links on the documentation pages until you've checked the sub-attributes of every attribute required by the model you're using. Many models have optional attributes, which will be marked optional on the model's documentation page.

from selling-partner-api.

jlevers avatar jlevers commented on August 11, 2024

@yassersebai did you resolve this issue? If so, I'd like to close it.

from selling-partner-api.

jlevers avatar jlevers commented on August 11, 2024

I'm going to close this -- please feel free to reopen it if necessary.

from selling-partner-api.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.