> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.youratlas.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.youratlas.com/_mcp/server.

# Create campaign

POST https://api.youratlas.com/v1/api/campaign
Content-Type: application/json

Creates a campaign of one of four types: outbound phone, inbound phone,
voice bubble (web), or Messages/SMS. The channel is set via the
combination of `campaignType`, `CallType`, `MessagesCampaign`, and
`Position`:

> **Next step — create an agent.** A campaign on its own is just the
> shell (channel, language, phone numbers, schedule). The voice,
> scripts, model, and conversational behavior all live on an **agent**
> attached to the campaign. After this request returns the campaign
> ID, call `POST /agent/new/{campaignId}` (template-driven) or
> `POST /agent/{campaignId}` (inline configuration) to attach an
> agent. Without an agent, the campaign cannot place or receive
> calls/messages.

| Campaign type      | `campaignType` | `CallType` | `MessagesCampaign` | `Position`                                                                     |
| ------------------ | -------------- | ---------- | ------------------ | ------------------------------------------------------------------------------ |
| Outbound phone     | `"1"`          | `"2"`      | omit               | omit                                                                           |
| Inbound phone      | `"1"`          | `"1"`      | omit               | omit                                                                           |
| Voice bubble (web) | `"0"`          | omit       | omit               | `"bottom-right"` \| `"bottom-left"` \| `"bottom-center"` \| `"not-positioned"` |
| Messages / SMS     | `"0"`          | omit       | `true`             | omit                                                                           |

### Picking a `TemplateId`

`TemplateId` is **required**. Pick one from the catalog below — match
on the user's selected language and on the campaign channel (`type`
column maps to the channel: `outbound`, `inbound`, `web` for voice
bubble, `messages` for SMS). Pass the chosen `Template ID` as
`TemplateId` in the request body.

Supported languages: `en-US` (English), `es-US` (Spanish), `de`
(German), `ro-RO` (Romanian), `fr-FR` (French), `hi-IN` (Hindi),
`he-IL` (Hebrew), `tr-TR` (Turkish), `multilanguage` (Multilingual).

#### English (`en-US`)

| Type     | Title                               | Template ID                            |
| -------- | ----------------------------------- | -------------------------------------- |
| web      | Voice Bubble - Create from scratch  | `572cea7c-851b-430d-ad34-2df87cf78745` |
| web      | Voice Bubble - Auto Dealership      | `860556f3-773a-4b3a-ad6d-9cf644d06490` |
| web      | Voice Bubble – Real Estate          | `8c2245d0-db09-4549-94ec-7f3becb8f8ff` |
| web      | Voice Bubble – Renovations          | `233a6ba7-564c-428e-9273-2d736f2a1710` |
| web      | Voice Bubble – MedSpa               | `8560cf24-eaf5-4de1-ad5f-f5d591bd6573` |
| outbound | Outbound - Create from scratch      | `6be44833-9133-4639-b6c9-425aee057c1c` |
| outbound | Outbound - Sales Qualifications     | `ca2cedc2-c196-40d2-be22-dfd70bb4594c` |
| outbound | Outbound - Appointment Confirmation | `303ae519-237a-4377-bc4b-c112da869210` |
| outbound | Outbound - Customer Service         | `391d2252-056b-48e6-8147-fb81c11c9a4f` |
| inbound  | Inbound - Create from scratch       | `b169095e-4b52-4002-9c0f-6d860d8f69f2` |
| inbound  | Inbound - Receptionist              | `ef425178-b820-460f-b4a2-1f8704487343` |
| inbound  | Inbound - Sales                     | `994c1320-b5c8-4ba6-af47-65f29caefaac` |
| inbound  | Inbound - Customer Service          | `28eb844e-5d43-4469-b422-d8cbb08ddba4` |
| messages | Messages - Create from scratch      | `4371c8a9-f3c4-4b11-aa15-871870869fec` |
| messages | Messages - Sales Qualifications     | `5b993906-231b-406b-bfb9-6188449e7a29` |
| messages | Messages - Appointment Confirmation | `93bd6c73-17f7-4e91-aee3-daaaa1fee598` |
| messages | Messages - Customer Service         | `54f23536-c34c-446e-8bfc-b089e68ec3e1` |

