# Update affiliate
URL: /docs/api-reference/affiliates/update-affiliate
Description: Updates an existing affiliate.

**PUT** `https://www.promotekit.com/api/v1/affiliates/{id}`

Updates an existing affiliate.

## Authentication

Requires a Bearer token in the `Authorization` header.

## Parameters

- `id` (path): string (uuid) **(required)** - Resource UUID

## Request Body

- `email`: string (email) - Affiliate email
- `first_name`: string - First name
- `last_name`: string - Last name
- `payout_email`: string (email) - Payout email address
- `ref_code`: string - Unique code that goes at the end of the affiliate link
- `promo_code`: string - Stripe promo code (will be generated if it doesn't already exist in Stripe)
- `campaign_id`: string (uuid) - Campaign UUID to assign the affiliate to
- `approved`: boolean - Whether the affiliate has been approved to start promoting
- `banned`: boolean - Whether the affiliate is banned. Banned affiliates are not eligible for future commissions and payouts.
- `details`: string - Additional details
- `new_paid_referral_notifications`: boolean - Whether the affiliate receives email alerts when they make a new paid referral

## Responses

### 200 - Affiliate updated

- `success`: boolean **(required)**
- `data`: object **(required)**

### 400 - Invalid request

- `success`: boolean **(required)**
- `error`: object **(required)**

### 401 - Authentication failed

- `success`: boolean **(required)**
- `error`: object **(required)**

### 404 - Resource not found

- `success`: boolean **(required)**
- `error`: object **(required)**

### 429 - Rate limit exceeded

- `success`: boolean **(required)**
- `error`: object **(required)**