> For the complete documentation index, see [llms.txt](https://docs.suggestic.com/graphql/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.suggestic.com/graphql/query/mutations/meal-plan/simplified-meal-tracking/create-a-meal-entry.md).

# Create a Meal Tracker Entry

Meal Tracking is a simplified version of food logging that only works for meal plan meals.

Use the `createMealEntry` mutation to add a meal entry for a specific meal. These created meal entries can be tracked by using the  [`mealTracker`](https://docs.suggestic.com/graphql/query/queries/meal-tracker) query.&#x20;

Meal entries can have an assigned value. For instance, if you want to skip a meal, you can send the `value: SKIPPED` as a parameter. Below you will find all the possible values a meal entry can have.

{% hint style="danger" %}
**Note:** Currently tracking service only supports [JWT authentication](https://docs.suggestic.com/graphql/graphql/authentication#jwt-authentication)
{% endhint %}

### **Required Arguments**

| Field    | Type   | Note                                                                                                                                                                                |
| -------- | ------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `mealId` | ID     | The meal ID (from the [meal plan](https://docs.suggestic.com/graphql/query/queries/meal-plan/meal-plan-1))                                                                          |
| `value`  | String | <p>Value of the meal. Possible values:</p><p><code>SKIPPED</code>, <code>ATE</code>, <code>OTHER\_FOLLOWING</code>, <code>OTHER\_NOT\_FOLLOWING</code>, and <code>DELETE</code></p> |

### Available Fields

The following fields will be displayed in the response:

| Field     | Type    | Note                                                                        |
| --------- | ------- | --------------------------------------------------------------------------- |
| `success` | Boolean | **True** if a meal entry has been created. Otherwise, it displays **False** |
| `message` | String  | Description of the result                                                   |

## Examples

The following examples will create a *skipped* meal entry&#x20;

### GraphQL Example

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

```graphql
mutation
{ createMealEntry(mealId:"TWVhbDoxMzUyMzE0" value: SKIPPED)
  {
    success
    message
  } 
  
}
```

{% endtab %}

{% tab title="Response" %}

```graphql
{
  "data": {
    "createMealEntry": {
      "success": true,
      "message": "Meal plan entry was successfully saved"
    }
  }
}
```

{% endtab %}
{% endtabs %}

### curl Example

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

```java
curl -XPOST 'https://production.suggestic.com/graphql' \
  -H 'Authorization: Bearer <User-JWT>' \
  -H 'Content-Type: application/json' \
--data-raw '{"query":"mutation { createMealEntry(mealId:\"TWVhbDoxMzUyMzE0\", value: SKIPPED) { success message } }"}'
```

{% endtab %}

{% tab title="Response" %}

```graphql
{
    "data": {
        "createMealEntry": {
            "success": true,
            "message": "Meal plan entry was successfully saved"
        }
    }
}
```

{% endtab %}
{% endtabs %}
