# ItemAttributeModifierHelper

`com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper`

**Since:** 2.3.0

Describes one configured item attribute modifier and where it applies.  
 ```js
const modifiers = Player.getPlayer()?.getMainHand().getComponents().getAttributeModifiers();  
if (modifiers != null) {
  for (const modifier of modifiers) {
    Chat.log(`${modifier.getAttributeId()}: ${modifier.getOperation()} ${modifier.getAmount()}`);  
  }
}
 ```

## Methods

### getAmount {#com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper_getAmount-}

```js
getAmount(): double
```

**Returns:** the modifier amount, interpreted according to its operation

### getAttributeId {#com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper_getAttributeId-}

```js
getAttributeId(): String
```

**Returns:** the attribute's registry ID, or `"[unregistered]"` for an inline attribute

### getModifierId {#com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper_getModifierId-}

```js
getModifierId(): String
```

**Returns:** this modifier's ID, separate from the attribute it changes

### getOperation {#com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper_getOperation-}

```js
getOperation(): String
```

**Returns:** the operation name, such as `"add_value"` or `"add_multiplied_base"`

### getSlotGroup {#com.jsmacrosce.jsmacros.client.api.helper.inventory.ItemAttributeModifierHelper_getSlotGroup-}

```js
getSlotGroup(): String
```

**Returns:** the equipment slot group name, such as `"mainhand"` or `"armor"`
