Update an existing Campaign. All fields are optional — only provided fields are updated. If a logo URL is provided, the image is fetched, re-encoded as PNG, and re-hosted on the NamePros CDN, replacing the previous CDN-hosted image. The same format, size, and dimension limits as POST ads/campaigns apply; if logo processing fails, the request returns logo_processing_failed and no fields on the campaign are changed.
Parameters
Input
Type
Description
horizontal_logo_url
string
New horizontal (wide) logo URL. Max 2 MB, up to 1000×1000 px. Accepted formats: PNG, JPEG, GIF, WebP.
vertical_logo_url
string
New vertical (narrow) logo URL. Max 2 MB, up to 1000×1000 px. Accepted formats: PNG, JPEG, GIF, WebP.
theme
string
CSS color in hex format.
ad_tag
string
Tag for link tracking (alphanumeric, starts with letter).
horizontal_logo_size
integer|null
Rendered width of the horizontal logo in the ad unit, in pixels — not the source image's dimensions. Values outside the 40–150 range are clamped.
vertical_logo_size
integer|null
Rendered height of the vertical logo in the ad unit, in pixels — not the source image's dimensions. Values outside the 18–40 range are clamped.
400 Logo image could not be downloaded, validated, or processed.
np_ads_error_too_many_campaigns
400 Too many active campaigns (when reactivating).
np_ads_error_campaign_not_found
404 Campaign doesn't exist or isn't associated with your account
DELETE ads/campaign/{id}
Deactivate a Campaign by setting is_active to false. The campaign data, listings, and click tracking history are preserved. Reactivate by POSTing with is_active=true.
404 Campaign doesn't exist or isn't associated with your account
POST ads/campaign/{id}/listing
Creating a new Listing within a Campaign.
Parameters
Input
Type
Description
domain
string
Listing domain name. Must be unique within the Campaign.
ad_expires_at
integer|null
Unix timestamp (in seconds) indicating when NamePros should stop displaying this listing.
action_label
string
A call-to-action that will be displayed for the listing. Common examples include "Bid", "Buy Now", and "Make Offer". See Listing.action_label for max length.
action_url
string
If a visitor clicks on the listing's call-to-action, they'll be forwarded to this URL. See Listing.action_url for max length.
auction_ends_at
integer|null
A Unix timestamp (in seconds) indicating when listing ends; typically used for auctions. Set this field to null to hide it.
bids
integer|null
The current number of bids; typically used for auctions. Set this field to null to hide it.
current_bid
integer|null
Current high bid, in dollars (USD); typically used for auctions. Set this field to null to hide it.
bin_price
integer|null
Listing's price, in dollars (USD); typically used for buy-now prices. Set this field to null to hide it.
409 A Listing already exists with the same domain and campaign_id.
np_ads_error_too_many_listings
400 Campaign has reached the maximum number of active listings.
np_ads_expected_json_content_type
415 Expected Content-Type to be application/json and request body to contain a valid JSON object
required_input_missing
400 Required fields are missing; see the 'missing' array in the response.
do_not_have_permission
403 A Listing already exists for the specified Campaign and domain name, but you don't have permission to edit it.
np_ads_error_campaign_not_found
404 Campaign doesn't exist or isn't associated with your account
np_ads_error_timestamp_probably_in_milliseconds
400 The Unix timestamp specified for {field} is very far in the future. Our API expects Unix timestamps to be in seconds, not milliseconds; did you accidentally use milliseconds?
np_ads_error_timestamp_must_be_in_the_future
400 {field} must be in the future.
PATCH ads/campaign/{id}/listing
Update an existing Listing by campaign_id ({id} in the URL) and domain name. Omitted fields are left unchanged; to clear a field, set it to null.
Parameters
Input
Type
Description
domain
string
Listing domain name. This field, combined with campaign_id, identifies the Listing to be updated.
ad_expires_at
integer
Unix timestamp (in seconds) indicating when NamePros should stop displaying this listing.
action_label
string
A call-to-action that will be displayed for the listing. Common examples include "Bid", "Buy Now", and "Make Offer". See Listing.action_label for max length. characters.
action_url
string
If a visitor clicks on the listing's call-to-action, they'll be forwarded to this URL. See Listing.action_url for max length.
auction_ends_at
integer|null
A Unix timestamp (in seconds) indicating when listing ends; typically used for auctions. Set this field to null to hide it.
bids
integer|null
The current number of bids; typically used for auctions. Set this field to null to hide it.
current_bid
integer|null
Current high bid, in dollars (USD); typically used for auctions. Set this field to null to hide it.
bin_price
integer|null
Listing's price, in dollars (USD); typically used for buy-now prices. Set this field to null to hide it.
Response
Output
Type
Description
changes
object
List of changes that were applied, along with the old values. Takes the form {"<field1>": {"old": ..., "new": ...}, "<field2>": {"old": ..., "new": ...}, ...}
Errors
Error key
Description
please_enter_value_for_required_field_x
400 An attempt was made to clear a required field.
np_ads_unknown_fields
400 Unrecognized fields were included in the JSON object. This probably means there was a typo.
np_ads_expected_json_content_type
415 Expected Content-Type to be application/json and request body to contain a valid JSON object
required_input_missing
400 Required fields are missing; see the 'missing' array in the response.
do_not_have_permission
403 A Listing already exists for the specified Campaign and domain name, but you don't have permission to edit it.
np_ads_error_campaign_not_found
404 Campaign doesn't exist or isn't associated with your account
must_wait_x_seconds_before_performing_this_action
429 You're trying to modify this resource too soon after the previous modification; try again after the number of seconds specified in the Retry-After header.
np_ads_error_timestamp_probably_in_milliseconds
400 The Unix timestamp specified for {field} is very far in the future. Our API expects Unix timestamps to be in seconds, not milliseconds; did you accidentally use milliseconds?
np_ads_error_timestamp_must_be_in_the_future
400 {field} must be in the future.
DELETE ads/campaign/{id}/listing
Expire an existing Listing by campaign_id ({id} in the URL) and domain name. The listing row is preserved so that existing redirect URLs continue to work; it simply stops being displayed. It is not an error to attempt to delete a Listing that doesn't exist as long as the Campaign exists.
Parameters
Input
Type
Description
domain
string
Listing domain name. This field, combined with campaign_id, identifies the Listing to be deleted.
The Listing that was deleted, or null if there was no matching listing.
Errors
Error key
Description
please_enter_value_for_required_field_x
400 An attempt was made to clear a required field.
np_ads_error_timestamp_probably_in_milliseconds
400 The Unix timestamp specified for {field} is very far in the future. Our API expects Unix timestamps to be in seconds, not milliseconds; did you accidentally use milliseconds?
np_ads_error_timestamp_must_be_in_the_future
400 {field} must be in the future.
np_ads_expected_json_content_type
415 Expected Content-Type to be application/json and request body to contain a valid JSON object
required_input_missing
400 Required fields are missing; see the 'missing' array in the response.
must_wait_x_seconds_before_performing_this_action
429 You're trying to modify this resource too soon after the previous modification; try again after the number of seconds specified in the Retry-After header.
do_not_have_permission
403 A Listing already exists for the specified Campaign and domain name, but you don't have permission to edit it.
np_ads_error_campaign_not_found
404 Campaign doesn't exist or isn't associated with your account
GET ads/campaign/{id}/listings
Gets a paginated list of Listing objects for a specified Campaign.
Parameters
Input
Type
Description
after
integer
When retrieving multiple pages, the last Listing.listing_id from the previous page.
List of Listings keyed by listing_id. An empty list indicates that there are no more pages.
Errors
Error key
Description
np_ads_error_campaign_not_found
404 Campaign doesn't exist or isn't associated with your account
PUT ads/campaign/{id}/listings
Sync listings for a campaign. Matches incoming listings to existing ones by domain name (case-insensitive): existing listings are updated in-place (preserving their listing_id), new domains are created, and domains no longer in the set are expired (rows preserved so redirect URLs keep working).
Parameters
Input
Type
Description
listings
array
Array of listing objects. Each must have: domain, ad_expires_at, action_label, action_url. Optional: auction_ends_at, bids, current_bid, bin_price.
Response
Output
Type
Description
created
integer
Number of new listings created.
updated
integer
Number of existing listings updated.
expired
integer
Number of stale listings expired (rows preserved for redirect URLs).
Errors
Error key
Description
np_ads_error_too_many_listings
400 The listings array exceeds the maximum allowed (1000).
np_ads_error_campaign_not_found
404 Campaign doesn't exist or isn't associated with your account
np_ads_error_timestamp_probably_in_milliseconds
400 The Unix timestamp specified for {field} is very far in the future. Our API expects Unix timestamps to be in seconds, not milliseconds; did you accidentally use milliseconds?
np_ads_error_timestamp_must_be_in_the_future
400 {field} must be in the future.
GET ads/campaigns
Gets a paginated list of Campaign objects.
Parameters
Input
Type
Description
after
integer
When retrieving multiple pages, the last campaign_id from the previous page.
List of Campaigns keyed by campaign_id. An empty list indicates that there are no more pages.
POST ads/campaigns
Create a new Campaign. Both logo variants are required: the horizontal logo fills the wide banner slots and the vertical logo fills the narrower sidebar slot. We fetch each image from the URL you provide, re-encode it as PNG, and re-host it on the NamePros CDN; the Campaign returned in the response contains CDN URLs. Accepted formats are PNG, JPEG, GIF, and WebP (SVG is not supported). Each source image must be at most 2 MB and 1000×1000 pixels; otherwise the request fails with logo_processing_failed and no campaign is created.
Parameters
Input
Type
Description
horizontal_logo_url
string
URL to the horizontal (wide) logo. Max 2 MB, up to 1000×1000 px. Accepted formats: PNG, JPEG, GIF, WebP.
vertical_logo_url
string
URL to the vertical (narrow) logo. Max 2 MB, up to 1000×1000 px. Accepted formats: PNG, JPEG, GIF, WebP.
theme
string
CSS color in hex format, e.g. "#ffffff".
ad_tag
string
Tag for link tracking (alphanumeric, starts with letter). If omitted, auto-generated from username.
horizontal_logo_size
integer|null
Rendered width of the horizontal logo in the ad unit, in pixels — not the source image's dimensions. Default 65. Values outside the 40–150 range are clamped. For crisp retina rendering, supply a source image at least 2x the upper bound.
vertical_logo_size
integer|null
Rendered height of the vertical logo in the ad unit, in pixels — not the source image's dimensions. Default 25. Values outside the 18–40 range are clamped. For crisp retina rendering, supply a source image at least 2x the upper bound.
404 The specified Listing couldn't be found, or you don't have permission to view it.
Data type: Campaign
Column
Type
Description
campaign_id
integer
user_id
integer
NamePros account responsible for the campaign
ad_tag
string
Tag used for link tracking
created_at
integer
Unix timestamp indicating when this Campaign object was created.
horizontal_logo_url
string
URL to the horizontal (wide) logo image, used in the banner ad slots. Returned as a NamePros CDN URL: when you supply your own URL on create or update we fetch the image, re-encode it as PNG, and re-host it — the source URL you provided is not served to end users.
horizontal_logo_size
integer|null
Rendered width of the horizontal logo in the ad unit, in pixels — not the dimensions of the source image. Default 65. Values outside the 40–150 range are clamped so the ad layout can't be broken by unexpected input; for crisp retina rendering supply a source image at least 2x the upper bound.
vertical_logo_url
string
URL to the vertical (narrow) logo image, used in the sidebar ad slot. Returned as a NamePros CDN URL — see horizontal_logo_url for details.
vertical_logo_size
integer|null
Rendered height of the vertical logo in the ad unit, in pixels — not the dimensions of the source image. Default 25. Values outside the 18–40 range are clamped; supply a source image at least 2x the upper bound for retina displays.
logo_action
string|null
URL where clicking on the logo takes the user (optional)
theme
string
Theme CSS color
is_active
bool
Data type: Listing
Column
Type
Description
listing_id
integer
ID of the Listing.
campaign_id
integer
ID of the parent Campaign.
created_at
integer
Unix timestamp indicating when this listing was first submitted to NamePros.
last_modified
integer
Unix timestmap indicating when this listing was last modified.
domain
string
Listing description; typically a domain name. Max length: 253 characters.
ad_expires_at
integer|null
Unix timestamp indicating when NamePros should stop displaying this listing.
auction_ends_at
integer|null
An optional Unix timestamp indicating when listing ends; typically used for auctions. Set this field to null to hide it.
bids
integer|null
An optional indicator of the number of bids; typically used for auctions. Set this field to null to hide it.
current_bid
integer|null
Current high bid, in dollars (USD); typically used for auctions. Set this field to null to hide it.
bin_price
integer|null
Listing's price, in dollars (USD); typically used for buy-now prices. Set this field to null to hide it.
action_label
string
A call-to-action that will be displayed for the listing. Common examples include "Bid", "Buy Now", and "Make Offer". Max length: 16 characters.
action_url
string
If a visitor clicks on the listing's call-to-action, they'll be forwarded to this URL. Max length: 250 characters.