#### Spanish (`es-US`)

| Type     | Title                                | Template ID                            |
| -------- | ------------------------------------ | -------------------------------------- |
| outbound | Outbound - Multilingual En & Spanish | `3d9f7b06-5ff9-47ad-bc9b-89d0d504fd80` |
| outbound | Outbound - ESPAÑOL                   | `bf608583-a352-4cbc-8a4f-24e3b516c95e` |
| inbound  | Inbound - Multilingual En & Spanish  | `937764af-80bf-4d3a-ba9d-5d0ffc62b5eb` |
| inbound  | Inbound - ESPAÑOL                    | `8f77d0cb-a198-4ec1-b202-442f1d7668ec` |
| messages | Messages - Multilingual En & Spanish | `3d9f7b06-5ff9-47ad-bc9b-89d0d504fd80` |
| messages | Messages - ESPAÑOL                   | `bf608583-a352-4cbc-8a4f-24e3b516c95e` |

#### German (`de`)

| Type     | Title                   | Template ID                            |
| -------- | ----------------------- | -------------------------------------- |
| web      | Von Grund auf erstellen | `422566c4-7408-4332-ae4c-5cf0c4640220` |
| outbound | Von Grund auf erstellen | `422566c4-7408-4332-ae4c-5cf0c4640220` |
| inbound  | Von Grund auf erstellen | `422566c4-7408-4332-ae4c-5cf0c4640220` |
| messages | Von Grund auf erstellen | `422566c4-7408-4332-ae4c-5cf0c4640220` |

#### Romanian (`ro-RO`)

| Type     | Title                  | Template ID                            |
| -------- | ---------------------- | -------------------------------------- |
| inbound  | Șablon pentru Inbound  | `761a6468-53e1-48ae-b21b-0f1e5c5c4585` |
| outbound | Șablon pentru Outbound | `23e344d1-39cb-4f64-9c9b-122f0903afbf` |
| web      | Șablon pentru web      | `761a6468-53e1-48ae-b21b-0f1e5c5c4585` |
| messages | Șablon pentru Messages | `23e344d1-39cb-4f64-9c9b-122f0903afbf` |

#### French (`fr-FR`)

| Type     | Title                | Template ID                            |
| -------- | -------------------- | -------------------------------------- |
| inbound  | Modèle pour Inbound  | `fd09500c-b572-41f7-b703-774e718c40fd` |
| outbound | Modèle pour Outbound | `bf23d52a-c57e-4744-969b-a6c5b5c25b9e` |
| web      | Modèle pour web      | `fd09500c-b572-41f7-b703-774e718c40fd` |
| messages | Modèle pour Messages | `bf23d52a-c57e-4744-969b-a6c5b5c25b9e` |

#### Hindi (`hi-IN`)

| Type     | Title               | Template ID                            |
| -------- | ------------------- | -------------------------------------- |
| outbound | Create From Scratch | `f2086e1d-8c61-4dba-9551-602526b4db2b` |
| inbound  | Create From Scratch | `f2086e1d-8c61-4dba-9551-602526b4db2b` |
| messages | Create From Scratch | `f2086e1d-8c61-4dba-9551-602526b4db2b` |

#### Hebrew (`he-IL`)

| Type     | Title       | Template ID                            |
| -------- | ----------- | -------------------------------------- |
| inbound  | להתחיל מאפס | `ca905bb8-35a5-4f47-8511-285d3804df1b` |
| outbound | להתחיל מאפס | `ca905bb8-35a5-4f47-8511-285d3804df1b` |
| web      | להתחיל מאפס | `ca905bb8-35a5-4f47-8511-285d3804df1b` |
| messages | להתחיל מאפס | `ca905bb8-35a5-4f47-8511-285d3804df1b` |

