---
title: "Create source"
method: POST
path: "/connectors/amazon_ads_v1/create-source"
tags: ["connectors.amazon_ads_v1"]
---

# Create source

`POST /connectors/amazon_ads_v1/create-source`

## Request

- Base URL: `https://headless.dataddo.com/customer-api/v1`
- URL: `https://headless.dataddo.com/customer-api/v1/connectors/amazon_ads_v1/create-source`
- Auth: none declared

Beta connector for Amazon's new Unified Ads API (`/adsApi/v1/...`), restricted to
Dataddo and L'Oréal accounts until the "Unified API — Beta" Reports resource it
depends on is confirmed stable. See `src/Connector/AmazonAds/` for the production
connector against Amazon's classic (v2 profiles / v3 reporting) API.

## Request body

- PostSourceAmazonAdsV1Input
  - `o_auth_id` string
  - `authorizer_id` string
  - `nullable_fields` boolean: Setting this parameter to true allows the use of null values. If set to false, default values for each data type will be used instead.
  - `ensure_data_types` object: Overrides the default data types of the produced Source schema, ensuring that each field is typed as specified.
  - `data_types` object: Overrides the default data types of the produced Source schema, ensuring that each field is typed as specified.
  - `connector_id` string
  - `template_id` string
  - `label` string
  - `allow_empty` boolean: Setting this parameter to true allows extraction operations to proceed even if they produce 0 rows. If set to false, the operation will result in an error if no rows are extracted.
  - `date_range` string, nullable
  - `advertiserAccountIds` string[]: Array of strings.
  - `reportTypes` string[]: Array of strings.
  - `attributes` string[]: Array of strings.
  - `currency` 'default' | 'AED' | 'ARS' | 'AUD' | 'AZN' | 'BBD' | 'BGN' | 'BMD' | 'BND' | 'BRL' | 'BSD' | 'CAD' | 'CHF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CZK' | 'DKK' | 'DOP' | 'EGP' | 'EUR' | 'GBP' | 'GHS' | 'GTQ' | 'HKD' | 'HUF' | 'IDR' | 'ILS' | 'INR' | 'JMD' | 'JPY' | 'KES' | 'KRW' | 'KYD' | 'KZT' | 'LBP' | 'LKR' | 'MAD' | 'MUR' | 'MXN' | 'MYR' | 'NAD' | 'NGN' | 'NOK' | 'NZD' | 'PAB' | 'PEN' | 'PHP' | 'PKR' | 'PLN' | 'QAR' | 'RON' | 'RUB' | 'SAR' | 'SEK' | 'SGD' | 'THB' | 'TRY' | 'TTD' | 'TWD' | 'TZS' | 'USD' | 'UYU' | 'VND' | 'XAF' | 'XCD' | 'XOF' | 'XPF' | 'ZAR': Currencies accepted by Amazon's `currencyOfView` report field (adsApi/v1, Beta) - all monetary metrics in the report get converted to this currency.
  - `granularity` 'date' | 'week' | 'day' | 'month' | 'year' | 'day_of_week' | 'hour' | 'date_range': Time breakdown of the report (adsApi/v1, Beta).
  - `use_extraction_timestamp` boolean
  - `use_hash` boolean
  - `use_date_start` boolean
  - `use_date_stop` boolean
  - `use_masked_columns` boolean
  - `hash_columns` string[]: Array of strings.
  - `masked_columns` string[]: Array of strings.

## Response `200`

Create source

- Source
  - `descriptors` Descriptor[]
    - `key` 'EMPTY' | 'DATABASE' | 'TABLE' | 'FILE' | 'FORMAT' | 'PATH' | 'WRITE_MODE' | 'SPREADSHEET_ID' | 'SPREADSHEET' | 'SHEET' | 'DATASET' | 'PROJECT' | 'SCHEMA' | 'TOPIC' | 'ACCOUNT' | 'TYPE' | 'REPORT' | 'GRANULARITY' | 'CHANNEL' | 'PROPERTY' | 'BUCKET'
    - `value` string: descriptor value
  - `external_id` string, nullable: The id of the document in external systems. By setting external_id you can link document with external systems id.
  - `is_locked` boolean: You may mark the document as locked to prevent accidental changes. When locked, the document cannot be modified or deleted.
  - `label` string
  - `description` string
  - `type` string
  - `customer_id` string
  - `created_at` integer
  - `updated_at` integer

---

[API](https://skmtc.dev/dataddo/apis/dataddo-headless-beta-api.md) · [All operations](https://skmtc.dev/dataddo/apis/dataddo-headless-beta-api/llms.txt) · [OpenAPI document](https://skmtc.dev/dataddo/apis/dataddo-headless-beta-api/revisions/dcfa2345bd10?raw)
