---
title: "Add Targets"
method: POST
path: "/api/v1/campaigns/{campaign_id}/targets"
tags: ["Campaigns"]
---

# Add Targets

`POST /api/v1/campaigns/{campaign_id}/targets`

Add targets to a campaign

## Path parameters

- `campaign_id` string, required — The ID of the campaign to add targets to.

## Request body

- AddTargetsRequest
  - `targets` TargetInput[], nullable — The list of targets as TargetInputs
    - `id` string — The ID of the target
    - `external_id` string, nullable — The external ID of the target
    - `phone_number` union, required — The phone number of the target
      - string
      - TargetInputPhoneNumber
        - `value` string, required — The phone number of the target
        - `operating_hours` WeekSchedule
          - `monday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `tuesday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `wednesday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `thursday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `friday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `saturday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `sunday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `tz` string
    - `fallback_phone_number` union — The fallback phone number of the target
      - string
      - TargetInputPhoneNumber
        - `value` string, required — The phone number of the target
        - `operating_hours` WeekSchedule
          - `monday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `tuesday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `wednesday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `thursday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `friday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `saturday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `sunday` TimeIntervalNoTz[]
            - `start` string, required — Clock time as the source writes it — "9:00", "13:30" and "1:30 PM" are all accepted; 12-hour times are converted on import.
            - `end` string, required — Clock time as the source writes it — "17:00", "12:00" and "5:00 PM" are all accepted; 12-hour times are converted on import.
          - `tz` string
    - `input_data` object — The input data of the target
    - `patient` PatientInput
      - `first_name` string, nullable — Patient first name
      - `last_name` string, nullable — Patient last name
      - `date_of_birth` string, nullable — Patient date of birth (YYYY-MM-DD)
      - `phone_number` string, nullable — Patient phone number
      - `external_id` string, nullable — Patient external ID (e.g. MRN)
      - `extra_data` object, nullable — Additional patient metadata
    - `pre_call_data` object, nullable — The pre-call data of the target
  - `launch` boolean — Whether to launch the targets immediately or only add them to the campaign
  - `allow_duplicates` boolean — When set to True all targets with and external ID already contained in the campaign will be ignored
  - `strict` boolean — When set to False, targets that fail validation are still uploaded; targets with an invalid phone number are marked as INVALID_PHONE_NUMBER when the call is about to be executed

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/getprosperapp/apis/prosper-voice.md) · [All operations](https://skmtc.net/getprosperapp/apis/prosper-voice/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/getprosperapp/prosper-voice/revisions/672ca50a9215/schema)
