# Cambiar un remitente

Source: https://won.dev/es/docs/email/senders-update

`PATCH https://api.won.dev/v1/email/senders/{id}`

Declara la base legal para escribirle a gente en más regiones con reglas más estrictas, o vuelve a indicar la base de una región, y reemplaza la `metadata` del remitente. Solo cambian los campos que envías. Una región declarada queda declarada: las personas de ahí que entraron en campañas entraron por esa declaración. Cada declaración se registra con la hora y la clave que la hizo, y vale desde el siguiente destinatario que se agregue. El nombre de la empresa, la dirección y el sitio web son lo que cada correo dice de quién viene, así que no cambian: para otra empresa, registra un remitente nuevo. Gratis.

- **Cobro:** Gratis.

Una clave de prueba (`won_test_...`) ejecuta esto en el [sandbox](/es/docs/email#sandbox): no se envía ni se cobra nada.

## Parámetros [#parameters]

`id` va en la ruta. Los demás van en el cuerpo JSON. Las solicitudes `PATCH` también aceptan el encabezado `Idempotency-Key`; consulta [Enviar una solicitud dos veces](/es/docs/email#idempotency).

| Parámetro | Tipo | Obligatorio | Descripción (texto original de la API) |
| --- | --- | --- | --- |
| `id` | string | sí | Sender ID, such as `snd_4k2m9x7p1q8w3e5r`. |
| `regions` | object[] | no | Regions to declare a lawful basis for: each one is added, or replaces the basis given for it before. The others stay as they are. |
| `regions[].region` | `eu` \| `uk` \| `ca` | sí | `eu`, `uk` or `ca`. |
| `regions[].basis` | string | sí | Why you may write to people there, such as: legitimate interest, B2B contacts at companies that import our product category. |
| `metadata` | object | no | Your own keys and values, such as `{"customer_id": "c_812"}`: up to 20 keys of at most 40 characters, each value a string of at most 500. It replaces the metadata there is; `{}` removes it. Events that already happened keep what they carried. |

## Respuesta [#response]

Los errores se describen en [Errores](/es/docs/errors).

| Campo | Tipo | Descripción (texto original de la API) |
| --- | --- | --- |
| `data` | object |  |
| `data.id` | string | Sender ID, such as `snd_4k2m9x7p1q8w3e5r`. |
| `data.company_name` | string | The company the emails are sent for. Every email names it. |
| `data.address` | string | The company's postal address. Every email carries it. |
| `data.website` | string | The company's website. |
| `data.purpose` | string | What the company sends and to whom, as it was described to us. |
| `data.status` | `active` \| `rejected` \| `suspended` | `active`: it can send once it has a sending domain. `suspended` when its emails bounced or were reported as spam too often, or we stopped it; `rejected` when we did not let it send. The reason is in `review_note`. |
| `data.review_note` | string \| null | Why the sender was stopped, when it was. |
| `data.throttled` | boolean | True while it sends at half speed, because many people unsubscribed or one reported its emails as spam. A person looks at it and lifts it. |
| `data.regions` | object[] | Regions the sender declared a lawful basis for: `eu`, `uk`, `ca`. |
| `data.regions[].region` | `eu` \| `uk` \| `ca` |  |
| `data.regions[].basis` | string |  |
| `data.regions[].declared_at` | string |  |
| `data.metadata` | object | Your own keys and values, as you gave them. Empty when none were. |
| `data.test` | boolean | Made with a test key: it sends from a simulated domain, and never for real. |
| `data.created_at` | string | When it was created, as an ISO 8601 time in UTC. |
| `notice` | string \| null | A plain sentence when there is something to know about this answer. Null otherwise. |
| `usage` | object | Nothing is charged here. The balance, for reference. |
| `usage.cost` | number | What this call cost, in US dollars. |
| `usage.balance` | number | The balance left after this call, in US dollars. |
| `usage.replayed` | boolean | True when this is a repeat of a request from the last 24 hours. Repeats are free. |

## Ejemplo [#example]

```bash
curl -X PATCH https://api.won.dev/v1/email/senders/snd_4k2m9x7p1q8w3e5r \
  -H "Authorization: Bearer $WON_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "regions": [
    {
      "region": "uk",
      "basis": "Legitimate interest: B2B contacts at companies that import office furniture, in their work role."
    }
  ]
}'
```

```json
{
  "data": {
    "id": "snd_4k2m9x7p1q8w3e5r",
    "company_name": "Northwind Seating Ltd",
    "address": "18 Harbour Road, Leeds LS1 4AP, United Kingdom",
    "website": "https://northwind-seating.example",
    "purpose": "We make office chairs and write to furniture importers and distributors about our new catalogue.",
    "status": "active",
    "review_note": null,
    "throttled": false,
    "regions": [
      {
        "region": "uk",
        "basis": "Legitimate interest: B2B contacts at companies that import office furniture, in their work role.",
        "declared_at": "2026-11-21T09:30:00.000Z"
      }
    ],
    "metadata": {
      "customer_id": "c_812"
    },
    "test": false,
    "created_at": "2026-11-17T09:12:44.000Z"
  },
  "notice": null,
  "usage": {
    "cost": 0,
    "balance": 48.08,
    "replayed": false
  }
}
```