Publication styles are tightly coupled to publications. A style must be provided when creating a publication, therefore it would be sensible to query this endpoint once in a while to sync which publication types are available to the organisation. It's unlikely a style would ever be revoked from an organisation, but new ones might be added.
GET v1/organisations/{id}/styles
200 OK | Listed the styles successfully |
---|---|
403 Not Authorised | Not allowed to list the styles - probably not allowed to deal with publications in the organisation |
An array of publication styles. A style consists of:
field | type | description |
---|---|---|
id | string | The unique ID of the style |
name | string | The name of the style |
description | string | The description of the style |
preview_url | string | The URL to preview the style on a publication |
available | boolean | Whether the style is available to use (yet) |
[
{
"id": "magazine",
"name": "Magazine",
"description": "A photographic awesomeness",
"preview_url": "http:\\/\\/google.com",
"available": true
},
{
"id": "yearbook",
"name": "Yearbook",
"description": "Great for large publications, including tag-based browsing and more",
"preview_url": "http:\\/\\/google.com",
"available": false
}
]
Note that publications that are not available should be considered "coming soon" - that is, they will be available to the user, once it's ready for use.
GET v1/organisations/{id}/publications
field | required | type | description |
---|---|---|---|
search | no | string | Filter results based on a search string |
status | no | string | Filter on the status of the publication, either published or unpublished |
limit | no | number | How many records to return |
offset | no1 | number | If limiting, how many records to offset by. Combined with limit , this is useful for pagination |
order | no | string | The field and optional direction to order on. Fields that can be ordered on are title , due_date and created_date . To specify with a direction, use a pipe e.g. `?order=due_date |
1An offset can only be supplied with a limit.
200 OK | Listed the publications successfully |
---|---|
403 Not Authorised | Not allowed to list that organisation's publications |