> ## Documentation Index
> Fetch the complete documentation index at: https://developers.leadwaycrm.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Note

> Update Note

Update Note

```http theme={null}
PUT https://services.leadconnectorhq.com/contacts/{contactId}/notes/{id}
```

## Autorización

<ParamField header="Authorization" type="string" required>
  Bearer token generado desde el portal Leadway. Ver [Autenticación](/authentication).
</ParamField>

<ParamField header="Version" type="string" required default="2021-07-28">
  Versión de la API.
</ParamField>

## Path parameters

<ParamField path="contactId" type="string" required default="sx6wyHhbFdRXh302LLNR">
  Contact Id
</ParamField>

<ParamField path="id" type="string" required default="ocQHyuzHvysMo5N5VsXc">
  Note Id
</ParamField>

## Body

<ParamField body="userId" type="string" default="GCs5KuzPqTls7vWclkEV" />

<ParamField body="body" type="string" default="lorem ipsum" />

<ParamField body="title" type="string" default="Follow-up summary" />

<ParamField body="color" type="string" default="#FFAA00" />

<ParamField body="pinned" type="boolean" default="False" />

## Respuestas

<Accordion title="200 - Successful response">
  <ResponseField name="note" type="object">
    <Expandable title="propiedades">
      <ResponseField name="id" type="string" default="HGPcayliwcdoUFzvbTok" />

      <ResponseField name="body" type="string" default="lorem ipsum" />

      <ResponseField name="userId" type="string" default="TUcmRxWrjqzJS8EjkxNK" />

      <ResponseField name="dateAdded" type="string" default="2021-07-08T12:02:11.285Z" />

      <ResponseField name="contactId" type="string" default="TUcmRxWrjqzJS8EjkxNK" />

      <ResponseField name="title" type="string" default="Follow-up summary" />

      <ResponseField name="color" type="string" default="#FFAA00" />

      <ResponseField name="pinned" type="boolean" default="False" />
    </Expandable>
  </ResponseField>

  ```json theme={null}
  {
    "note": {
      "id": "HGPcayliwcdoUFzvbTok",
      "body": "lorem ipsum",
      "userId": "TUcmRxWrjqzJS8EjkxNK",
      "dateAdded": "2021-07-08T12:02:11.285Z",
      "contactId": "TUcmRxWrjqzJS8EjkxNK",
      "title": "Follow-up summary",
      "color": "#FFAA00",
      "pinned": false
    }
  }
  ```
</Accordion>

<Accordion title="400 - Bad Request">
  ```json theme={null}
  {}
  ```
</Accordion>

<Accordion title="401 - Unauthorized">
  ```json theme={null}
  {}
  ```
</Accordion>

<Accordion title="422 - Unprocessable Entity">
  ```json theme={null}
  {}
  ```
</Accordion>

## Ejemplo

<CodeGroup>
  ```bash cURL theme={null}
  curl -X PUT 'https://services.leadconnectorhq.com/contacts/YOUR_contactId/notes/YOUR_id' \
    -H 'Authorization: Bearer YOUR_TOKEN' \
    -H 'Version: 2021-07-28' \
    -H 'Content-Type: application/json' \
    -d '{
    "userId": "GCs5KuzPqTls7vWclkEV",
    "body": "lorem ipsum",
    "title": "Follow-up summary",
    "color": "#FFAA00",
    "pinned": false
  }'
  ```

  ```javascript Node.js theme={null}
  const response = await fetch('https://services.leadconnectorhq.com/contacts/YOUR_contactId/notes/YOUR_id', {
    method: 'PUT',
    headers: {
      Authorization: `Bearer ${process.env.LEADWAY_TOKEN}`,
      Version: '2021-07-28',
      'Content-Type': 'application/json',
    },
    body: JSON.stringify({"userId": "GCs5KuzPqTls7vWclkEV", "body": "lorem ipsum", "title": "Follow-up summary", "color": "#FFAA00", "pinned": false}),
  });
  const data = await response.json();
  ```

  ```python Python theme={null}
  import os, requests
  response = requests.request(
      'PUT',
      'https://services.leadconnectorhq.com/contacts/YOUR_contactId/notes/YOUR_id',
      headers={
          'Authorization': f"Bearer {os.environ['LEADWAY_TOKEN']}",
          'Version': '2021-07-28',
          'Content-Type': 'application/json',
      },
      json={"userId": "GCs5KuzPqTls7vWclkEV", "body": "lorem ipsum", "title": "Follow-up summary", "color": "#FFAA00", "pinned": false},
  )
  data = response.json()
  ```

  ```php PHP theme={null}
  <?php
  $ch = curl_init('https://services.leadconnectorhq.com/contacts/YOUR_contactId/notes/YOUR_id');
  curl_setopt_array($ch, [
      CURLOPT_RETURNTRANSFER => true,
      CURLOPT_CUSTOMREQUEST => 'PUT',
      CURLOPT_HTTPHEADER => [
          'Authorization: Bearer ' . getenv('LEADWAY_TOKEN'),
          'Version: 2021-07-28',
          'Content-Type: application/json',
      ],
      CURLOPT_POSTFIELDS => json_encode({'userId': 'GCs5KuzPqTls7vWclkEV', 'body': 'lorem ipsum', 'title': 'Follow-up summary', 'color': '#FFAA00', 'pinned': false}),
  ]);
  $data = json_decode(curl_exec($ch), true);
  ```
</CodeGroup>
