# Update "own Food"

| Arguments      | Required | Type                                                                             |
| -------------- | -------- | -------------------------------------------------------------------------------- |
| `databaseId`   | True     | String!                                                                          |
| `name`         | false    | String                                                                           |
| `barcode`      | false    | String                                                                           |
| `brand`        | false    | String                                                                           |
| `ownNutrients` | true     | [OwnNutrients!](https://docs.suggestic.com/graphql/objects/common/own-nutrients) |
| `ownServing`   | true     | [OwnServing!](https://docs.suggestic.com/graphql/objects/common/own-serving)     |

{% tabs %}
{% tab title="Mutation" %}

```graphql
mutation {
  updateOwnMeal(
    name: "Avocado"
    brand: "HEB market"
    databaseId: "9c0e60ee-6a77-11eb-8f46-324f6bb126c1"
    ownServing:{
      equivalent: 110,
      name: "1 servings"
    },
    ownNutrients: {
      enercKcal: 220,
    	ca: 60,
      chocdf: 12,
      chole: 0,
      fams: 0,
      fapu: 0,
      fasat: 0,
      fat: 13,
      fatrn: 0,
      fe: 0,
      fibtg: 0,
      k: 0,
      na: 0,
      procnt: 13,
      sugar: 6,
      vitaIu: 0,
      vitc: 0
    }
  ) {
    success
    message
  }
}

```

{% endtab %}

{% tab title="Response" %}

```javascript
{
  "data": {
    "updateOwnMeal": {
      "success": true,
      "message": "Own Meal was successfully updated"
    }
  }
}
```

{% endtab %}
{% endtabs %}


---

# 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.suggestic.com/graphql/query/mutations/food-log/own-food-item/update-own-food.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.
