/
CMS Carousels API
CMS Carousels API
All request will use the post method and request URL https://cms.manage.aniview.com/backend/graphql
1. Get Carousels List
Get list of all Carouselss
Query:
query carousels($order: [QueryCarouselsOrderByOrderByClause!], $search: QueryCarouselsSearchWhereConditions, $first: Int!, $page: Int!, $status: [String!]) { carousels( orderBy: $order first: $first page: $page search: $search status: $status ) { paginatorInfo { total count currentPage } data { id title duration createdAt updatedAt slideCount transitionFilter slideDuration progress feed { id title } status error video { thumbnail { urlByDimensionKey(key: "small") status } poster { status } } } } }
Query variables:
{ "first": 10, "order": [ { "column": "CREATED_AT", "order": "DESC" }, { "column": "ID", "order": "ASC" } ], "search": { "OR": [ { "column": "TITLE", "value": null, "operator": "LIKE" }, { "column": "ID", "value": "" } ], "AND": [] }, "status": [ "active", "generating", "error", "archived", "importing", "transcoding", "encoding", "uploading" ], "page": 1 }
Code Example:
const axios = require("axios");
const url = 'https://manage.aniview.com/api/token?format=json';
const payload = {
"operationName": "carousels",
"variables": {
"first": 10,
"order": [
{
"column": "CREATED_AT",
"order": "DESC"
},
{
"column": "ID",
"order": "ASC"
}
],
"search": {
"OR": [
{
"column": "TITLE",
"value": null,
"operator": "LIKE"
},
{
"column": "ID",
"value": ""
}
],
"AND": []
},
"status": [
"active",
"generating",
"error",
"archived",
"importing",
"transcoding",
"encoding",
"uploading"
],
"page": 1
},
"query": "query carousels($order: [QueryCarouselsOrderByOrderByClause!], $search: QueryCarouselsSearchWhereConditions, $first: Int!, $page: Int!, $status: [String!]) {\n carousels(\n orderBy: $order\n first: $first\n page: $page\n search: $search\n status: $status\n ) {\n paginatorInfo {\n total\n count\n currentPage\n }\n data {\n id\n title\n duration\n createdAt\n updatedAt\n slideCount\n transitionFilter\n slideDuration\n progress\n feed {\n id\n title\n }\n status\n error\n video {\n thumbnail {\n urlByDimensionKey(key: \"small\")\n status\n }\n poster {\n status\n }\n }\n }\n }\n}"
}
axios.post(url, {
'id': 'id',
'password': 'password',
'accountId': 'accountId'
})
.then((response) => {
apiCall(response.data);
}, (error) => {
console.log(error);
});
function apiCall(auth) {
axios({
url: 'https://cms.manage.aniview.com/backend/graphql/',
method: 'post',
headers: {
'Cookie': 'token=' + auth.data.token
},
data: payload
}).then((result) => {
console.log(result.data[0]);
});
}
2. Create Carousels
Create a new Carousels
Query:
Query variables:
Code Example:
3. Update Carousels
Update a specific Carousels
Query:
Query variables:
Code example:
4. Delete Carousels
Delete a specific Carousels
Query:
Query variables:
Code example:
, multiple selections available,
Related content
CMS Playlist API
CMS Playlist API
More like this
CMS Categories API
CMS Categories API
More like this
CMS Contextual Filters API
CMS Contextual Filters API
More like this
CMS Feed API
CMS Feed API
More like this
CMS Tags API
CMS Tags API
More like this
CMS Videos API
CMS Videos API
More like this