# Edit Transaction Note

## Editing a Transaction Note

Initiate a mutation to edit an existing transaction note according to a Transaction ID.

Existing notes that are empty/`null` can also be edited and changed.

```graphql
mutation UpdateTransaction($data: TransactionUpdateInput!, $where: TransactionWhereUniqueInput!) {
  updateTransaction(data: $data, where: $where) {
    id
  }
}
```

### **Headers**

| Name          | Value              |
| ------------- | ------------------ |
| Content-Type  | `application/json` |
| Authorization | `Bearer <token>`   |

### Body (<mark style="color:orange;">TransactionUpdateInput</mark>) object + (<mark style="color:orange;">TransactionWhereUniqueInput</mark>) object

| Name                                   | Type   | Description          |
| -------------------------------------- | ------ | -------------------- |
| note<mark style="color:red;">\*</mark> | String | New transaction note |
| Id<mark style="color:red;">\*</mark>   | String | Transaction ID       |

Example body:

```graphql
{
  "data": {
    "note": "made by api Admin"
  },
  "where": {
    "id": "clpgvrjb700136g01lr3o0tgv"
  }
}
```

### Response

Return values:

| Name | Type   | Description            |
| ---- | ------ | ---------------------- |
| id   | String | Updated Transaction ID |

{% tabs %}
{% tab title="🟢 Success" %}

```javascript
{
  "data": {
    "updateTransaction": {
      "id": "clpgvrjb700136g01lr3o0tgv",
    }
  }
}
```

{% endtab %}

{% tab title="🔴 Failure" %}

{% endtab %}
{% endtabs %}

### Try it out!

{% embed url="<https://studio.apollographql.com/sandbox/explorer?endpoint=https%3A%2F%2Fapi.inabit.app%2Fgraphql&explorerURLState=N4IgJg9gxgrgtgUwHYBcQC4RxighigSwiQAIBVABzHwQBUAnXJAZ1ykOIAoASavdEgyat2RJJT4IAkkgo4AhABoS3AO4ALBPQQChLNhyQB1TdrJICARxjTZCgJQlgAHVIkYVGnpGHOfXAK8%2BLjKGlo6KmHaji5uJCQEYK7xAL6uKSApQA>" %}


---

# 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.inabit.com/api-reference/develop-with-inabit-api/transactions/edit-transaction-note.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.