#### Turkish (`tr-TR`)

| Type     | Title                       | Template ID                            |
| -------- | --------------------------- | -------------------------------------- |
| outbound | Sıfırdan oluşturmak - Giden | `951c250e-b776-4550-8c87-a6282878a8bc` |
| inbound  | Sıfırdan oluşturmak - Gelen | `951c250e-b776-4550-8c87-a6282878a8bc` |
| web      | Sıfırdan oluşturmak - Web   | `951c250e-b776-4550-8c87-a6282878a8bc` |
| messages | Sıfırdan oluşturmak         | `951c250e-b776-4550-8c87-a6282878a8bc` |

#### Multilingual (`multilanguage`)

| Type     | Title        | Template ID                            |
| -------- | ------------ | -------------------------------------- |
| web      | Multilingual | `937764af-80bf-4d3a-ba9d-5d0ffc62b5eb` |
| inbound  | Multilingual | `937764af-80bf-4d3a-ba9d-5d0ffc62b5eb` |
| outbound | Multilingual | `3d9f7b06-5ff9-47ad-bc9b-89d0d504fd80` |
| messages | Multilingual | `3d9f7b06-5ff9-47ad-bc9b-89d0d504fd80` |

### Outbound phone

```json
{
  "name": "My Outbound Campaign",
  "campaignType": "1",
  "CallType": "2",
  "CompanyName": "Acme Inc",
  "BusinessName": "Acme",
  "TemplateId": "6be44833-9133-4639-b6c9-425aee057c1c",
  "FirstMessage": "Hi, this is...",
  "ScriptBase": "...",
  "ScriptNotes": "...",
  "Timezone": "America/New_York",
  "TimezoneFriendlyName": "Eastern Time",
  "StartDate": "2026-05-14",
  "TimeWindows": "[{\"startHour\":8,\"startMinute\":0,\"endHour\":20,\"endMinute\":0}]",
  "FeatureRescheduleCallEnabled": false,
  "FeatureEnrichmentInfoEnabled": false,
  "FeatureAppendPreviousSummaryEnabled": false
}
```

### Inbound phone

Inbound is always-on — drop `StartDate`, `TimeWindows`, and
`FeatureRescheduleCallEnabled`. `FeatureAppendPreviousSummaryEnabled`
is inbound-only.

```json
{
  "name": "My Inbound Campaign",
  "campaignType": "1",
  "CallType": "1",
  "CompanyName": "Acme Inc",
  "BusinessName": "Acme",
  "TemplateId": "6be44833-9133-4639-b6c9-425aee057c1c",
  "FirstMessage": "Thanks for calling Acme...",
  "ScriptBase": "...",
  "ScriptNotes": "...",
  "Timezone": "America/New_York",
  "TimezoneFriendlyName": "Eastern Time",
  "FeatureEnrichmentInfoEnabled": false,
  "FeatureAppendPreviousSummaryEnabled": true
}
```

### Voice bubble (web)

`campaignType: "0"`, no `CallType`, add `Position`. Drop phone-only
schedule fields and summary append.

```json
{
  "name": "My Voice Bubble",
  "campaignType": "0",
  "CompanyName": "Acme Inc",
  "BusinessName": "Acme",
  "Position": "bottom-right",
  "TemplateId": "6be44833-9133-4639-b6c9-425aee057c1c",
  "FirstMessage": "Hi! How can I help?",
  "ScriptBase": "...",
  "ScriptNotes": "...",
  "Timezone": "America/New_York",
  "TimezoneFriendlyName": "Eastern Time",
  "FeatureEnrichmentInfoEnabled": false
}
```

### Messages / SMS

`campaignType: "0"` + `MessagesCampaign: true`. No `CallType`,
no schedule windows (text is async).

