Layout Template Object

Layout templates are used to format landing pages, forms, and site search results. Learn more about layout templates in Salesforce Help.

The API to access the Layout Templates object follows the conventions described in Version 5 Overview.

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

OperationHTTP VerbURL FormatAbility Requirements
ReadGEThttps://pi.pardot.com/api/v5/objects/layout-templates/<id>?<params>Marketing > Landing Pages > Layout Templates > View ability
CreatePOSThttps://pi.pardot.com/api/v5/objects/layout-templates?<params>Marketing > Landing Pages > Layout Templates > Create/Edit ability
UpdatePATCHhttps://pi.pardot.com/api/v5/objects/layout-templates/<id>?<params>Marketing > Landing Pages > Layout Templates > Create/Edit ability
DeleteDELETEhttps://pi.pardot.com/api/v5/objects/layout-templates/<id>Marketing > Landing Pages > Layout Templates > Delete ability
QueryGEThttps://pi.pardot.com/api/v5/objects/layout-templates?<params>Marketing > Landing Pages > Layout Templates > View ability
FieldTypeDescription
nameStringName of the object for identification in Account Engagement.
layoutContentStringHTML content of this layout template encoded as JSON string.

| Field | Type | Description | | --------------------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --- | | formContent | String | HTML content encoded as a JSON string that controls form display logic. Uses default values if they're not provided. | | | isIncludeDefaultCss | Boolean | True if not supplying custom CSS styling. | | folderId | Integer | ID of the folder containing this object. Uses the asset type's uncategorized folder if not specified on create. |

FieldTypeDescription
idIntegerID of this object.
isDeletedBooleanThe value is true if this object is in the recycle bin in Account Engagement.
createdAtDateTimeCreation time of this object.
updatedAtDateTimeThe last-updated time for the object.
createdByIdIntegerID of the user who created the object.
updatedByIdIntegerID of the user who last updated the object.
createdByUserUser object representing the user who created the object. See documentation for User for fields.
updatedByUserUser object representing the user who last updated the object. See documentation for User for fields.
siteSearchContentStringHTML content encoded as a JSON string that controls the site search content. Uses default values if they're not provided.
folderFolderFolder object representing the folder containing this object. See documentation for Folder for fields.

A Layout Template POST request must have a JSON body that specifies all the required fields. All HTML content must be JSON escaped.

Example request:

Example response:

This example doesn't show all the headers. Whitespace has been added to make it easier to read.

Examples include extra spaces for readability and don't always include headers. The fields in the response body and Location header match the fields specified on the example request.

Updating a layout template follows the conventions described in the Version 5 Overview.

Deleting a layout template follows the conventions described in the Version 5 Overview. Layout templates that are in use on Forms and Landing Pages can't be deleted. To successfully delete, remove all usages.

Retrieving a collection of layout templates 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 layout templates where ID is equal to the given integer value.
idListReturns any layout templates where ID is included in the given list of values.
idGreaterThanReturns any layout templates where ID is greater than the specified value, non-inclusive.
idGreaterThanOrEqualToReturns any layout templates where ID is greater than or equal to the specified value.
idLessThanReturns any layout templates where ID is less than the specified value, non-inclusive.
idLessThanOrEqualToReturns any layout templates where ID is less than or equal to the specified value.
nameReturns any layout templates where Name is equal to the given string value.
deletedDetermines whether to return deleted records. The value can be false (default), true, or all.

Example request:

Example response: