> For the complete documentation index, see [llms.txt](https://api.senderwiz.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://api.senderwiz.com/customer/subscribers/create-a-subscriber.md).

# Create a Subscriber

### 🆕 Create a Subscriber

Add a subscriber to your list with custom field data such as email, first name, and last name.

***

#### 🔹 HTTP Request

```http
POST API-URL/lists/LIST-UNIQUE-ID/subscribers
```

***

#### 🔸 URL Segments

| Segment          | Required | Description             |
| ---------------- | -------- | ----------------------- |
| `LIST-UNIQUE-ID` | Yes      | List unique identifier. |

***

#### 📤 POST Parameters

| Parameter | Type  | Required | Description                                                 |
| --------- | ----- | -------- | ----------------------------------------------------------- |
| `data`    | array | Yes      | Associative array with custom fields. `EMAIL` is mandatory. |

***

#### 🔐 Authorization Header

```
X-API-KEY: your-api-key-here
```

***

#### 💻 PHP Example

```php
// ADD SUBSCRIBER
$response = $endpoint->create('LIST-UNIQUE-ID', [
    'EMAIL'    => 'linda.smith@demo.com', // the confirmation email will be sent!!! Use valid email address
    'FNAME'    => 'Linda',
    'LNAME'    => 'Smith'
]);

// DISPLAY RESPONSE
echo '<hr /><pre>';
print_r($response->body);
echo '</pre>';
```

***

#### 📦 Sample JSON Response

```json
{
  "status": "success",
  "data": {
    "record": {
      "subscriber_uid": "xy918k4tvd731",
      "email": "linda.smith@demo.com",
      "ip_address": "192.168.25.101",
      "source": "api",
      "date_added": {
        "expression": "NOW()",
        "params": {}
      }
    }
  }
}
```
