<?php

namespace Tops\AmazonSellingPartnerAPI\Api;

class FulfillmentOutboundApi20200701 extends BaseApi
{
    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function getFulfillmentPreview($body)
    {
        if (null === $body) {
            throw new \InvalidArgumentException('Missing the required parameter $body when calling getFulfillmentPreview');
        }

        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders/preview';
        $url = $this->config->getHost() . $resource_path;
        $http_body = $body;
        $query_params = [];
        $method = 'GET';

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function listAllFulfillmentOrders($params)
    {
        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders';
        $http_body = '';
        $query_params = [];
        $method = 'GET';
        
        // query params
        if (array_key_exists('queryStartDate', $params) && $params['queryStartDate'] !== null) {
            $query_params['queryStartDate'] = $params['queryStartDate'];
        }
        if (array_key_exists('nextToken', $params) && $params['nextToken'] !== null) {
            $query_params['nextToken'] = $params['nextToken'];
        }

        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function createFulfillmentOrder($body)
    {
        if (null === $body) {
            throw new \InvalidArgumentException('Missing the required parameter $body when calling createFulfillmentOrder');
        }

        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders';
        $http_body = $body;
        $query_params = [];
        $method = 'POST';
        
        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function getPackageTrackingDetails($params)
    {
        if (!array_key_exists('packageNumber', $params) ||  null === $params['packageNumber']) {
            throw new \InvalidArgumentException('Missing the required parameter $packageNumber when calling getPackageTrackingDetails');
        }

        $resource_path = '/fba/outbound/2020-07-01/tracking';
        $http_body = '';
        $query_params = [];
        $method = 'GET';
        
        // query params
        if (array_key_exists('packageNumber', $params) && $params['packageNumber'] !== null) {
            $query_params['packageNumber'] = $params['packageNumber'];
        }

        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function listReturnReasonCodes($params)
    {
        if (!array_key_exists('sellerSku', $params) ||  null === $params['sellerSku']) {
            throw new \InvalidArgumentException('Missing the required parameter $sellerSku when calling getPreorderInfo');
        }
        if (!array_key_exists('language', $params) ||  null === $params['language']) {
            throw new \InvalidArgumentException('Missing the required parameter $language when calling getPreorderInfo');
        }

        $resource_path = '/fba/outbound/2020-07-01/returnReasonCodes';
        $url = $this->config->getHost() . $resource_path;
        $http_body = '';
        $query_params = [];
        $method = 'GET';

        // query params
        if (array_key_exists('sellerSku', $params) && $params['sellerSku'] !== null) {
            $query_params['sellerSku'] = $params['sellerSku'];
        }
        if (array_key_exists('marketplaceId', $params) && $params['marketplaceId'] !== null) {
            $query_params['marketplaceId'] = $params['marketplaceId'];
        }
        if (array_key_exists('sellerFulfillmentOrderId', $params) && $params['sellerFulfillmentOrderId'] !== null) {
            $query_params['sellerFulfillmentOrderId'] = $params['sellerFulfillmentOrderId'];
        }
        if (array_key_exists('language', $params) && $params['language'] !== null) {
            $query_params['language'] = $params['language'];
        }

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }
    
    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function createFulfillmentReturn($body, $seller_fulfillment_order_id)
    {
        if (null === $body) {
            throw new \InvalidArgumentException('Missing the required parameter $body when calling createFulfillmentReturn');
        }
        if (null === $seller_fulfillment_order_id) {
            throw new \InvalidArgumentException('Missing the required parameter $seller_fulfillment_order_id when calling createFulfillmentReturn');
        }

        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders/{sellerFulfillmentOrderId}/return';
        $url = $this->config->getHost() . $resource_path;
        $http_body = $body;
        $query_params = [];
        $method = 'PUT';

        // path params
        if (null !== $seller_fulfillment_order_id) {
            $resource_path = str_replace(
                '{' . 'sellerFulfillmentOrderId' . '}',
                $seller_fulfillment_order_id,
                $resource_path
            );
        }

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function getFulfillmentOrder($seller_fulfillment_order_id)
    {
        if (null === $seller_fulfillment_order_id) {
            throw new \InvalidArgumentException('Missing the required parameter $seller_fulfillment_order_id when calling getFulfillmentOrder');
        }

        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders/{sellerFulfillmentOrderId}';
        $url = $this->config->getHost() . $resource_path;
        $http_body = '';
        $query_params = [];
        $method = 'GET';

        // path params
        if (null !== $seller_fulfillment_order_id) {
            $resource_path = str_replace(
                '{' . 'sellerFulfillmentOrderId' . '}',
                $seller_fulfillment_order_id,
                $resource_path
            );
        }

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function updateFulfillmentOrder($body, $seller_fulfillment_order_id)
    {
        if (null === $body) {
            throw new \InvalidArgumentException('Missing the required parameter $body when calling updateFulfillmentOrder');
        }
        if (null === $seller_fulfillment_order_id) {
            throw new \InvalidArgumentException('Missing the required parameter $seller_fulfillment_order_id when calling updateFulfillmentOrder');
        }

        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders/{sellerFulfillmentOrderId}';
        $url = $this->config->getHost() . $resource_path;
        $http_body = $body;
        $query_params = [];
        $method = 'PUT';

        // path params
        if (null !== $seller_fulfillment_order_id) {
            $resource_path = str_replace(
                '{' . 'sellerFulfillmentOrderId' . '}',
                $seller_fulfillment_order_id,
                $resource_path
            );
        }

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function cancelFulfillmentOrder($seller_fulfillment_order_id)
    {
        if (null === $seller_fulfillment_order_id) {
            throw new \InvalidArgumentException('Missing the required parameter $seller_fulfillment_order_id when calling cancelFulfillmentOrder');
        }

        $resource_path = '/fba/outbound/2020-07-01/fulfillmentOrders/{sellerFulfillmentOrderId}/cancel';
        $http_body = $body;
        $query_params = [];
        $method = 'PUT';
        
        // path params
        if (null !== $seller_fulfillment_order_id) {
            $resource_path = str_replace(
                '{' . 'sellerFulfillmentOrderId' . '}',
                $seller_fulfillment_order_id,
                $resource_path
            );
        }

        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function getFeatures($params)
    {
        if (!array_key_exists('marketplaceId', $params) ||  null === $params['marketplaceId']) {
            throw new \InvalidArgumentException('Missing the required parameter $marketplaceId when calling getPreorderInfo');
        }

        $resource_path = '/fba/outbound/2020-07-01/features';
        $http_body = '';
        $query_params = [];
        $method = 'GET';

        if (array_key_exists('marketplaceId', $params) && $params['marketplaceId'] !== null) {
            $query_params['marketplaceId'] = $params['marketplaceId'];
        }

        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function getFeatureInventory($params, $feature_name)
    {
        if (!array_key_exists('marketplaceId', $params) ||  null === $params['marketplaceId']) {
            throw new \InvalidArgumentException('Missing the required parameter $marketplaceId when calling getPreorderInfo');
        }
        if (null === $feature_name) {
            throw new \InvalidArgumentException('Missing the required parameter $feature_name when calling getFeatureInventory');
        }

        $resource_path = '/fba/outbound/2020-07-01/features/inventory/{featureName}';
        $http_body = '';
        $query_params = [];
        $method = 'GET';
        
        // path params
        if (null !== $feature_name) {
            $resource_path = str_replace(
                '{' . 'featureName' . '}',
                $feature_name,
                $resource_path
            );
        }

        if (array_key_exists('marketplaceId', $params) && $params['marketplaceId'] !== null) {
            $query_params['marketplaceId'] = $params['marketplaceId'];
        }
        if (array_key_exists('nextToken', $params) && $params['nextToken'] !== null) {
            $query_params['nextToken'] = $params['nextToken'];
        }

        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }

    /**
     * Operation List Catalog Items
     *
     * @param array $params
     * @param string $params['MarketplaceId'] A marketplace identifier. Specifies the marketplace for which items are returned. (required)
     * @param string $params['Query'] Keyword(s) to use to search for items in the catalog. Example: 'harry potter books'.
     * @param string $params['QueryContextId'] An identifier for the context within which the given search will be performed. A marketplace might provide mechanisms for constraining a search to a subset of potential items. For example, the retail marketplace allows queries to be constrained to a specific category. The QueryContextId parameter specifies such a subset. If it is omitted, the search will be performed using the default context for the marketplace, which will typically contain the largest set of items.
     * @param string $params['SellerSKU'] Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.
     * @param string $params['UPC'] A 12-digit bar code used for retail packaging.
     * @param string $params['EAN'] A European article number that uniquely identifies the catalog item, manufacturer, and its attributes.
     * @param string $params['ISBN'] The unique commercial book identifier used to identify books internationally.
     * @param string $params['JAN'] A Japanese article number that uniquely identifies the product, manufacturer, and its attributes.
     * @return json\
     *
     * @author Chetan Meena <chetan@topsinfosolutions.com>
     *
     * about more Ref: https://github.com/amzn/selling-partner-api-docs/blob/main/references/catalog-items-api/catalogItemsV0.md#listcatalogitems
     */
    public function getFeatureSKU($params, $feature_name, $seller_sku)
    {
        if (!array_key_exists('marketplaceId', $params) ||  null === $params['marketplaceId']) {
            throw new \InvalidArgumentException('Missing the required parameter $marketplaceId when calling getPreorderInfo');
        }
        if (null === $feature_name) {
            throw new \InvalidArgumentException('Missing the required parameter $feature_name when calling getFeatureSKU');
        }
        if (null === $seller_sku) {
            throw new \InvalidArgumentException('Missing the required parameter $seller_sku when calling getFeatureSKU');
        }

        $resource_path = '/fba/outbound/2020-07-01/features/inventory/{featureName}/{sellerSku}';
        $http_body = '';
        $query_params = [];
        $method = 'GET';
        
        // path params
        if (null !== $feature_name) {
            $resource_path = str_replace(
                '{' . 'featureName' . '}',
                $feature_name,
                $resource_path
            );
        }
        if (null !== $seller_sku) {
            $resource_path = str_replace(
                '{' . 'sellerSku' . '}',
                $seller_sku,
                $resource_path
            );
        }

        if (array_key_exists('marketplaceId', $params) && $params['marketplaceId'] !== null) {
            $query_params['marketplaceId'] = $params['marketplaceId'];
        }

        $url = $this->config->getHost() . $resource_path;

        $curl_headers = $this->generateRequest($resource_path, $query_params, $http_body, $this->config, $method);

        return $this->sendRequest($url, $query_params, $http_body, $curl_headers, $method);
    }
}
