Feed Builder
AUTHORIZATIONOAuth 2.0
Admin
AUTHORIZATIONOAuth 2.0
This folder is using OAuth 2.0 from collectionFeed Builder
Super admin
AUTHORIZATIONOAuth 2.0
This folder is using OAuth 2.0 from collectionFeed Builder
POSTCreate Client Rules
{{url}}/v1/admin/rules
AUTHORIZATIONBearer Token
Token
<token>
Bodyraw (json)
json
{
"id": "GYMNASTICSAUS",
"sortOptions": [
{
"label": "Publish date (oldest first)",
"value": "publishDate"
},
{
"label": "Publish date (newest first)",
"value": "publishDate,desc"
}
],
"returnTypeOptions": [
{
"label": "Articles only",
"value": "0"
},
{
"label": "Pages only",
"value": "1"
},
{
"label": "Articles & pages",
"value": "2"
}
],
"rules": [
{
"title": "Specific content",
"key": "id.keyword",
"metadata": {
"type": "text",
"options": null,
"operators": [
{
"label": "Equals",
"value": "="
},
{
"label": "Does Not Equal",
"value": "!="
}
]
}
},
{
"title": "Linked ID source system",
"key": "linkedIds.sourceSystem.keyword",
"metadata": {
"type": "text",
"options": [
{
"label": "Competition",
"value": "OPTA_FOOTBALL_COMPETITION"
},
{
"label": "Team",
"value": "OPTA_FOOTBALL_TEAM"
},
{
"label": "Match",
"value": "OPTA_MATCH"
}
],
"operators": [
{
"label": "equals",
"value": "="
}
]
}
},
{
"title": "Linked ID source system ID",
"key": "linkedIds.sourceSystemId.keyword",
"metadata": {
"type": "text",
"options": null,
"operators": [
{
"label": "equals",
"value": "="
}
]
}
},
{
"title": "Tags",
"key": "tags.keyword",
"metadata": {
"type": "text",
"options": null,
"operators": [
{
"label": "Includes",
"value": "IN"
},
{
"label": "Excludes",
"value": "NOT_IN"
}
]
}
},
{
"title": "Categories",
"key": "categories.id.keyword",
"metadata": {
"type": "text",
"options": null,
"operators": [
{
"label": "Includes",
"value": "IN"
},
{
"label": "Excludes",
"value": "NOT_IN"
}
]
}
},
{
"title" : "Hero media content type",
"key" : "heroMedia.content.contentType.keyword",
"metadata" : {
"type" : "select",
"options" : [
{
"label" : "Image",
"value" : "IMAGE"
},
{
"label" : "Video",
"value" : "VIDEO"
}
],
"operators" : [
{
"label" : "equals",
"value" : "="
}
]
}
}
]
}
Example Request
Success
curl
curl --location -g '{{url}}/v1/admin/rules' \
--data '{
"id": "a",
"sortOptions" : [
{
"label": "Publish Date Ascending",
"value": "publishDate"
},
{
"label": "Publish Date Descending",
"value": "publishDate,desc"
}
],
"rules": [
{
"title": "Media Type",
"key": "mediaType",
"metadata": {
"type": "select",
"options": [
{
"label": "On Demand",
"value": "ondemand"
},
{
"label": "Streaming",
"value": "streaming"
}
],
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Linked ID Source System",
"key": "linkedIds.sourceSystem.keyword",
"metadata": {
"type": "select",
"options": [
{
"label": "Competition",
"value": "OPTA_FOOTBALL_COMPETITION"
},
{
"label": "Team",
"value": "OPTA_FOOTBALL_TEAM"
},
{
"label": "Match",
"value": "OPTA_MATCH"
}
],
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Linked ID Source System ID",
"key": "linkedIds.sourceSystemId.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Tags",
"key": "tags.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "INCLUDES",
"value": "IN"
},
{
"label": "EXCLUDES",
"value": "NOT_IN"
}
]
}
},
{
"title": "Categories",
"key": "categories.text.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "INCLUDES",
"value": "IN"
},
{
"label": "EXCLUDES",
"value": "NOT_IN"
}
]
}
},
{
"title": "Hits",
"key": "hits",
"metadata": {
"type": "number",
"operators": [
{
"label": "equal",
"value": "="
},
{
"label": "less than",
"value": "<"
},
{
"label": "less than or equal to",
"value": "<="
},
{
"label": "greater than",
"value": ">"
},
{
"label": "greater than or equal to",
"value": ">="
}
]
}
},
{
"title": "Teams",
"key": "teamId",
"metadata": {
"type": "select",
"options": [
{
"label": "Leeds",
"value": "t2"
},
{
"label": "Brighton",
"value": "t36"
}
],
"operators": [
{
"label": "Brighton",
"value": "="
}
]
}
}
]
}'
200 OK
Example Response
json
{
"status": "success",
"data": {
"id": "a",
"rules": [
{
"title": "Media Type",
"key": "mediaType",
"metadata": {
"type": "select",
"options": [
{
"label": "On Demand",
"value": "ondemand"
},
{
"label": "Streaming",
"value": "streaming"
}
],
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Linked ID Source System",
"key": "linkedIds.sourceSystem.keyword",
"metadata": {
"type": "select",
"options": [
{
"label": "Competition",
"value": "OPTA_FOOTBALL_COMPETITION"
},
{
"label": "Team",
"value": "OPTA_FOOTBALL_TEAM"
},
{
"label": "Match",
"value": "OPTA_MATCH"
}
],
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Linked ID Source System ID",
"key": "linkedIds.sourceSystemId.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Tags",
"key": "tags.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "INCLUDES",
"value": "IN"
},
{
"label": "EXCLUDES",
"value": "NOT_IN"
}
]
}
},
{
"title": "Categories",
"key": "categories.text.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "INCLUDES",
"value": "IN"
},
{
"label": "EXCLUDES",
"value": "NOT_IN"
}
]
}
},
{
"title": "Hits",
"key": "hits",
"metadata": {
"type": "number",
"operators": [
{
"label": "equal",
"value": "="
},
{
"label": "less than",
"value": "<"
},
{
"label": "less than or equal to",
"value": "<="
},
{
"label": "greater than",
"value": ">"
},
{
"label": "greater than or equal to",
"value": ">="
}
]
}
},
{
"title": "Teams",
"key": "teamId",
"metadata": {
"type": "select",
"options": [
{
"label": "Leeds",
"value": "t2"
},
{
"label": "Brighton",
"value": "t36"
}
],
"operators": [
{
"label": "Brighton",
"value": "="
}
]
}
}
],
"sortOptions": [
{
"label": "Publish Date Ascending",
"value": "publishDate"
},
{
"label": "Publish Date Descending",
"value": "publishDate,desc"
}
],
"deleted": false,
"created": {
"date": "2020-06-02T12:34:46.507Z",
"editorName": "Ioannis D",
"editorAuthId": 639,
"editorEmail": "jordan.hitchman@incrowdsports.com",
"editorIp": ""
},
"lastModified": {
"date": "2020-06-02T12:34:46.507Z",
"editorName": "Ioannis D",
"editorAuthId": 639,
"editorEmail": "jordan.hitchman@incrowdsports.com",
"editorIp": ""
}
},
"metadata": {
"createdAt": "2020-06-02T11:34:46.508Z"
}
}
Content-Type
application/json
Vary
Origin
Date
Tue, 02 Jun 2020 11:34:46 GMT
Content-Length
2028
DELETEDelete Client Rules
{{url}}/v1/admin/rules/{{clientId}}
AUTHORIZATIONOAuth 2.0
This request is using OAuth 2.0 from collectionFeed Builder
Example Request
Token expired
curl
curl --location -g --request DELETE '{{url}}/v1/admin/rules/{{clientId}}'
400 Bad Request
Example Response
json
{
"status": "fail",
"data": "token is expired by 477h54m24s",
"message": "Could not decode authorization token",
"metadata": {
"createdAt": "2020-06-02T14:20:46.742Z"
}
}
Content-Type
application/json
Vary
Origin
Date
Tue, 02 Jun 2020 14:20:46 GMT
Content-Length
159
PUTUpdate Client Rules
{{url}}/v1/admin/rules/{{clientId}}
AUTHORIZATIONOAuth 2.0
This request is using OAuth 2.0 from collectionFeed Builder
Bodyraw (json)
json
{
"id": "INCROWD",
"rules": [
{
"title": "Specific Content",
"key": "id",
"metadata": {
"type": "text",
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Linked ID Source System ID",
"key": "linkedIds.sourceSystemId.keyword",
"metadata": {
"type": "text",
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Linked ID Source System",
"key": "linkedIds.sourceSystem.keyword",
"metadata": {
"type": "select",
"options": [
{
"label": "Competition",
"value": "OPTA_FOOTBALL_COMPETITION"
},
{
"label": "Team",
"value": "OPTA_FOOTBALL_TEAM"
},
{
"label": "Match",
"value": "OPTA_MATCH"
}
],
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Tags",
"key": "tags",
"metadata": {
"type": "text",
"operators": [
{
"label": "Includes",
"value": "IN"
},
{
"label": "Excludes",
"value": "NOT_IN"
}
]
}
},
{
"title": "Categories",
"key": "categories.text",
"metadata": {
"type": "text",
"operators": [
{
"label": "Includes",
"value": "IN"
},
{
"label": "Excludes",
"value": "NOT_IN"
}
]
}
},
{
"title": "Hits",
"key": "hits",
"metadata": {
"type": "number",
"operators": [
{
"label": "equal",
"value": "="
},
{
"label": "less than",
"value": "<"
},
{
"label": "less than or equal to",
"value": "<="
},
{
"label": "greater than",
"value": ">"
},
{
"label": "greater than or equal to",
"value": ">="
}
]
}
},
{
"title": "Teams",
"key": "teamId",
"metadata": {
"type": "select",
"options": [
{
"label": "Leeds",
"value": "t2"
},
{
"label": "Brighton",
"value": "t36"
}
],
"operators": [
{
"label": "Brighton",
"value": "="
}
]
}
},
{
"title" : "Hero media content type",
"key" : "heroMedia.content.contentType.keyword",
"metadata" : {
"type" : "select",
"options" : [
{
"label" : "Image",
"value" : "IMAGE"
},
{
"label" : "Video",
"value" : "VIDEO"
}
],
"operators" : [
{
"label" : "equals",
"value" : "="
}
]
}
}
]
}
Example Request
Rules not found
curl
curl --location -g --request PUT '{{url}}/v1/admin/rules/{{clientId}}' \
--data '{
"id": "INCROWD",
"rules": [
{
"title": "Media Type",
"key": "mediaType",
"metadata": {
"type": "select",
"options": [
{
"label": "On Demand",
"value": "ondemand"
},
{
"label": "Streaming",
"value": "streaming"
}
],
"operators": [
{
"label": "equal",
"value": "="
}
]
}
},
{
"title": "Tags",
"key": "tags",
"metadata": {
"type": "text",
"operators": [
{
"label": "INCLUDES",
"value": "IN"
},
{
"label": "EXCLUDES",
"value": "NOT_IN"
}
]
}
},
{
"title": "Categories",
"key": "categories.text",
"metadata": {
"type": "text",
"operators": [
{
"label": "INCLUDES",
"value": "IN"
},
{
"label": "EXCLUDES",
"value": "NOT_IN"
}
]
}
},
{
"title": "Hits",
"key": "hits",
"metadata": {
"type": "number",
"operators": [
{
"label": "equal",
"value": "="
},
{
"label": "less than",
"value": "<"
},
{
"label": "less than or equal to",
"value": "<="
},
{
"label": "greater than",
"value": ">"
},
{
"label": "greater than or equal to",
"value": ">="
}
]
}
},
{
"title": "Teams",
"key": "teamId",
"metadata": {
"type": "select",
"options": [
{
"label": "Leeds",
"value": "t2"
},
{
"label": "Brighton",
"value": "t36"
}
],
"operators": [
{
"label": "Brighton",
"value": "="
}
]
}
}
]
}'
404 Not Found
Example Response
json
{
"status": "fail",
"message": "clientRules with ID a not found",
"metadata": {
"createdAt": "2020-06-02T14:25:12.385Z"
}
}
Content-Type
application/json
Vary
Origin
Date
Tue, 02 Jun 2020 14:25:12 GMT
Content-Length
114