# Price and Quantity Update

## Parameters

### `merchantId`

{% hint style="danger" %}
**Required**
{% endhint %}

There is documentation on how to retrieve your `merchantId`  in the [Flat file feeds](/feed-transformer/feed-types/tab.md#common-required-parameters)section of the [Flat file feeds](/feed-transformer/feed-types/tab.md) page.

### `shippingGroupMap`

{% hint style="warning" %}
Required if the `merchant_shipping_group_name` field is present in the feed file being converted.
{% endhint %}

This is a mapping of your account's shipping group names to their internal Amazon identifiers. Instructions on how to generate this mapping are here: [Inventory Loader](/feed-transformer/feed-types/tab/invloader.md#shippinggroupmap)

## Usage

To convert a `POST_FLAT_FILE_PRICEANDQUANTITYONLY_UPDATE_DATA` feed to the newer `JSON_LISTINGS_FEED` format:

```php
use SellingPartnerApi\FeedTransformer\Transformer;
use SellingPartnerApi\FeedTransformer\FeedTypes\PriceAndQuantityUpdateOnly;

// See the documentation referenced in the Parameters section for more information
// about what's going on in this line
$shippingGroupMap = Transformer::parseShippingGroups($jsonSchemaUrl);

$feedFile = 'path/to/your/feed.tab';
$json = Transformer::fromFile(
    PriceAndQuantityUpdateOnly::$feedType,
    $feedFile,
    'ATVPDKIKX0DER',
    [
        'merchantId' => 'A2DI..........',
        'shippingGroupMap' => $shippingGroupMap
    ]
);

$jsonFeedPath = 'path/to/new/feed.json';
file_put_contents($jsonFeedPath, json_encode($json));
```

##

## Known columns

This is an exhaustive list of the columns we support for this feed type. If you are successfully passing feed files with additional columns, [let us know](mailto:hi@highsidelabs.co) and we'll add support for the ones we're missing.

* `sku`
* `price`
* `quantity`
* `handling-time`


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.highsidelabs.co/feed-transformer/feed-types/tab/priceandquantityonly-update.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
