Overwrite campaign object (PUT)

Learn to replace campaign configurations using PUT and manage update restrictions.

Overview

Update existing Onsite Display campaigns using full-object replacement.

PUT updates use the same request structure as campaign creation. Unlike PATCH updates, PUT replaces the entire campaign object with the version included in the request.

Use PUT when:

  • Replacing the complete campaign configuration
  • Synchronizing from a source-of-truth system
  • Updating multiple dependent settings together
  • Rebuilding campaign configuration intentionally

Because PUT replaces the full object, additional validation is required before submission.

Availability

Supported for Onsite Display only.


How PUT updates work

PUT updates replace the entire campaign object.

Before submitting a PUT request, validate:

  • Campaign lifecycle state
  • Parameter eligibility
  • Configuration inheritance rules
  • Dependent field behavior

Some campaign settings become immutable after creation.

Full object replacement

PUT replaces the entire campaign object. Always retrieve the latest campaign configuration before using POST /api/v1/campaigns/list

Sending incomplete campaign objects may unintentionally overwrite existing values.


Campaign PUT update workflow

Retrieve

Retrieve the latest campaign configuration.

Review

Validate lifecycle state.

Update

Modify the full campaign object.

Validate

Confirm inheritance and lifecycle rules.

Submit

Send PUT request.

Review Results

Validate update outcome.


Before you begin

  • Valid advertiserId
  • Valid campaignId
  • Campaign in an eligible lifecycle state
  • Latest campaign configuration retrieved
  • Understanding of configuration inheritance rules

Endpoint

PUT /api/v1/campaigns


Request details

How this request is used

Use PUT requests to:

  • Update campaign metadata
  • Adjust budgets and schedules
  • Extend campaign duration
  • Modify delivery configuration
  • Replace campaign configuration
  • Synchronize external system updates
  • Perform bulk campaign updates
  • Rebuild campaign setup

Campaign field update eligibility

FieldDraftScheduledLivePausedCompletedArchived
name✅✅✅✅⚠️❌
description✅✅✅✅⚠️❌
objective✅✅❌❌❌❌
campaignType❌❌❌❌❌❌
mediaType❌❌❌❌❌❌
startDate*✅✅❌❌❌❌
endDate*✅✅✅✅✅❌
budgetType❌❌❌❌❌❌
dailyBudget*✅✅✅✅⚠️❌
totalBudget*✅✅✅✅⚠️❌
deliverySpeed*✅❌❌❌❌❌

*Can only be updated if configured at the campaign level during campaign creation.

  • ✅ = field can be updated
  • ❌= field cannot be updated
  • ⚠️= limited update support available
📌

Lifecycle rule

As campaigns progress through lifecycle states, fewer fields remain editable.


Configuration inheritance rules

Budget, schedule, and delivery settings must remain configured entirely at either the campaign level or ad group level.

The following fields always remain grouped together:

  • budgetType
  • dailyBudget
  • totalBudget
  • startDate
  • endDate
  • deliverySpeed

Configuration rule

If these settings were configured at the ad-group level during campaign creation, campaign-level updates are not supported.

Configuration placement becomes immutable after scheduling.


Additional constraints

  • PUT requests overwrite the full campaign object
  • Configuration placement becomes immutable after scheduling
  • Campaigns created to run indefinitely can be updated later to include an end date.
  • campaignType cannot be modified after creation
  • mediaType cannot be modified after creation

Campaign updates vs campaign status updates

Campaign configuration updates and lifecycle state updates are separate workflows.

Campaign Updates

  • Update metadata
  • Update budgets
  • Update schedules
  • Update delivery settings
  • Use PUT

Campaign Status Updates

  • Pause campaigns
  • Resume campaigns
  • Archive campaigns
  • Unarchive campaigns
  • Use Status APIs

Batch update behavior

This endpoint supports batch operations.

Each campaign update is processed independently.

Batch requests:

  • Max batch size: 10
  • Are not transactional
  • May partially succeed
  • Return per-object success or failure results

See the Batch Requests Guide for additional information.


Sample requests

Banner campaign
curl -X PUT \ 'https://developer.api.us.stg.walmart.com/api-proxy/service/display/api/v1/api/v1/campaigns' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer <auth_token>'
--header 'WM_SEC.AUTH_SIGNATURE: **************' \ --header 'WM_SEC.KEY_VERSION: 1' \ --header 'WM_CONSUMER.ID: adfwe-v23-faasd2r-afs-asdfqeff' \ --header 'WM_CONSUMER.intimestamp: 1565309779' -data ' [        { "campaignId": 1, "advertiserId": 1, "name": "string", "description": "string", "objective": "awareness", "campaignType": "ngd", "startDate": "2023-12-05T12:00:00Z ", "endDate": "2023-12-25T12:00:00Z ", "budgetType": "TOTAL", "totalBudget": 1000.0, "deliverySpeed": "string", "optimization": { "goalSetting": [ { "kpi": "ROAS" } ] }
}
]'
Batch operation
curl -X PUT \ 'https://developer.api.us.stg.walmart.com/api-proxy/service/display/api/v1/api/v1/campaigns' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer <auth_token>'
--header 'WM_SEC.AUTH_SIGNATURE: **************' \ --header 'WM_SEC.KEY_VERSION: 1' \ --header 'WM_CONSUMER.ID: adfwe-v23-faasd2r-afs-asdfqeff' \ --header 'WM_CONSUMER.intimestamp: 1565309779' -data ' [      { "campaignId": 1, "advertiserId": 1, "name": "string", "description": "string", "objective": "awareness", "campaignType": "ngd", "startDate": "2023-12-05T12:00:00Z ", "endDate": "2023-12-25T12:00:00Z ", "budgetType": "DAILY", "dailyBudget": 100.0, "deliverySpeed": "string", "optimization": { "goalSetting": [ { "kpi": "ROAS" } ] }
},
{ "campaignId": 2, "advertiserId": 1, "name": "string", "description": "string", "objective": "awareness", "campaignType": "ngd", "startDate": "2023-12-05T12:00:00Z ", "endDate": "2023-12-25T12:00:00Z ", "budgetType": "TOTAL", "totalBudget": 1000.0, "deliverySpeed": "string"
} ]'

Response details

What this response returns

The response confirms whether each campaign update succeeded or failed.

Batch requests return one response object per campaign.

Key fields to use

  • campaignId
    Unique campaign identifier associated with the update result.

  • code
    Overall operation result (success, failure)

  • details
    Validation messages, processing feedback, or failure details

  • name
    Name of the campaign. Returned only when code=success

  • message
    Optional. High-level, human-readable summary of the error when available.

  • errors
    Detailed information about one or more errors. This is an array object with fields: field, errorType, description

Error Handling

If the request or an individual item fails, the response includes error information to help identify the issue and determine the corrective action. Use errorType for the error condition, field for the affected request field when applicable, and description for an explanation of the error and, when available, guidance on how to resolve it.
For the complete error response schema and endpoint-specific response definitions, see the API Reference. For guidance on HTTP status codes and how clients should handle them, see API status codes and error handling.

How to interpret results

Successful updates

A successful response confirms the campaign object was updated successfully.

Batch operations

Batch requests may contain both successful and failed updates. Always validate results at the individual campaign level.


Sample responses

Single campaign
[  { "code": "success", "details": ["string"], "campaignId": 1 }
]
Batch operation (partial failure)
[ { "code": "failure", "details": [ "string" ], "campaignId": 1, "message": "string",
    "errors": [ { "field": "string", "errorType": "string", "description": "string" } ] }, { "code": "success", "details": [ "string" ], "campaignId": 2 }
]
Sample response - failure
[ { "code": "failure", "details": [ "string" ],    "message": "string",
    "errors": [ { "field": "string", "errorType": "string", "description": "string" } ] }
]

Common issues

  • Not using latest campaign configuration
  • Sending partial objects in PUT requests
  • Attempting to update immutable fields
  • Updating budget at the wrong configuration level
  • Forgetting to extend endDate before editing completed campaigns
  • Updating fields that are no longer eligible due to lifecycle state

What happens next

After updating campaigns:

  1. Store updated campaign metadata
  2. Review validation results
  3. Re-sync partner systems if needed
  4. Continue ad group workflows
  5. Validate delivery behavior after updates

Related pages


Did this page help you?