{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-personalize/json-schema/amazon-personalize-create-dataset-import-job-request-schema.json",
  "title": "CreateDatasetImportJobRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-personalize-dataset-import-job-api-openapi.yml#/components/schemas/CreateDatasetImportJobRequest",
  "type": "object",
  "properties": {
    "jobName": {
      "type": "string",
      "description": "The name for the dataset import job."
    },
    "datasetArn": {
      "type": "string",
      "description": "The ARN of the dataset that receives the imported data."
    },
    "dataSource": {
      "$ref": "#/$defs/DataSource"
    },
    "roleArn": {
      "type": "string",
      "description": "The ARN of the IAM role that has permissions to read from the Amazon S3 data source."
    },
    "tags": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Tag"
      },
      "description": "A list of tags to apply to the dataset import job."
    },
    "importMode": {
      "type": "string",
      "enum": [
        "FULL",
        "INCREMENTAL"
      ],
      "description": "Specify how to add the new records to an existing dataset. The default import mode is FULL. If you haven't imported bulk records into the dataset previously, you can only specify FULL. Specify FULL to overwrite all existing bulk data in your dataset. Data you imported individually is not replaced. Specify INCREMENTAL to append the new records to the existing data in your dataset. Amazon Personalize replaces any record with the same ID with the new one."
    },
    "publishAttributionMetricsToS3": {
      "type": "boolean",
      "description": "If you created a metric attribution, specify whether to publish metrics for this import job to Amazon S3"
    }
  },
  "required": [
    "jobName",
    "datasetArn",
    "dataSource"
  ],
  "$defs": {
    "DataSource": {
      "type": "object",
      "properties": {
        "dataLocation": {
          "type": "string",
          "description": "For dataset import jobs, the path to the Amazon S3 bucket where the data that you want to upload to your dataset is stored. For data deletion jobs, the path to the Amazon S3 bucket that stores the list of records to delete. For example: s3://bucket-name/folder-name/fileName.csv If your CSV files are in a folder in your Amazon S3 bucket and you want your import job or data deletion job to consider multiple files, you can specify the path to the folder. With a data deletion job, Amazon Personalize uses all files in the folder and any sub folder. Use the following syntax with a / after the folder"
        }
      }
    },
    "Tag": {
      "type": "object",
      "properties": {
        "tagKey": {
          "type": "string",
          "description": "One part of a key-value pair that makes up a tag. A key is a general label that acts like a category for more specific tag values."
        },
        "tagValue": {
          "type": "string",
          "description": "The optional part of a key-value pair that makes up a tag. A value acts as a descriptor within a tag category (key)."
        }
      },
      "required": [
        "tagKey",
        "tagValue"
      ]
    }
  }
}