Custom Redirect Object

Track links on your website or third-party site with Account Engagement’s custom redirects. For example, you can track a link on your Twitter page or a banner ad on a third-party site. When a user clicks a link, a corresponding activity is created on their profile. Learn about custom redirects in Salesforce Help.

The API to access Custom Redirects follows the conventions described in Version 5 Overview.

Include the authentication header with every request. For information on how to authenticate, see Authentication.

OperationVerbURL FormatAbility Requirements
ReadGEThttps://pi.pardot.com/api/v5/objects/custom-redirects/<id>?<params>Marketing > Content > Custom Redirects > View ability
CreatePOSThttps://pi.pardot.com/api/v5/objects/custom-redirects?<params>Marketing > Content > Custom Redirects > Create/Edit ability
UpdatePATCHhttps://pi.pardot.com/api/v5/objects/custom-redirects/<id>?<params>Marketing > Content > Custom Redirects > Create/Edit ability
DeleteDELETEhttps://pi.pardot.com/api/v5/objects/custom-redirects/<id>Marketing > Content > Custom Redirects > Delete ability
QueryGEThttps://pi.pardot.com/api/v5/objects/custom-redirects?<params>Marketing > Content > Custom Redirects > View ability
FieldTypeDescription
nameStringName of the object for identification in Account Engagement.
campaignIdIntegerAccount Engagement Campaign related to this object.
destinationUrlStringA fully qualified URL. The visitor who clicks the custom redirect will be directed to this location. E.g. https://example.com/content.html
FieldTypeDescription
folderIdIntegerID of the folder containing this object. Uses the asset type's uncategorized folder if not specified on create.
trackerDomainIdIntegerID of the tracker domain to use in the URL for this object. Uses the primary tracker domain for the account if not specified on create.
vanityUrlPathStringVanity URL path (excluding protocol and host). Must be unique for each tracker domain. E.g. /my-link. The value assumes empty (/) if not specified on create.

The following fields are only available if a Google Analytics connector is present. For more information, see the Google Analytics documentation.

FieldTypeDescription
gaSourceStringCampaign source
gaMediumStringCampaign medium
gaTermStringCampaign keyword
gaContentStringCampaign content
gaCampaignStringCampaign ID
FieldTypeDescription
idIntegerID of the object.
salesforceIdStringSalesforce Id of the object.
vanityUrlStringFully qualified vanity URL. Includes tracker domain and vanityUrlPath. E.g. https://mytracked.example.com/my-link
urlStringFully qualified tracked URL. Doesn't include Vanity URL. E.g. https://mytracked.example.com/l/386175/2023-03-30/rnctj
trackedUrlStringFully qualified tracked URL if Vanity URL isn't set, otherwise Vanity URL is returned.
bitlyIsPersonalizedBooleanTrue if a custom Bitly URL was set.
bitlyShortUrlStringIf set, a fully qualified Bitly URL.
isDeletedBooleanTrue if the object is in the recycle bin in Account Engagement.
createdAtDateTimeCreation time of the object.
updatedAtDateTimeLast update time of the object.
createdByIdIntegerID of the user who created this object.
updatedByIdIntegerID of the user who last updated this object.
createdByUserUser object representing the user who created this object. See documentation for User for fields.
updatedByUserUser object representing the uer who last updated this object. See documentation for User for fields.
trackerDomainTrackerDomainTracker Domain object representing the tracker domain that was set on Create. See documentation for Tracker Domain for fields. A null value indicates that the object will use the default tracker domain for the account.
campaignCampaignCampaign object representing the campaign that was set on Create. See documentation for Campaign for fields.
folderFolderJSON object representing the folder for this object. See documentation for Folder for fields.

A custom redirect POST request must have a JSON body with all required fields specified, as described in the Version 5 Overview.

Example request:

Example response

This example does not show all headers, and whitespace has been added to make it easier to read.

The fields in the response body and Location header are the same as the fields specified on the example request.

Updating a custom redirect follows the conventions described in the Version 5 Overview.

Deleting a custom redirect follows the conventions described in the Version 5 Overview.

Retrieving a collection of custom redirects follows the conventions described in Version 5 Overview.

When executing a query, the following fields can be specified in the orderBy parameter. See the conventions for query described in the Version 5 Overview.

  • id

Example request:

Example response:

When executing a query, the following parameters can be used to filter the returned results. These parameters can be specified in the request along with any shared parameters defined in Version 5 Overview. When specifying more than one parameter, all parameters must match the record in order for it to be returned in the results.

ParameterDescription
idReturns any custom redirects where ID is equal to the given integer value.
idListReturns any custom redirects where ID is included in the given list of values.
idGreaterThanReturns any custom redirects where ID is greater than the specified value, non-inclusive.
idGreaterThanOrEqualToReturns any custom redirects where ID is greater than or equal to the specified value.
idLessThanReturns any custom redirects where ID is less than the specified value, non-inclusive.
idLessThanOrEqualToReturns any custom redirects where ID is less than or equal to the specified value.
deletedDetermines whether to return deleted records. The value can be false (default), true, or all.

Example request:

Example response: