Skip to main content
PUT
/
public
/
v1
/
contacts
/
{id}
Python
import requests

url = 'https://api.minimo.it/public/v1/contacts/42'
headers = {'Authorization': 'Bearer {{BEARER_TOKEN}}', 'Content-Type': 'application/json'}
data = {'email': 'new-email@example.com'}
response = requests.put(url, json=data, headers=headers)
print(response.json())
{
  "id": 123,
  "phone": "<string>"
}
Unlike the upsert endpoint which matches by email or phone, this endpoint updates a specific contact by their ID. Use this when you need a deterministic update by ID — especially when changing a contact’s email address.

When to Use This

ScenarioUse this endpointUse upsert instead
Change a contact’s emailYesOnly if phone number is also provided (upsert falls back to phone matching)
Update a known contact by IDYesEither works
Create a new contactNo (returns 404)Yes
Update by email/phone matchNoYes

How It Works

  • Only provided fields are updated — omitted fields are preserved
  • Custom fields are deep merged — existing custom fields not included in the request are kept
  • Automations are triggered — field change detection and automation triggers work the same as upsert
  • Soft-deleted contacts are restored — if the contact was deleted, it will be restored with the provided data
Update channel-specific marketing consent for a contact:
{
  "marketingConsent": {
    "email": true,
    "whatsapp": false
  }
}
FieldTypeDescription
emailbooleanEmail marketing opt-in (true) or opt-out (false)
whatsappbooleanWhatsApp marketing opt-in (true) or opt-out (false)
Both fields are optional. Omitting a channel leaves its current consent status unchanged. Setting true opts the contact in, false opts them out.
This endpoint does not create new contacts. If no contact exists with the given ID, a 404 error is returned.

Example: Change a Contact’s Email

1

Look up the contact by email

curl --request GET \
  --url 'https://api.minimo.it/public/v1/contacts/by-email/old@example.com' \
  --header 'Authorization: Bearer mn-YOUR_CLIENT_ID-YOUR_API_KEY'
Response: { "data": { "id": 42, "email": "old@example.com", ... } }
2

Update using the contact ID

curl --request PUT \
  --url 'https://api.minimo.it/public/v1/contacts/42' \
  --header 'Authorization: Bearer mn-YOUR_CLIENT_ID-YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{ "email": "new@example.com" }'

Common Errors

ErrorCauseSolution
not_foundNo contact with this IDVerify the contact ID
unauthorizedInvalid API keyVerify API key in Authorization header

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
integer
required

Contact ID

Body

application/json
email
string

New email address

phone
string

New phone number

customFields
object

Custom fields to update (merged with existing)

Channel-specific marketing consent preferences

Response

Contact updated

id
integer

Contact ID

Example:

42

phone
string | null

Phone number

Example:

"+393391234567"