Apply a Template

Applies the structure of a Template to an existing Item.

Beware that, just like within the application, this action will override the existing structure of an Item and may result in loss of content when fields do not match. Ensure you take necessary precautions.

Response Code



item_id The ID of the Item to apply a Template to
template_id The ID of the Template to apply


POST: /items/<ITEM_ID>/apply_template

cURL Example

curl<ITEM_ID>/apply_template \ -u [email protected]:<YOUR_API_KEY> \ -H "Accept: application/vnd.gathercontent.v0.5+json" \ -X POST --data "template_id=<TEMPLATE_ID>"

PHP Example

[email protected]';
$apikey '<YOUR_API_KEY>';

$data = array(
'template_id' => '<TEMPLATE_ID>'

$item_id '<ITEM_ID>';

$ch curl_init();

curl_setopt$chCURLOPT_HTTPHEADER, array('Accept: application/vnd.gathercontent.v0.5+json'));
curl_setopt$chCURLOPT_USERPWD$username ':' $apikey);
curl_setopt$chCURLOPT_URL'' $item_id '/apply_template');
curl_setopt$chCURLOPT_RETURNTRANSFERtrue );
curl_setopt$chCURLOPT_POSTtrue );

$response json_decodecurl_exec$ch ) );
curl_close$ch );

Great, welcome aboard!

That’s it! You’re signed up to our mailing list and can expect content strategy goodness in your inbox soon.