Skip to main content
POST
Update Platform Asset

Authorizations

x-api-key
string
header
required

A server-side Bily API key created under Settings > AI tools > Access keys. Select the intended workspace before creating it.

Headers

x-bily-organization-id
string

An organization ID returned by GET /context or GET /organizations. Omit it when a scoped key supplies the organization. Otherwise provide it when no organization is selected.

Example:

"org_01J8W7T9G3E6ZQ4M2K5N8P1R0S"

Path Parameters

resourceUrl
string
required

Exact workspace URL returned by GET /context.

Body

application/json

For Meta/Google budget changes, first read the native budget and keep the returned guard unchanged. Send only budget and budgetType inside updates. Meta omits top-level sourceAuthority; its source is inside budgetGuard. Google supplies the exact top-level sourceAuthority pair. The path supplies resourceUrl; do not repeat it in the body.

platform
enum<string>
required
Available options:
FACEBOOK,
GOOGLE_ADS,
MICROSOFT,
LINKEDIN,
SNAPCHAT,
TIKTOK,
PINTEREST
assetType
enum<string>
required
Available options:
campaign,
adset,
ad
assetId
string
required
updates
object
required
parentAssetId
string
Pattern: ^[1-9]\d{0,19}$
adAccountId
string
budgetGuard
object

Use the live quote unchanged. amountUnits must fit a positive signed 64-bit integer (at most 9223372036854775807). Selection, owner, currency, cadence and source must match the exact request. Google affectedCampaignIds is the complete unique lexically sorted scope, includes the selected campaign, and matches referenceCount. A JSON-shaped guard without a current matching fingerprint is not executable authority.

sourceAuthority
object

GOOGLE_ADS only: use the exact enabled account and connector pair from the current workspace selection. Omit for other platforms.

Response

Request completed. Inspect the returned state and any verification fields.

The response is of type object.