Font variants
Retrieve font variants for a layer of a template
This endpoint retrieves the font variants (weight and style combination) of a text layer's fonts of a specific template.
Request
Method: GET
URL:
https://api.creatopy.com/v1/templates/fontVariants
Body:
templateHash
(string, required): The hash of the template.layerName
(string, required): The name of the layer of export.
Response
The response is a JSON object with the following schema:
JSON
{
"response": [
{
"name": "Description",
"fontFamilyType": "google",
"slideNumber": 0,
"bannersetElementId": 7,
"fontFamily": "Roboto Condensed",
"actualFontStyle": "normal",
"actualFontWeight": 400,
"fontVariants": [
{
"weight": "300",
"subFamily": "Light"
},
{
"weight": "400",
"subFamily": "Regular"
},
{
"weight": "700",
"subFamily": "Bold"
},
{
"weight": "300italic",
"subFamily": "Light Italic"
},
{
"weight": "400italic",
"subFamily": "Regular Italic"
},
{
"weight": "700italic",
"subFamily": "Bold Italic"
}
]
}
]
}
When you use the FONTVARIANT attribute on related endpoints, as value you will use the weight value from the response.
Last updated