```json
{
  "name": "My Messages Campaign",
  "campaignType": "0",
  "MessagesCampaign": true,
  "CompanyName": "Acme Inc",
  "BusinessName": "Acme",
  "TemplateId": "6be44833-9133-4639-b6c9-425aee057c1c",
  "FirstMessage": "Hey, this is Acme...",
  "ScriptBase": "...",
  "ScriptNotes": "...",
  "Timezone": "America/New_York",
  "TimezoneFriendlyName": "Eastern Time",
  "FeatureEnrichmentInfoEnabled": false
}
```

Reference: https://docs.youratlas.com/api-reference/atlas-api/campaigns/create-campaign

## Authentication

- `api-key` header (required) — Your Atlas API key. Get it from the Atlas Portal under Settings > API Keys.

## Request

### Body (application/json)

This endpoint expects a CampaignBody.

- `name` (string, required) — Required. Human-readable campaign name.
- `campaignType` (enum, required) — Required. Channel family. `"1"` = phone (inbound or outbound — set direction with `CallType`). `"0"` = non-phone (voice bubble or Messages/SMS — distinguished by `MessagesCampaign`).
  - Allowed values: `0`, `1`
- `TemplateId` (string, required) — Required. ID of a starter template. See the catalog tables in the `Create campaign` endpoint description — pick the row matching the user's language and the campaign channel (`outbound`, `inbound`, `web` for voice bubble, `messages` for SMS) and pass its Template ID here.
- `CallType` (enum, optional) — Required when `campaignType` is `"1"`, omit otherwise. Phone direction: `"1"` = inbound, `"2"` = outbound.
  - Allowed values: `1`, `2`
- `MessagesCampaign` (boolean, optional) — Optional. Set `true` (with `campaignType: "0"`) to create a Messages/SMS campaign. Omit for voice bubble.
- `Position` (enum, optional) — Required for voice bubble (`campaignType: "0"` with `MessagesCampaign` omitted). Voice bubble position on the host page. Omit for phone and Messages campaigns.
  - Allowed values: `bottom-right`, `bottom-left`, `bottom-center`, `not-positioned`
- `CompanyName` (string, optional) — Optional. Injected as \{\{companyName}} in the script.
- `BusinessName` (string, optional) — Optional. Display name shown to callers/visitors.
- `IsActive` (boolean, optional) — Optional. Whether the campaign is enabled at creation.
- `Mode` (boolean, optional) — Optional.
- `StartDate` (datetime, optional) — Optional. Outbound-only — first date the agent may begin dialing. Ignored for inbound, voice bubble, and Messages campaigns.
- `TimeWindows` (string, optional) — Optional. Outbound-only. JSON-encoded array of time-window objects. Each object must contain startHour (0–23), startMinute (0–59), endHour (0–23), and endMinute (0–59). Example: \[\{"startHour":9,"startMinute":0,"endHour":17,"endMinute":0}]. Ignored for inbound, voice bubble, and Messages campaigns.
- `FirstMessage` (string, optional) — Optional. Greeting the agent speaks at the start of every call.
- `PreScript` (string, optional) — Optional. Prepended to the agent prompt.
- `PostScript` (string, optional) — Optional. Appended to the agent prompt.
- `ScriptBase` (string, optional) — Optional. The agent's conversation script.
- `ScriptNotes` (string, optional) — Optional. Additional script guidance.
- `FeatureRescheduleCallEnabled` (boolean, optional) — Optional. Outbound-only — allow agent to reschedule calls.
- `FeatureEnrichmentInfoEnabled` (boolean, optional) — Optional. Toggle caller-info enrichment.
- `FeatureAppendPreviousSummaryEnabled` (boolean, optional) — Optional. Inbound-only — append previous call summary to context.
- `EnrichmentInfoProvider` (enum, optional) — Optional. Provider used for caller enrichment.
  - Allowed values: `custom`, `shopify`, `ghl`, `monday`, `hubspot`
- `EnrichmentInfoSettings` (string, optional) — Optional. JSON string of enrichment settings.
- `Timezone` (string, optional) — Optional. IANA timezone, e.g. `America/New_York`.
- `TimezoneFriendlyName` (string, optional) — Optional. Human-readable timezone label.
- `Status` (enum, optional) — Optional. Lifecycle state.
  - Allowed values: `archived`, `active`, `draft`
- `Collection` (string, optional) — Optional. Collection/group identifier.
- `ToolIds` (string, optional) — Optional. Comma-separated tool IDs.
- `SMSTrigger` (string, optional) — Optional. Trigger phrase that fires an SMS during a call.
- `SMSBody` (string, optional) — Optional. SMS body associated with the trigger.
- `FirstMessageMode` (enum, optional) — Optional. Who speaks first at call start.
  - Allowed values: `assistant-speaks-first`, `assistant-waits-for-user`, `assistant-speaks-first-with-model-generated-message`
- `EndCallMessage` (string, optional) — Optional. Message the agent says before hanging up.
- `VoicemailMessage` (string, optional) — Optional. Message left on voicemail.
- `AnalysisPlanSummaryPrompt` (string, optional) — Optional. Prompt used to summarize calls for analysis.
- `AnalysisPlanSuccessEvaluationPrompt` (string, optional) — Optional. Prompt used to evaluate whether the call achieved its goal.
- `AnalysisPlanStructuredDataPrompt` (string, optional) — Optional. Prompt used to extract structured data from calls.
- `FeatureEndCallWhenVoicemail` (boolean, optional) — Optional. End the call when voicemail is detected.
- `VoicemailDropMechanism` (enum, optional) — Optional. Voicemail drop strategy. `audio-detection` detects voicemail via audio analysis and drops a pre-recorded message. `ringless` delivers a voicemail without ringing the recipient's phone.
  - Allowed values: `audio-detection`, `ringless`
- `FeatureRedialOnNoResponse` (boolean, optional) — Optional. Retry call when there's no answer.
- `RedialSettings` (string, optional) — Optional. JSON string of redial settings.
- `FeatureDoubleCall` (boolean, optional) — Optional. Place two concurrent attempts.
- `DailyCallLimit` (integer, optional) — Optional. Maximum calls per day.
- `IdleMessages` (string, optional) — Optional. JSON string of idle messages.
- `IsOutboundChatActive` (boolean, optional) — Optional. Whether outbound chat is enabled.
- `ChatReplyPacingEnabled` (boolean, optional) — Optional. Messages campaigns only. When true, AI chat reply bubbles are paced with a typing indicator and a short delay before each send, making conversations feel more natural.
- `ChatReplyPacingSeconds` (integer, optional) — Optional. Messages campaigns only. Fixed per-bubble typing duration in seconds (1–60). When absent or 0 the duration is auto-calculated based on message length.

## Response

### 200

Campaign created

- `PartitionKey` (string, optional)
- `RowKey` (string, optional)
- `Timestamp` (datetime, optional)
- `odata.etag` (string, optional)
- `name` (string, optional)
- `campaignType` (string, optional)
- `Mode` (boolean, optional)
- `BusinessName` (string, optional)
- `CallType` (string, optional)
- `CompanyName` (string, optional)
- `FirstMessage` (string, optional)
- `IsActive` (boolean, optional)
- `PhoneNumberId` (string, optional)
- `Position` (string, optional)
- `ScriptBase` (string, optional)
- `ScriptNotes` (string, optional)
- `StartDate` (datetime, optional)
- `TimeWindows` (string, optional) — JSON-encoded array of time-window objects. Each object contains startHour (0–23), startMinute (0–59), endHour (0–23), and endMinute (0–59).
- `SuccessRequest` (integer, optional)
- `TemplateId` (string, optional)
- `TotalRequest` (integer, optional)
- `TotalTransfers` (integer, optional)
- `DailyCallLimit` (integer, optional)
- `KnowledgeBaseId` (string, optional)
- `KnowledgeBaseDataSetId` (string, optional) — Knowledge base dataset identifier
- `FeatureAppendPreviousSummaryEnabled` (boolean, optional)
- `PhoneNumberProvider` (string, optional)
- `FeatureRescheduleCallEnabled` (boolean, optional)
- `EnrichmentInfoSettings` (string, optional)
- `EnrichmentInfoProvider` (string, optional)
- `FeatureEnrichmentInfoEnabled` (boolean, optional)
- `EndCallMessage` (string, optional)
- `VoicemailMessage` (string, optional)
- `AnalysisPlanSummaryPrompt` (string, optional)
- `AnalysisPlanSuccessEvaluationPrompt` (string, optional)
- `AnalysisPlanStructuredDataPrompt` (string, optional)
- `FeatureEndCallWhenVoicemail` (boolean, optional)
- `VoicemailDropMechanism` (enum, optional) — Voicemail drop strategy. `audio-detection` detects voicemail via audio analysis and drops a pre-recorded message. `ringless` delivers a voicemail without ringing the recipient's phone.
  - Allowed values: `audio-detection`, `ringless`
- `FeatureRedialOnNoResponse` (boolean, optional)
- `RedialSettings` (string, optional) — JSON string of redial attempt configuration
- `FeatureDoubleCall` (boolean, optional)
- `Timezone` (string, optional)
- `TimezoneFriendlyName` (string, optional)
- `Status` (enum, optional)
  - Allowed values: `archived`, `active`, `draft`
- `Collection` (string, optional)
- `IdleMessages` (string, optional)
- `ToolIds` (string, optional)
- `SMSTrigger` (string, optional)
- `SMSBody` (string, optional)
- `ForwardingPhoneNumber` (string, optional)
- `PreScript` (string, optional)
- `PostScript` (string, optional)
- `FirstMessageMode` (enum, optional)
  - Allowed values: `assistant-speaks-first`, `assistant-waits-for-user`, `assistant-speaks-first-with-model-generated-message`
- `ChatPhoneNumberId` (string, optional)
- `IsOutboundChatActive` (boolean, optional)
- `ChatReplyPacingEnabled` (boolean, optional) — Whether AI chat reply pacing is enabled. When true, reply bubbles are sent with a typing indicator and a short delay, making conversations feel more natural. Messages campaigns only.
- `ChatReplyPacingSeconds` (integer, optional) — Fixed per-bubble typing duration in seconds (1–60). When absent or 0 the duration is auto-calculated based on message length. Messages campaigns only.
- `AIAssistantProvider` (enum, optional, nullable) — AI assistant runtime powering this campaign. Returns "atlas" when the campaign uses the Atlas runtime, or null otherwise.
  - Allowed values: `atlas`
- `TotalBooked` (double, optional)
- `AtlasKnowledgeBaseId` (string, optional)
- `MarketplaceAgentId` (string, optional)
- `AgentType` (string, optional)
- `language` (string, optional)
- `voiceId` (string, optional)

## Errors

### 400 Bad Request Error

Bad request

- `error` (ErrorError, optional)

### 500 Internal Server Error

Internal server error

- `error` (ErrorError, optional)

## Types

### ErrorError

- `message` (string, optional)
- `code` (string, optional)
- `requestId` (string, optional)

## Examples

**Request**

```json
{
  "name": "string",
  "campaignType": "0",
  "TemplateId": "string"
}
```

**Response**

