> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sync.cdata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Job

> Creates a new jobs object with the specified parameters.



## OpenAPI

````yaml /26.3/en/rest-api/openapi-v1.json post /jobs
openapi: 3.0.1
info:
  title: CData OpenAPI
  version: 26.3.0
servers:
  - url: '{baseUrl}'
    variables:
      baseUrl:
        default: https://sync.example.com/api.rsc
        description: >-
          Base URL of your Sync instance, including scheme and application path
          (e.g. https://sync.example.com/api.rsc).
security: []
paths:
  /jobs:
    post:
      tags:
        - jobs
      summary: Create Job
      description: Creates a new jobs object with the specified parameters.
      operationId: createjobs
      requestBody:
        description: The jobs entity to post
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/jobs'
        required: true
      responses:
        '201':
          description: jobs created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/jobs'
        default:
          description: Unexpected error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CDataError'
      security:
        - basic: []
        - authtoken_header: []
        - authtoken_query: []
components:
  schemas:
    jobs:
      type: object
      properties:
        JobId:
          description: The id of the job.
          type: string
        JobName:
          description: The name of the job.
          type: string
        WorkspaceId:
          description: The id of the Workspace.
          type: string
        Source:
          description: The source connection, usually it is a value of Connection Name.
          type: string
        Destination:
          description: >-
            The destination connection, usually it is a value of Connection
            Name.
          type: string
        Scheduled:
          description: >-
            Set this to true to the job can be executed according to a specific
            scheduler, default is false.
          type: string
        ScheduledCron:
          description: The scheduler cron string.
          type: string
        NotifyWindowsEvent:
          description: >-
            Set this to true to write error messages to the Windows Application
            Event Log, default is false.
          type: string
        SendEmailNotification:
          description: >-
            Set this to true to send email notifications after jobs are
            completed, default is false.
          type: string
        NotifyEmailTo:
          description: The email address where notifications will be sent to.
          type: string
        NotifyEmailSubject:
          description: The email subject for notifications.
          type: string
        EmailErrorOnly:
          description: Send the error message only, default is false.
          type: string
        Verbosity:
          description: >-
            The log verbosity level of the job, where 0 represents None, 1
            represents Error, 2 represents Info, 3 represents Transfer, and 5
            represents Verbose, default is 0.
          type: string
        TableNamePrefix:
          description: A prefix for all tables being replicated.
          type: string
        UseGmtDateTime:
          description: >-
            Set this to true to synchronize times in the GMT time zone as
            opposed to local time, default is false.
          type: string
        TruncateTableData:
          description: >-
            Set this to true to delete all rows before each update, default is
            false.
          type: string
        DropTable:
          description: >-
            Set this to true to drop the table before each update, default is
            false.
          type: string
        AutoTruncateStrings:
          description: >-
            Set this to true to automatically truncate strings that are too
            large for the column size, default is true.
          type: string
        ContinueOnError:
          description: >-
            Set this to true to continue onto the next table when previous table
            throws error, default is true.
          type: string
        AlterSchema:
          description: >-
            Set this to true to add columns and alter data types if there is a
            mismatch between the source table metadata and the destination table
            metadata, default is true.
          type: string
        ReplicateInterval:
          description: >-
            Paired with ReplicateIntervalUnit, ReplicateInterval controls the
            time frames to split the data into when replicating, default is 180
            (days).
          type: string
        ReplicateIntervalUnit:
          description: >-
            Paired with ReplicateInterval, ReplicateIntervalUnit controls the
            time frames to split the data into when replicating. Values are
            minutes, hours, days, weeks, months, years, rows, default is days.
          type: string
        ReplicateStartDate:
          description: >-
            This option sets the minimum date to start replicating data from
            (yyyy-MM-dd).
          type: string
        BatchSize:
          description: Sets the size of batch.
          type: string
        CommandTimeout:
          description: Controls the timeout for destination connections， default is 300.
          type: string
        DeletionBehavior:
          description: How to handle Deleted records in the source, default is HardDelete.
          type: string
        OtherCacheOptions:
          description: A comma separated list of additional options to include.
          type: string
        CacheSchema:
          description: Assign a specific schema for the destination database.
          type: string
        PreJob:
          description: The code of Pre-Job event.
          type: string
        PostJob:
          description: The code of Post-Job event.
          type: string
        StatusConnection:
          description: Assign a specific connection to store the status of jobs.
          type: string
        Type:
          description: The type of job.
          type: string
        EnableParallelProcessing:
          description: Whether allow current job to support parallel processing of queries.
          type: string
        AutomaticJobRetry:
          description: Whether retry failed tasks, default is true for new jobs.
          type: string
        WorkerPool:
          description: The size of threads in worker pool, default is 2.
          type: string
        RowVersion:
          description: The version number of row information.
          type: integer
          format: int64
        LogicalReplicationSlot:
          description: >-
            The logical replication slot created for the Change Data Capture of
            PostgreSQL.
          type: string
        HistoryMode:
          description: Whether use the History Mode to replicate data, default is false.
          type: string
        Label#:
          description: The labels of Job or Transformation
          type: string
        WithHistory:
          description: >-
            When set this to true, return info contains history, default is
            false.
          type: string
        HistoryId:
          description: The historyId of Job, default is 0.
          type: string
        ResetStrategy:
          description: The strategy of resetting data in the Reverse ETL job
          type: string
        LicenseState:
          description: Whether the job is valid or invalid based on the license.
          type: string
        LicenseMessage:
          description: Details for why the job is invalid.
          type: string
        PublicationName:
          description: >-
            The name of the PostgreSQL publication created for streaming
            changes. This publication is created at start-up if it does not
            already exist.
          type: string
        PluggableDatabase:
          description: >-
            Enhanced oracle proprietary property. Name of the Oracle pluggable
            database to connect to. Use this property with container database
            (CDB) installations only.
          type: string
        AdditionalCDCEngineProperties:
          description: >-
            A comma separated list of additional CDC engine properties to pass
            to the underlying engine in the format key=value.
          type: string
        InsertMode:
          description: >-
            Whether to create and insert into a new file for every batch or
            write all rows into a single file.
          type: string
        TableNameSuffix:
          description: A Suffix for all tables being replicated.
          type: string
        LoadFolderFileNamePattern:
          description: >-
            The file name pattern to load files from a folder, default is
            "NAME_WITH_EXT".
          type: string
        SkipFormulaFields:
          description: >-
            Set this to true, current job will skip all formula fields for the
            Salesforce source, default is false.
          type: boolean
        SourceSchema:
          description: Enhanced DB2 iSereies property. Name of the schema to connect to.
          type: string
        JournalLibrary:
          description: Enhanced DB2 iSeries property. Name of the journal library.
          type: string
        JournalName:
          description: Enhanced DB2 iSeries property. Name of the journal.
          type: string
        SnapshotSize:
          description: This option sets the size of the snapshot
          type: integer
          format: int64
        SkipSnapshot:
          description: This option sets whether we have to skip the snapshot or not
          type: boolean
        CDCEngineModeEnabled:
          description: Whether CDC Engine mode is enabled.
          type: boolean
        CanUpdate:
          description: Whether the current entity can be updated.
          type: string
        CanRemove:
          description: Whether the current entity can be removed.
          type: string
        CanExecute:
          description: Whether the current entity can be executed.
          type: string
      required:
        - JobName
    CDataError:
      type: object
      properties:
        error:
          $ref: '#/components/schemas/CDataInError'
    CDataInError:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
  securitySchemes:
    basic:
      scheme: basic
      type: http
    authtoken_header:
      type: apiKey
      in: header
      name: x-cdata-authtoken
    authtoken_query:
      type: apiKey
      in: query
      name: '@authtoken'

````