> For the complete documentation index, see [llms.txt](https://documents.blocksurvey.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documents.blocksurvey.io/audience/update-contact.md).

# Update Contact

### **Overview**

Updates an existing contact in a specified list.

### Authentication

This request requires a `Authorization` header with a valid token.&#x20;

**URL:** `PUT https://api3.blocksurvey.io/contact/update-contact`

### Request Headers

| Key           | Value              | Description                 |
| ------------- | ------------------ | --------------------------- |
| Authorization | Bearer \<api\_key> | API key for authentication. |

### Request Body

| Field                                                              | Type   | Required | Description                                                             |
| ------------------------------------------------------------------ | ------ | -------- | ----------------------------------------------------------------------- |
| teamId                                                             | String | Yes      | ID of the team owning the list.                                         |
| listId                                                             | String | Yes      | ID of the list containing contact.                                      |
| listPublicKey                                                      | String | Yes      | Public key for encryption.                                              |
| recordId                                                           | String | No       | ID of the contact to update. Required if oldEmail is not provided.      |
| oldEmail                                                           | String | No       | Old email of the contact. Required if recordId is not provided.         |
| Email                                                              | String | No       | New email of the contact. If provided, oldEmail must also be included.. |
| <p>First Name</p><p>Last Name</p><p>Phone Number</p><p>Country</p> | String | No       | Additional column data.                                                 |

### cURL Example

```bash
curl -X PUT https://api3.blocksurvey.io/contact/update-contact
-H "Authorization: Bearer your-api-key" \
-H "Content-Type: application/json" \
-d '{
    "teamId": "team-123",
    "listId": "list-456",
    "listPublicKey": "base64-public-key",
    "recordId": "contact-789",
    "oldEmail": "old-email@example.com",
    "Email": "new-email@example.com",
    "First Name": "Jane"
}'
```

### Response

**Successful Response**

```json
Success (200)
{
    "success": true,
    "recordId": "contact-id"
}
```

<br>
