Templates
Reusable starting points for deal rooms, documents, proposals, mutual action plans and emails. The list holds the organization's own templates and Closepact's built-in library, which every organization shares.
List templates
/templatesActive templates — the organization's own and Closepact's built-in library — most used first, a page at a time. Each carries a preview (how many content rows it holds, per section); add include_content=1 to get the full content as well, or fetch one with GET /templates/{template}.
curl 'https://api.closepact.com/v1/api/templates' \
-H "Authorization: Bearer $CLOSEPACT_API_KEY"{
"data": [
{
"id": "01a14f90-5d2c-7a18-9e3b-4c6d8f0a2b71",
"name": "Serviceavtal – fastighetsskötsel",
"type": "room",
"scope": "organization",
"is_built_in": false,
"description": "Rum för nya serviceavtal: offert, avtal för signering och tidplan för uppstart.",
"is_active": true,
"usage_count": 37,
"last_used_at": "2026-10-12T08:10:55+00:00",
"created_at": "2026-03-02T09:30:00+00:00",
"preview": {
"sections": {
"overview": 1,
"documents": 2,
"pricing": 1
},
"content_count": 4,
"has_branding": true
}
}
],
"links": {
"first": null,
"last": null,
"prev": null,
"next": null
},
"meta": {
"path": "https://api.closepact.com/v1/api/templates",
"per_page": 25,
"next_cursor": null,
"prev_cursor": null
}
}Query parameters
filter[type]stringOnly templates of this type. Repeat as
filter[type][]for several.One of
roomdocumentproposalmapemailqstringCase-insensitive match anywhere in the name.
Example
Serviceavtalinclude_contentbooleanInclude each template's full
content.Default
falselimitintegerItems per page. Values outside 1–100 are clamped.
Default
251–100cursorstringOpaque cursor from
meta.next_cursorormeta.prev_cursorof the previous page.
Responses
Headers
X-RateLimit-Limit— Requests this key may make per minute.X-RateLimit-Remaining— Requests left in the current minute.
dataarray of objectsrequiredidstring(uuid)requirednamestringrequiredis_built_inbooleanrequiredTrue for a Closepact library template shared by every organization. It can be used but not deleted.
typestringrequiredWhat it makes: a deal room, a document, a proposal, a mutual action plan, or an email.
One of
roomdocumentproposalmapemailscopestringrequiredOne of
personalteamorganizationdescriptionstringnullablerequiredis_activebooleanrequiredusage_countintegernullablerequiredTimes it has been used. Null in the response that creates it.
last_used_atstring(date-time)nullablerequiredcreated_atstring(date-time)requiredpreviewobjectrequiredcontentobject | array of valuesnullableThe template's body; its shape depends on
type. Only onGET /templates/{template}, or withinclude_content=1on the list. Sent as an empty array[]when empty.
linksobjectrequiredmetaobjectrequired
- 401No key, or the key is invalid, revoked or expired, or its creator no longer has access.Errors
- 402The organization has not bought the module this endpoint belongs to, or it has lapsed to read-only, or its tier does not include what the operation needs:Errors
featurenames the capability (the operation'sx-feature) andrequired_tierthe cheapest tier that grants it. Every operation answers this with"feature": "core.api"when no module the organization holds is on a tier that includes the API. - 403The key lacks the scope, or the member it acts as lacks the permission or holds no seat in the module (Errors
module_seat_required— an administrator assigns seats under Settings → Users), or the organization is suspended. - 429The key has made more requests this minute than its limit allows.Errors
Create a template
/templateswrite Permission templates.createAdds a template to the organization's library. content is stored as given and read by the part of Closepact the type belongs to; for a room template it holds contents — rows with a section (overview, documents, pricing, map, attachments), a kind (text, video, link, document, …), and title, body or url — and optionally brand_overrides. The easiest way to get a valid content is to copy it from an existing template (GET /templates/{template}).
scope defaults to organization.
curl -X POST 'https://api.closepact.com/v1/api/templates' \
-H "Authorization: Bearer $CLOSEPACT_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Serviceavtal – fastighetsskötsel",
"type": "room",
"description": "Rum för nya serviceavtal: offert, avtal för signering och tidplan för uppstart.",
"content": {
"contents": [
{
"section": "overview",
"kind": "text",
"title": "Välkommen",
"body": "Här samlar vi allt inför uppstarten av ert serviceavtal."
},
{
"section": "documents",
"kind": "link",
"title": "Våra villkor",
"url": "https://nordiskfastighet.se/villkor"
}
]
}
}'{
"data": {
"id": "01a15c44-1f8e-7b3a-a2d5-6e9c0b4f7a12",
"name": "Serviceavtal – fastighetsskötsel",
"type": "room",
"scope": "organization",
"is_built_in": false,
"description": "Rum för nya serviceavtal: offert, avtal för signering och tidplan för uppstart.",
"is_active": true,
"usage_count": null,
"last_used_at": null,
"created_at": "2026-10-18T09:02:11+00:00",
"preview": {
"sections": {
"overview": 1,
"documents": 1
},
"content_count": 2,
"has_branding": false
}
}
}Request body
application/json · required
namestringrequired2–255 characters
typestringrequiredOne of
roomdocumentproposalmapemailscopestringOne of
personalteamorganizationDefault
"organization"descriptionstringnullableat most 5,000 characters
contentobjectThe template's body; its shape depends on
type. Defaults to empty.team_idstring(uuid)nullableThe team a
teamtemplate belongs to: one of this organization's teams. Any other id fails validation (422).
Responses
Headers
X-RateLimit-Limit— Requests this key may make per minute.X-RateLimit-Remaining— Requests left in the current minute.
dataobjectrequiredA reusable starting point.
idstring(uuid)requirednamestringrequiredis_built_inbooleanrequiredTrue for a Closepact library template shared by every organization. It can be used but not deleted.
typestringrequiredWhat it makes: a deal room, a document, a proposal, a mutual action plan, or an email.
One of
roomdocumentproposalmapemailscopestringrequiredOne of
personalteamorganizationdescriptionstringnullablerequiredis_activebooleanrequiredusage_countintegernullablerequiredTimes it has been used. Null in the response that creates it.
last_used_atstring(date-time)nullablerequiredcreated_atstring(date-time)requiredpreviewobjectrequiredcontentobject | array of valuesnullableThe template's body; its shape depends on
type. Only onGET /templates/{template}, or withinclude_content=1on the list. Sent as an empty array[]when empty.
- 401No key, or the key is invalid, revoked or expired, or its creator no longer has access.Errors
- 402The organization has not bought the module this endpoint belongs to, or it has lapsed to read-only, or its tier does not include what the operation needs:Errors
featurenames the capability (the operation'sx-feature) andrequired_tierthe cheapest tier that grants it. Every operation answers this with"feature": "core.api"when no module the organization holds is on a tier that includes the API. - 403The key lacks the scope, or the member it acts as lacks the permission or holds no seat in the module (Errors
module_seat_required— an administrator assigns seats under Settings → Users), or the organization is suspended. - 422The request body or query failed validation.Errors
- 429The key has made more requests this minute than its limit allows.Errors
Retrieve a template
/templates/{template}One template, always with its full content. Works for the organization's own templates and for Closepact's built-in library; another organization's template answers 404.
curl 'https://api.closepact.com/v1/api/templates/01a14f90-5d2c-7a18-9e3b-4c6d8f0a2b71' \
-H "Authorization: Bearer $CLOSEPACT_API_KEY"{
"data": {
"id": "01a14f90-5d2c-7a18-9e3b-4c6d8f0a2b71",
"name": "Serviceavtal – fastighetsskötsel",
"type": "room",
"scope": "organization",
"is_built_in": false,
"description": "Rum för nya serviceavtal: offert, avtal för signering och tidplan för uppstart.",
"is_active": true,
"usage_count": 37,
"last_used_at": "2026-10-12T08:10:55+00:00",
"created_at": "2026-03-02T09:30:00+00:00",
"preview": {
"sections": {
"overview": 1,
"documents": 1
},
"content_count": 2,
"has_branding": false
},
"content": {
"contents": [
{
"section": "overview",
"kind": "text",
"title": "Välkommen",
"body": "Här samlar vi allt inför uppstarten av ert serviceavtal."
},
{
"section": "documents",
"kind": "link",
"title": "Våra villkor",
"url": "https://nordiskfastighet.se/villkor"
}
]
}
}
}Path parameters
templatestring(uuid)requiredThe template's id.
Example
01a14f90-5d2c-7a18-9e3b-4c6d8f0a2b71
Responses
Headers
X-RateLimit-Limit— Requests this key may make per minute.X-RateLimit-Remaining— Requests left in the current minute.
dataobjectrequiredA reusable starting point.
idstring(uuid)requirednamestringrequiredis_built_inbooleanrequiredTrue for a Closepact library template shared by every organization. It can be used but not deleted.
typestringrequiredWhat it makes: a deal room, a document, a proposal, a mutual action plan, or an email.
One of
roomdocumentproposalmapemailscopestringrequiredOne of
personalteamorganizationdescriptionstringnullablerequiredis_activebooleanrequiredusage_countintegernullablerequiredTimes it has been used. Null in the response that creates it.
last_used_atstring(date-time)nullablerequiredcreated_atstring(date-time)requiredpreviewobjectrequiredcontentobject | array of valuesnullableThe template's body; its shape depends on
type. Only onGET /templates/{template}, or withinclude_content=1on the list. Sent as an empty array[]when empty.
- 401No key, or the key is invalid, revoked or expired, or its creator no longer has access.Errors
- 402The organization has not bought the module this endpoint belongs to, or it has lapsed to read-only, or its tier does not include what the operation needs:Errors
featurenames the capability (the operation'sx-feature) andrequired_tierthe cheapest tier that grants it. Every operation answers this with"feature": "core.api"when no module the organization holds is on a tier that includes the API. - 403The key lacks the scope, or the member it acts as lacks the permission or holds no seat in the module (Errors
module_seat_required— an administrator assigns seats under Settings → Users), or the organization is suspended. - 404No such record in this organization.Errors
- 429The key has made more requests this minute than its limit allows.Errors