```json
{
  "PartitionKey": "string",
  "RowKey": "string",
  "Timestamp": "2024-01-15T09:30:00Z",
  "odata.etag": "string",
  "name": "string",
  "campaignType": "string",
  "Mode": true,
  "BusinessName": "string",
  "CallType": "string",
  "CompanyName": "string",
  "FirstMessage": "string",
  "IsActive": true,
  "PhoneNumberId": "string",
  "Position": "string",
  "ScriptBase": "string",
  "ScriptNotes": "string",
  "StartDate": "2024-01-15T09:30:00Z",
  "TimeWindows": "string",
  "SuccessRequest": 1,
  "TemplateId": "string",
  "TotalRequest": 1,
  "TotalTransfers": 1,
  "DailyCallLimit": 1,
  "KnowledgeBaseId": "string",
  "KnowledgeBaseDataSetId": "string",
  "FeatureAppendPreviousSummaryEnabled": true,
  "PhoneNumberProvider": "string",
  "FeatureRescheduleCallEnabled": true,
  "EnrichmentInfoSettings": "string",
  "EnrichmentInfoProvider": "string",
  "FeatureEnrichmentInfoEnabled": true,
  "EndCallMessage": "string",
  "VoicemailMessage": "string",
  "AnalysisPlanSummaryPrompt": "string",
  "AnalysisPlanSuccessEvaluationPrompt": "string",
  "AnalysisPlanStructuredDataPrompt": "string",
  "FeatureEndCallWhenVoicemail": true,
  "VoicemailDropMechanism": "audio-detection",
  "FeatureRedialOnNoResponse": true,
  "RedialSettings": "string",
  "FeatureDoubleCall": true,
  "Timezone": "string",
  "TimezoneFriendlyName": "string",
  "Status": "archived",
  "Collection": "string",
  "IdleMessages": "string",
  "ToolIds": "string",
  "SMSTrigger": "string",
  "SMSBody": "string",
  "ForwardingPhoneNumber": "string",
  "PreScript": "string",
  "PostScript": "string",
  "FirstMessageMode": "assistant-speaks-first",
  "ChatPhoneNumberId": "string",
  "IsOutboundChatActive": true,
  "ChatReplyPacingEnabled": true,
  "ChatReplyPacingSeconds": 1,
  "AIAssistantProvider": "atlas",
  "TotalBooked": 1.1,
  "AtlasKnowledgeBaseId": "string",
  "MarketplaceAgentId": "string",
  "AgentType": "string",
  "language": "string",
  "voiceId": "string"
}
```

**SDK Code**

```python
import requests

url = "https://api.youratlas.com/v1/api/campaign"

payload = {
    "name": "string",
    "campaignType": "0",
    "TemplateId": "string"
}
headers = {
    "api-key": "<apiKey>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.youratlas.com/v1/api/campaign';
const options = {
  method: 'POST',
  headers: {'api-key': '<apiKey>', 'Content-Type': 'application/json'},
  body: '{"name":"string","campaignType":"0","TemplateId":"string"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.youratlas.com/v1/api/campaign"

	payload := strings.NewReader("{\n  \"name\": \"string\",\n  \"campaignType\": \"0\",\n  \"TemplateId\": \"string\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("api-key", "<apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.youratlas.com/v1/api/campaign")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["api-key"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"name\": \"string\",\n  \"campaignType\": \"0\",\n  \"TemplateId\": \"string\"\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.youratlas.com/v1/api/campaign")
  .header("api-key", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"name\": \"string\",\n  \"campaignType\": \"0\",\n  \"TemplateId\": \"string\"\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.youratlas.com/v1/api/campaign', [
  'body' => '{
  "name": "string",
  "campaignType": "0",
  "TemplateId": "string"
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'api-key' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.youratlas.com/v1/api/campaign");
var request = new RestRequest(Method.POST);
request.AddHeader("api-key", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"name\": \"string\",\n  \"campaignType\": \"0\",\n  \"TemplateId\": \"string\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "api-key": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = [
  "name": "string",
  "campaignType": "0",
  "TemplateId": "string"
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.youratlas.com/v1/api/campaign")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```