> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stateset.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Return Line Item

> This endpoint updates an existing return line item.

### Body

<ParamField body="id" name="id" type="string">
  This is the id of the return line item.
</ParamField>

<ParamField body="amount" name="amount" type="string">
  This is the amount of the return line item.
</ParamField>

<ParamField body="condition" name="condition" type="string">
  This is the condition of the return line item.
</ParamField>

<ParamField body="flat_rate_shipping" name="flat_rate_shipping" type="string">
  This is the flat rate shipping of the return line item.
</ParamField>

<ParamField body="name" name="name" type="string">
  This is the name of the return line item.
</ParamField>

<ParamField body="price" name="price" type="string">
  This is the price of the return line item.
</ParamField>

<ParamField body="return_id" name="return_id" type="string">
  This is the id of the return associated with the line item.
</ParamField>

<ParamField body="serial_number" name="serial_number" type="string">
  This is the serial number of the return line item.
</ParamField>

<ParamField body="sku" name="sku" type="string">
  This is the sku of the return line item.
</ParamField>

<ParamField body="tax_refunded" name="tax_refunded" type="string">
  This is the tax refunded of the return line item.
</ParamField>

### Response

<ResponseField name="id" type="string">
  This is the id of the return line item.
</ResponseField>

<ResponseField name="amount" type="string">
  This is the amount of the return line item.
</ResponseField>

<ResponseField name="condition" type="string">
  This is the condition of the return line item.
</ResponseField>

<ResponseField name="flat_rate_shipping" type="string">
  This is the flat rate shipping of the return line item.
</ResponseField>

<ResponseField name="name" type="string">
  This is the name of the return line item.
</ResponseField>

<ResponseField name="price" type="string">
  This is the price of the return line item.
</ResponseField>

<ResponseField name="return_id" type="string">
  This is the id of the return associated with the line item.
</ResponseField>

<ResponseField name="serial_number" type="string">
  This is the serial number of the return line item.
</ResponseField>

<ResponseField name="sku" type="string">
  This is the sku of the return line item.
</ResponseField>

<ResponseField name="tax_refunded" type="string">
  This is the tax refunded of the return line item.
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl --location --request PUT 'https://api.stateset.com/v1/return_line_item' \
  --header 'Content-Type: application/json' \
  --header 'Authorization: Token <token>' \
  --data-raw '{
      "user_group_id": "example_1",
      "name": "Example 1",
      "mapping": {"40": "213", "134": "386"},
      "properties": {"filterValue": "value"}
  }'
  ```

  ```js Node.js theme={null}
  const returnLineItem = await stateset.returnItem.update({
    '0901f083-aa1c-43c5-af5c-0a9d2fc64e30'
  });

  ```

  ```graphQL GraphQL theme={null}

                 mutation (
                  $id: uuid
                  $return_line_item: return_line_items_set_input!
                ) {
                  update_return_line_items (
                  where: { id : { _eq: $id }}
                  _set: $return_line_item
                  ) {
                    returning {
                      id
                      sku
                      name
                      price
                      tax_refunded
                      condition
                      amount
                      flat_rate_shipping
                    }
                  }
                }
  ```

  ```python Python theme={null}

  return_line_item = stateset.ReturnItem.modify(
      id='0901f083-aa1c-43c5-af5c-0a9d2fc64e30',
      return_line_item={
          'sku': 'example_1',
          'name': 'Example 1',
          'price': 100,
          'tax_refunded': 0,
          'condition': 'new',
          'amount': 1,
          'flat_rate_shipping': 0
      }
  )

  ```

  ```ruby Ruby theme={null}

  return_line_item = Stateset::ReturnItem.update(
      id: '0901f083-aa1c-43c5-af5c-0a9d2fc64e30',
      return_line_item: {
          sku: 'example_1',
          name: 'Example 1',
          price: 100,
          tax_refunded: 0,
          condition: 'new',
          amount: 1,
          flat_rate_shipping: 0
      }
  )

  ```

  ```php PHP theme={null}

  $return_line_item = $stateset->return_line_item->update(
      '0901f083-aa1c-43c5-af5c-0a9d2fc64e30',
      [
          'sku' => 'example_1',
          'name' => 'Example 1',
          'price' => 100,
          'tax_refunded' => 0,
          'condition' => 'new',
          'amount' => 1,
          'flat_rate_shipping' => 0
      ]
  );

  ```

  ```go Golang theme={null}

  returnLineItem, err := stateset.ReturnLineItem.Update(
      "0901f083-aa1c-43c5-af5c-0a9d2fc64e30",
      stateset.ReturnLineItem{
          Sku: "example_1",
          Name: "Example 1",
          Price: 100,
          TaxRefunded: 0,
          Condition: "new",
          Amount: 1,
          FlatRateShipping: 0
      }
  )

  ```

  ```java Java theme={null}

  ReturnLineItem returnLineItem = stateset.returnLineItem.update(
      "0901f083-aa1c-43c5-af5c-0a9d2fc64e30",
      new ReturnLineItem(
          "example_1",
          "Example 1",
          100,
          0,
          "new",
          1,
          0
      )
  );

  ```

  ```csharp CSharp theme={null}

  var returnLineItem = await stateset.ReturnLineItem.Update(
      "0901f083-aa1c-43c5-af5c-0a9d2fc64e30",
      new ReturnLineItem()
      {
          Sku = "example_1",
          Name = "Example 1",
          Price = 100,
          TaxRefunded = 0,
          Condition = "new",
          Amount = 1,
          FlatRateShipping = 0
      }
  );

  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
      "data": {
          "insert_return_line_items": {
              "returning": [
                  {
                      "id": "0901f083-aa1c-43c5-af5c-0a9d2fc64e30",
                      "sku": "123456789",
                      "name": "Example Item",
                      "price": 100,
                      "condition": "New",
                      "serial_number": "123456789",
                      "amount": 1,
                      "return_id": "0901f083-aa1c-43c5-af5c-0a9d2fc64e30"
                  }
              ]
          }
      }
  }
  ```
</ResponseExample>
