# updateIngredient

> Required permission: RestaurantMenuWrite

Source: https://docs.gastrogate.io/docs/api/mutations/updateIngredient

```graphql
updateIngredient(
  restaurantId: ID!
  ingredientId: ID!
  patch: IngredientPatch!
): Ingredient
```

## Arguments

| Name | Type | Description |
| --- | --- | --- |
| `restaurantId` | [`ID`](https://docs.gastrogate.io/docs/api/types/ID.md)! |  |
| `ingredientId` | [`ID`](https://docs.gastrogate.io/docs/api/types/ID.md)! |  |
| `patch` | [`IngredientPatch`](https://docs.gastrogate.io/docs/api/types/IngredientPatch.md)! |  |

## Returns

[`Ingredient`](https://docs.gastrogate.io/docs/api/types/Ingredient.md)

## Example

```graphql
mutation UpdateIngredient($restaurantId: ID!, $ingredientId: ID!, $patch: IngredientPatch!) {
  updateIngredient(restaurantId: $restaurantId, ingredientId: $ingredientId, patch: $patch) {
    id
    nameEn
    nameSv
  }
}
```

```bash
curl https://api.thelocoapp.com/graphql \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $LOCO_API_KEY" \
  -d '{"query": "mutation { updateIngredient(...) { __typename } }"}'
```
