# Ends contact with a lead for a company's given campaign

`POST` `/api/v1/leads/end-contact`

Ends contact with a lead for a campaign upon company request. This does not create a DNC.

## Request

### Headers

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `x-api-key` | string | yes | The Aktify-provided API key. |

### Body

Content type: `application/json` (required)

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `phoneNumberList` | array<string> | yes | The list of phone numbers to end contact with in Aktify for the company. The entire request will fail if a phone number is not formatted correctly. Limited to a list of 50. Each phone number in the list must be unique. (Example: `["(509) 555-1234"]`) |

## Responses

### 201

Returns two lists, one for numbers that were successfully processed, and another list of phone numbers that failed to process correctly.

Response body (`application/json`):

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `success` | array<string> | yes | The list of phone numbers that successfully marked as end contact. The lead will not be outreached to unless they reach out first. The numbers will be in E.164 format. Numbers that were already submitted or if the lead has not been posted (outreached to) yet will be in the `success` field. (Example: `["+15095551234"]`) |
| `failure` | array<string> | yes | The list of phone numbers that failed to be marked as end contact. The numbers will be in E.164 format. This was likely due to a system error on our side, so feel free to retry. Notify us if the issue persists. (Example: `["+15095551234"]`) |

### 400

Returned if required fields are missing or any provide field is invalid. Additional details may be in the response body but are not included in the API contract.

### 401

Returned if the request was not authorized with a valid x-api-key header. Additional details may be in the response body but are not included in the API contract.
