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

# /preview/marketing-solutions/campaigns

> Patch a list of Campaigns.
            
A campaign, or in other words a marketing campaign, is an entity that defines advertising objectives and success criteria.



## OpenAPI

````yaml https://api.criteo.com/preview/marketingsolutions/open-api-specifications.json patch /preview/marketing-solutions/campaigns
openapi: 3.0.1
info:
  title: Criteo API
  description: Criteo API - MarketingSolutions
  version: Preview
servers:
  - url: https://api.criteo.com
security:
  - oauth: []
tags:
  - name: Advertiser
  - name: Analytics
  - name: Audience
  - name: Campaign
  - name: Catalog
  - name: Creative
  - name: Gateway
  - name: OnSiteRecommendation
  - name: Reco
paths:
  /preview/marketing-solutions/campaigns:
    patch:
      tags:
        - Campaign
      summary: /preview/marketing-solutions/campaigns
      description: "Patch a list of Campaigns.\r\n            \r\nA campaign, or in other words a marketing campaign, is an entity that defines advertising objectives and success criteria."
      operationId: PatchCampaigns
      requestBody:
        description: List of campaigns to patch.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PatchCampaignListRequest'
        required: true
        x-bodyName: request
      responses:
        '200':
          description: List of patched campaigns.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PatchResultCampaignListResponse'
      security:
        - oauth:
            - MarketingSolutions_Campaign_Manage
components:
  schemas:
    PatchCampaignListRequest:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/PatchCampaignWriteResource'
          nullable: true
      description: List of input resources
    PatchResultCampaignListResponse:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/PatchResultCampaignReadResource'
          nullable: true
          readOnly: true
        errors:
          type: array
          items:
            $ref: '#/components/schemas/CommonProblem'
          nullable: true
          readOnly: true
        warnings:
          type: array
          items:
            $ref: '#/components/schemas/CommonProblem'
          nullable: true
          readOnly: true
      description: List of output resources
    PatchCampaignWriteResource:
      type: object
      properties:
        attributes:
          $ref: '#/components/schemas/PatchCampaign'
        id:
          type: string
          description: Id of the entity
          nullable: true
        type:
          type: string
          description: Canonical type name of the entity
          nullable: true
          example: Campaign
      description: write model data for resources
    PatchResultCampaignReadResource:
      type: object
      properties:
        id:
          type: string
          description: Id of the entity
          nullable: true
          readOnly: true
        type:
          type: string
          nullable: true
          readOnly: true
          example: Campaign
      description: read model data for resources
    CommonProblem:
      type: object
      properties:
        code:
          type: string
          description: A machine-readable error code, expressed as a string value.
          nullable: true
        detail:
          type: string
          description: >-
            A human-readable explanation specific to this occurrence of the
            problem
          nullable: true
        instance:
          type: string
          description: A URI that identifies the specific occurrence of the problem.
          nullable: true
        source:
          type: object
          additionalProperties:
            type: string
          description: >-
            A machine-readable structure to reference to the exact location(s)
            causing the error(s)
          nullable: true
        stackTrace:
          type: string
          nullable: true
        title:
          type: string
          description: A short human-readable description of the problem type
          nullable: true
        traceId:
          type: string
          description: The request correlation ID this problem comes from.
          nullable: true
        traceIdentifier:
          type: string
          description: >-
            The request correlation ID this problem comes from. (deprecated, use
            traceId instead)
          nullable: true
        type:
          enum:
            - unknown
            - access-control
            - authentication
            - authorization
            - availability
            - deprecation
            - quota
            - validation
          type: string
          description: The problem's category.
          nullable: true
      description: Common problem object.
    PatchCampaign:
      type: object
      properties:
        budgetAutomation:
          $ref: '#/components/schemas/PatchMarketingCampaignBudgetAutomation'
        spendLimit:
          $ref: '#/components/schemas/PatchCampaignSpendLimit'
      description: "Campaign patch model.\r\nThe campaign identifier is provided in the resource {id} field (string-encoded integer) and is required."
    PatchMarketingCampaignBudgetAutomation:
      type: object
      properties:
        budgetConfiguration:
          $ref: '#/components/schemas/BudgetAutomationConfiguration'
        enabled:
          type: boolean
          description: >-
            Whether budget automation is enabled for this campaign. This field
            is always present in the response.
      description: "Budget automation, lets users configure budgets once at the campaign level while Criteo dynamically routes spend toward the best-performing ad sets.\r\nOnly provided fields are updated; omitted fields are left unchanged.\r\nIf \"enabled\" is omitted and only \"budgetConfiguration\" is provided, \"enabled\" defaults to false — budget automation will not be activated.\r\nTo activate budget automation, \"enabled\" must be explicitly set to true along with a valid \"budgetConfiguration\".\r\nTo deactivate, set \"enabled\" to false; \"budgetConfiguration\" can be omitted."
    PatchCampaignSpendLimit:
      type: object
      properties:
        spendLimitAmount:
          $ref: '#/components/schemas/NillableDecimal'
        spendLimitRenewal:
          enum:
            - undefined
            - daily
            - monthly
            - lifetime
          type: string
          description: "The period over which the campaign spend limit is applied.\r\nWhen spendLimitType is \"capped\", this is \"daily\", \"monthly\", or \"lifetime\".\r\nWhen spendLimitType is \"uncapped\", this is \"undefined\"."
          nullable: true
        spendLimitType:
          enum:
            - capped
            - uncapped
          type: string
          description: "Controls whether the campaign has a spend limit.\r\n\"capped\" returns a non-null spendLimitAmount.value and a spendLimitRenewal of \"daily\", \"monthly\", or \"lifetime\".\r\n\"uncapped\" returns spendLimitAmount.value as null and spendLimitRenewal as \"undefined\"."
          nullable: true
      description: "Spend limit configuration for a marketing campaign (patch).\r\nOnly provided fields are updated; omitted fields are left unchanged.\r\nWhen spendLimitType is \"capped\": spendLimitAmount and spendLimitRenewal are required.\r\nWhen spendLimitType is \"uncapped\": spendLimitAmount is null and spendLimitRenewal is \"undefined\"."
    BudgetAutomationConfiguration:
      type: object
      properties:
        adSetObjectives:
          enum:
            - conversions
            - revenue
            - visits
            - videoViews
          type: string
          description: "The ad set optimization objective for budget automation. Determines how the automated budget allocates spend across ad sets in the campaign.\r\n- \"conversions\": optimize for conversion events.\r\n- \"revenue\": optimize for revenue.\r\n- \"visits\": optimize for site visits.\r\n- \"videoViews\": optimize for completed video views."
      description: "Configuration for budget automation. Only meaningful when \"enabled\" is true.\r\nWhen \"enabled\" is false or omitted, this field is ignored."
      nullable: true
    NillableDecimal:
      type: object
      properties:
        value:
          type: number
          format: double
          nullable: true
      description: >-
        structure that encapsulates an object that have valid business null
        values. If the structure is provided (i.e. not null), then the value in
        it, even null, is provided.
      nullable: true
  securitySchemes:
    oauth:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://api.criteo.com/oauth2/token
          scopes: {}
        authorizationCode:
          authorizationUrl: https://api.criteo.com/oauth2
          tokenUrl: https://api.criteo.com/oauth2/token
          scopes: {}

````