# Water and Hydration

Use the `updateHydration` mutation to increase or decrease the number of cups of water tracked.

### **Required Arguments**

| Argument | Type | Note                                                                                                             |
| -------- | ---- | ---------------------------------------------------------------------------------------------------------------- |
| `date`   | Date | The date when the water entries will be counted. Use the format: `YYYY-MM-DD`                                    |
| `action` | Date | Add the **INCREASE** or **DECREASE** value to specify if the amount of cup of water is increasing or decreasing. |

### **Available Fields**

| Field     | Type    | Note                                                                                   |
| --------- | ------- | -------------------------------------------------------------------------------------- |
| `success` | Boolean | **true:** If the entry has been created successfully. Otherwise, it displays **false** |
| `message` | String  | The message returns either if the information has been updated or not.                 |

### Example <a href="#example" id="example"></a>

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

```javascript
curl -XPOST 'https://production.suggestic.com/graphql' \
  -H 'Authorization: Bearer <User-JWT>' \
  -H 'Content-Type: application/json' \
 --data-raw '{"query": "mutation { updateHydration(date:\"2020-10-13\",action: INCREASE) {success message}}}"
}'{ "Authorization": "Token ", "Suggestic-Partner":"" }
```

{% endtab %}

{% tab title="Response" %}

```javascript
{
    "data": {
        "updateHydration": {
            "success": true,
            "message": "Hydration was successfully updated"
        }
    }
}
```

{% endtab %}
{% endtabs %}

### UI Example

<img src="/files/qKEuZ26ivvVTUc0ie4y5" alt="" data-size="original">


---

# 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/tracking/update-hydratation.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.
