OpenFolia

List page designs

GET
/page-designs

The page designs at ?ref= (design/<id>.yaml), by ID, each with the problems found checking it against the configuration. A file in design/ that is no design is listed too (UnreadablePageDesignResource, with meta.error). A manual naming no design (and a configuration naming none as pdf.design) gets the built-in design, which is no file and not listed. Designs carry no audience: every reader of the ref reads them.

Authorization

bearer
headerAuthorizationBearer <JWT>

A service account's token (ccms_sat_…, issued by POST /service-accounts/{id}/tokens), or, for local use and demo mode, the server's shared CCMS_API_TOKEN.

Query Parameters

page[number]?integer

Page to return, from 1. Default: 1.

Range1 <= value
page[size]?integer

Resources per page. Default: 50, at most 200.

Range1 <= value <= 200
ref?string

Branch, tag or commit ID to read from. Default: the server's CCMS_DEFAULT_REF.

Header Parameters

X-Ccms-User?string

Demo mode only (CCMS_AUTH_MODE=demo): the user ID to act as. The bearer token is still required; without demo mode the header is refused (400).

Response Body

application/vnd.api+json
  1. response
data*array<|>
meta*
links*
Example Request
curl -X GET 'http://localhost:3000/page-designs'
Example Response
{  "data": [    {      "type": "PageDesign",      "id": "string",      "attributes": {        "schemaVersion": 1,        "name": "string",        "preset": "string",        "template": "string",        "page": {          "size": "a4",          "margins": {            "top": 26,            "right": 22,            "bottom": 24,            "left": 22          },          "doubleSided": false        },        "colours": {          "primary": "string",          "accent": "string",          "text": "string"        },        "fonts": {          "embeddingAllowed": false        },        "logo": {          "light": "string",          "dark": "string"        },        "titlePage": {          "fields": [            "title",            "variant",            "language",            "release",            "date"          ]        },        "regions": {},        "translations": {          "property1": {            "sourceCommit": "string",            "blocks": {              "property1": "string",              "property2": "string"            }          },          "property2": {            "sourceCommit": "string",            "blocks": {              "property1": "string",              "property2": "string"            }          }        },        "coverImage": {          "default": {            "asset": "string",            "alt": "string"          },          "variants": []        },        "backPage": {          "position": "last",          "copyright": "string",          "documentNumber": true,          "date": true        },        "header": {          "default": {            "left": [              {                "type": "placeholder",                "key": "title"              }            ],            "right": [              {                "type": "placeholder",                "key": "variant"              }            ]          }        },        "footer": {          "default": {            "left": [              {                "type": "placeholder",                "key": "language"              }            ],            "right": [              {                "type": "placeholder",                "key": "page"              }            ]          }        },        "headings": {          "numbering": [            "decimal"          ],          "sizes": [            "3xl",            "2xl",            "xl",            "base"          ],          "colour": "text",          "pageBreakBeforeLevel1": true        },        "body": {          "fontSize": 10,          "lineHeight": 1.45,          "paragraphSpacing": 7,          "columns": 1        },        "tables": {          "headerTint": true,          "borders": "horizontal",          "zebra": false        },        "steps": {          "marker": "filled-circle"        },        "notes": {          "style": "tinted"        },        "safety": {          "standard": "ansi-z535"        }      },      "meta": {        "issues": [          {            "severity": "error",            "code": "string",            "message": "string",            "at": "string",            "block": "string"          }        ]      }    }  ],  "meta": {    "page": {      "currentPage": -9007199254740991,      "lastPage": -9007199254740991,      "perPage": -9007199254740991,      "total": -9007199254740991    }  },  "links": {    "self": "string",    "first": "string",    "last": "string",    "prev": "string",    "next": "string"  }}