Description
This endpoint must be used for updating a specific profile by id ({id})
This endpoint must be consumed in PATCH request
Request
As part of the request headers, a Basic Auth must be sent:
This must be sended in the Http headers of the request, look at the next curl example for a better understanding
Copy codecurl --location --request PATCH 'host:port/zynchro.api.system-config/v1/profiles/33' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer ••••••' \ --data '{ "header": { "transactionId": "123455566677788" }, "data": { "profile": { "name": "UK Content Publisher TEST 6/17", "isDashboard": false, "isMap": true, "isList": 1, "isSnapshotMosaic": false, "isPlayerHealth": true, "isOperationalHealth": false, "isLocationCompliance": true, "isBandWidth": false, "isVDAMonitoring": true, "isVDAHealth": false, "isDashboardAnalytics": true, "isPlaybacks": false, "isEvents": true, "isPageViews": false, "isSessions": true, "isDownloadFTP": false, "isManageLocations": true, "isUpdateLocation": false, "isGroupsLocation": true, "isPlayersLocation": false, "isSmartGroups": true, "isTags": false, "isMediaLibrary": true, "isFilesLibrary": false, "isMediaFeed": true, "isPresentations": false, "isAuthorizeContent": true, "isPublishLocation": false, "isPublishLocationGroup": true, "isPublishSmartGroups": false, "isPublishUpdatePresentation": true, "isPublishUpdatePlaylist": false, "isPublishFirmware": true, "isPublishLog": false, "isWall": true, "isContentLog": false, "cmCampaigns": 2, "cmCanApprove": true, "cmRundown": false, "cmDayparting": false, "cmBanners": false, "cmProManufacturer": true, "cmProBrands": false, "cmProCategories": false, "cmProRevenueClass": false, "cmProFillers": true, "cmProInserts": false, "cmProPresentations": false, "cmProSettings": false, "cmProReports": true, "cmProInventory": false, "cmInventory": 2, "cmProDisclaimer": false, "cmReports": 1, "isTVControl": false, "isDownloadControl": true, "isRemoteSetup": false, "isBDeploy": true, "isPlayerSetup": false, "isSmartActions": true, "isStocks": false, "isLicenses": true, "isUsers": false, "isSetupUser": true, "isPlayListStandard": false, "isDayparting": true, "isAdminClients": false }, "clientsIds": [ 23,24,26,27,28,29,30,31,32,33,34,35,36, 38, 33 ] } }'
In java it would be something like this (depending on the dependency you use)
Copy codeOkHttpClient client = new OkHttpClient().newBuilder() .build(); MediaType mediaType = MediaType.parse("application/json"); RequestBody body = RequestBody.create(mediaType, "{\r\n \"header\": {\r\n \"transactionId\": \"123455566677788\"\r\n },\r\n \"data\": {\r\n \"profile\": {\r\n \"name\": \"UK Content Publisher TEST 6/17\",\r\n \"isDashboard\": false,\r\n \"isMap\": true,\r\n \"isList\": 1,\r\n \"isSnapshotMosaic\": false,\r\n \"isPlayerHealth\": true,\r\n \"isOperationalHealth\": false,\r\n \"isLocationCompliance\": true,\r\n \"isBandWidth\": false,\r\n \"isVDAMonitoring\": true,\r\n \"isVDAHealth\": false,\r\n \"isDashboardAnalytics\": true,\r\n \"isPlaybacks\": false,\r\n \"isEvents\": true,\r\n \"isPageViews\": false,\r\n \"isSessions\": true,\r\n \"isDownloadFTP\": false,\r\n \"isManageLocations\": true,\r\n \"isUpdateLocation\": false,\r\n \"isGroupsLocation\": true,\r\n \"isPlayersLocation\": false,\r\n \"isSmartGroups\": true,\r\n \"isTags\": false,\r\n \"isMediaLibrary\": true,\r\n \"isFilesLibrary\": false,\r\n \"isMediaFeed\": true,\r\n \"isPresentations\": false,\r\n \"isAuthorizeContent\": true,\r\n \"isPublishLocation\": false,\r\n \"isPublishLocationGroup\": true,\r\n \"isPublishSmartGroups\": false,\r\n \"isPublishUpdatePresentation\": true,\r\n \"isPublishUpdatePlaylist\": false,\r\n \"isPublishFirmware\": true,\r\n \"isPublishLog\": false,\r\n \"isWall\": true,\r\n \"isContentLog\": false,\r\n \"cmCampaigns\": 2,\r\n \"cmCanApprove\": true,\r\n \"cmRundown\": false,\r\n \"cmDayparting\": false,\r\n \"cmBanners\": false,\r\n \"cmProManufacturer\": true,\r\n \"cmProBrands\": false,\r\n \"cmProCategories\": false,\r\n \"cmProRevenueClass\": false,\r\n \"cmProFillers\": true,\r\n \"cmProInserts\": false,\r\n \"cmProPresentations\": false,\r\n \"cmProSettings\": false,\r\n \"cmProReports\": true,\r\n \"cmProInventory\": false,\r\n \"cmInventory\": 2,\r\n \"cmProDisclaimer\": false,\r\n \"cmReports\": 1,\r\n \"isTVControl\": false,\r\n \"isDownloadControl\": true,\r\n \"isRemoteSetup\": false,\r\n \"isBDeploy\": true,\r\n \"isPlayerSetup\": false,\r\n \"isSmartActions\": true,\r\n \"isStocks\": false,\r\n \"isLicenses\": true,\r\n \"isUsers\": false,\r\n \"isSetupUser\": true,\r\n \"isPlayListStandard\": false,\r\n \"isDayparting\": true,\r\n \"isAdminClients\": false\r\n }, \r\n \"clientsIds\": [\r\n 23,24,26,27,28,29,30,31,32,33,34,35,36, 38, 33\r\n ]\r\n }\r\n}"); Request request = new Request.Builder() .url("host:port/zynchro.api.system-config/v1/profiles/33") .method("PATCH", body) .addHeader("Content-Type", "application/json") .addHeader("Authorization", "••••••") .build(); Response response = client.newCall(request).execute();
Next are listed the params required in the request body
Field | SubField | Type | Description | IsRequired |
---|---|---|---|---|
header | object | Y | ||
transactionId | text | A custom value to identify the data related to the request in the response (you can see the transactionId in the response header). Example:
Note: This field is not related to the creation of a new campaign, must be used by the client app in order to identify the request/response (if that is useful), the same value can be sended in multiple request (it’s not validated that the same value was sended before) | N | |
Data | | Object | The specific body data related to the request | Y |
profile | Object | The profile object (look at the next table for further details) | Y | |
clientsIds | Array | An array of ints values, each value must be a valid client id Every time this array is sent, it replaces the values previously sent | Y |
Profile Object
Field | SubField | Type | Description | IsRequired |
---|---|---|---|---|
profile | All the boolean values are not required because by default the value is false it is not sended | Y | ||
name | text | The name of the profile | Y | |
isDashboard | boolean | Used to access data in:
| N | |
isMap | boolean | Used to access data in:
| N | |
isList | int | Used to access data in:
These are the possible values this field can retrieve:
| Y | |
isSnapshotMosaic | boolean | Used to access data in:
| N | |
isPlayerHealth | boolean | Used to access data in:
| N | |
isOperationalHealth | boolean | Used to access data in:
| N | |
isLocationCompliance | boolean | Used to access data in:
| N | |
isBandWidth | boolean | Used to access data in:
| N | |
isVDAMonitoring | boolean | Used to access data in:
| N | |
isVDAHealth | boolean | Used to access data in:
| N | |
isDashboardAnalytics | boolean | Used to access data in:
| N | |
isPlaybacks | boolean | Used to access data in:
| N | |
isEvents | boolean | Used to access data in:
| N | |
isPageViews | boolean | Used to access data in:
| N | |
isSessions | boolean | Used to access data in:
| N | |
isDownloadFTP | boolean | Used to access data in:
| N | |
isManageLocations | boolean | Used to access data in:
| N | |
isUpdateLocation | boolean | Used to access data in:
| N | |
isGroupsLocation | boolean | Used to access data in:
| N | |
isPlayersLocation | boolean | Used to access data in:
| N | |
isSmartGroups | boolean | Used to access data in:
| N | |
isTags | boolean | Used to access data in:
| N | |
isMediaLibrary | boolean | Used to access data in:
| N | |
isFilesLibrary | boolean | Used to access data in:
| N | |
isMediaFeed | boolean | Used to access data in:
| N | |
isPresentations | boolean | Used to access data in:
| N | |
isAuthorizeContent | boolean | Used to access data in:
| N | |
isPublishLocation | boolean | Used to access data in:
| N | |
isPublishLocationGroup | boolean | Used to access data in:
| N | |
isPublishSmartGroups | boolean | Used to access data in:
| N | |
isPublishUpdatePresentation | boolean | Used to access data in:
| N | |
isPublishUpdatePlaylist | boolean | Used to access data in:
| N | |
isPublishFirmware | boolean | Used to access data in:
| N | |
isPublishLog | boolean | Used to access data in:
| N | |
isWall | boolean | Used to access data in:
| N | |
isContentLog | boolean | Used to access data in:
| N | |
cmCampaigns | int | Used to access data in:
| Y | |
cmCanApprove | boolean | It is used to change a status campaign to approved | N | |
cmRundown | boolean | Used to access data in:
| N | |
cmDayparting | boolean | Used to access data in:
| N | |
cmBanners | boolean | Used to access data in:
| N | |
cmProManufacturer | boolean | Used to access data in:
| N | |
cmProBrands | boolean | Used to access data in:
| N | |
cmProCategories | boolean | Used to access data in:
| N | |
cmProRevenueClass | boolean | Used to access data in:
| N | |
cmProFillers | boolean | Used to access data in:
| N | |
cmProInserts | boolean | Used to access data in:
| N | |
cmProPresentations | boolean | Used to access data in:
| N | |
cmProSettings | boolean | Used to access data in:
| N | |
cmProReports | boolean | Used to access data in:
| N | |
cmProInventory | boolean | Used to access data in:
| N | |
cmInventory | int | Used to access data in:
| Y | |
cmProDisclaimer | boolean | Used to access data in:
| N | |
cmReports | int | Used to access data in:
| Y | |
isTVControl | boolean | Used to access data in:
| N | |
isDownloadControl | boolean | Used to access data in:
| N | |
isRemoteSetup | boolean | Used to access data in:
| N | |
isBDeploy | boolean | Used to access data in:
| N | |
isPlayerSetup | boolean | Used to access data in:
| N | |
isSmartActions | boolean | Used to access data in:
| N | |
isStocks | boolean | Used to access data in:
| N | |
isLicenses | boolean | Used to access data in:
| N | |
isUsers | boolean | Used to access data in:
| N | |
isSetupUser | boolean | Used to access data in:
| N | |
isPlayListStandard | boolean | Used to access data in:
| N | |
isDayparting | boolean | Used to access data in:
| N | |
isAdminClients | boolean | Used to access data in:
| N | |
clients | Object | Includes the list of the clients thst have this profile //this field is unavalible no | Y |
Consuming Service
Example Request
Consuming service
(PATCH) URL:HOST:PORT/zynchro.api.system-config/v1/profiles/1?transaction_id=12233445666
Request Body (JSON RAW):
Copy code{ "header": { "transactionId": "123455566677788" }, "data": { "profile": { "name": "UK Content Publisher TEST 6/17", "isDashboard": false, "isMap": true, "isList": 1, "isSnapshotMosaic": false, "isPlayerHealth": true, "isOperationalHealth": false, "isLocationCompliance": true, "isBandWidth": false, "isVDAMonitoring": true, "isVDAHealth": false, "isDashboardAnalytics": true, "isPlaybacks": false, "isEvents": true, "isPageViews": false, "isSessions": true, "isDownloadFTP": false, "isManageLocations": true, "isUpdateLocation": false, "isGroupsLocation": true, "isPlayersLocation": false, "isSmartGroups": true, "isTags": false, "isMediaLibrary": true, "isFilesLibrary": false, "isMediaFeed": true, "isPresentations": false, "isAuthorizeContent": true, "isPublishLocation": false, "isPublishLocationGroup": true, "isPublishSmartGroups": false, "isPublishUpdatePresentation": true, "isPublishUpdatePlaylist": false, "isPublishFirmware": true, "isPublishLog": false, "isWall": true, "isContentLog": false, "cmCampaigns": 2, "cmCanApprove": true, "cmRundown": false, "cmDayparting": false, "cmBanners": false, "cmProManufacturer": true, "cmProBrands": false, "cmProCategories": false, "cmProRevenueClass": false, "cmProFillers": true, "cmProInserts": false, "cmProPresentations": false, "cmProSettings": false, "cmProReports": true, "cmProInventory": false, "cmInventory": 2, "cmProDisclaimer": false, "cmReports": 1, "isTVControl": false, "isDownloadControl": true, "isRemoteSetup": false, "isBDeploy": true, "isPlayerSetup": false, "isSmartActions": true, "isStocks": false, "isLicenses": true, "isUsers": false, "isSetupUser": true, "isPlayListStandard": false, "isDayparting": true, "isAdminClients": false }, "clientsIds": [ 23,24,26,27,28,29,30,31,32,33,34,35,36, 38, 33 ] } }
Response
Response 200 OK
If the params present in the request are valid, then you will receive a response 200 "ok" message code look at the next example:
Copy code{ "header": { "resultCode": "ok", "messageCode": "ok", "messageDescription": "request ok", "transactionId": "123455566677788" }, "data": { "success": true, "profile": { "id": 33, "name": "UK Content Publisher TEST 6/17", "isDashboard": false, "isMap": true, "isList": 1, "isSnapshotMosaic": false, "isPlayerHealth": true, "isOperationalHealth": false, "isLocationCompliance": true, "isBandWidth": false, "isVDAMonitoring": true, "isVDAHealth": false, "isDashboardAnalytics": true, "isPlaybacks": false, "isEvents": true, "isPageViews": false, "isSessions": true, "isDownloadFTP": false, "isManageLocations": true, "isUpdateLocation": false, "isGroupsLocation": true, "isPlayersLocation": false, "isSmartGroups": true, "isTags": false, "isMediaLibrary": true, "isFilesLibrary": false, "isMediaFeed": true, "isPresentations": false, "isAuthorizeContent": true, "isPublishLocation": false, "isPublishLocationGroup": true, "isPublishSmartGroups": false, "isPublishUpdatePresentation": true, "isPublishUpdatePlaylist": false, "isPublishFirmware": true, "isPublishLog": false, "isWall": true, "isContentLog": false, "cmCampaigns": 2, "cmCanApprove": true, "cmRundown": false, "cmDayparting": false, "cmBanners": false, "cmProManufacturer": true, "cmProBrands": false, "cmProCategories": false, "cmProRevenueClass": false, "cmProFillers": true, "cmProInserts": false, "cmProPresentations": false, "cmProSettings": false, "cmProReports": true, "cmProInventory": false, "cmInventory": 2, "cmProDisclaimer": false, "cmReports": 1, "isTVControl": false, "isDownloadControl": true, "isRemoteSetup": false, "isBDeploy": true, "isPlayerSetup": false, "isSmartActions": true, "isStocks": false, "isLicenses": true, "isUsers": false, "isSetupUser": true, "isPlayListStandard": false, "isDayparting": true, "isAdminClients": false, "clients": null }, "message": "" } }
Description of the response data
Field | SubField | Type | Description |
---|---|---|---|
header | | Object | Specific data related to the response |
| resultCode | text | The result code of the response, can be: · error -> if errors were found · ok -> if NO errors were found |
| messageCode | text | The message code related to the result code of the response, can be: Example: |
| messageDescription | text | The description of the message code Example: · request ok · Please check your params fields |
| transactionId | text | The transactionId specified in the request, if no transactionId was sended in the request then the transacionId in the response will be null |
errors | | Array | This field is present if there are errors in the request |
| fieldName | text | The field with errors |
| fieldDesc | text | The description of the error |
Data | | Array | The specific response data related to the request |
success | boolean | Indicates if the request was successfully processed | |
profile | Object | The profile data updated |
profile Object
Field | SubField | Type | Description |
---|---|---|---|
profile | |||
id | int | The identifier of the profile Example: 1 | |
name | text | The name of the profile | |
isDashboard | boolean | Used to access data in:
| |
isMap | boolean | Used to access data in:
| |
isList | int | Used to access data in:
These are the possible values this field can retrieve:
| |
isSnapshotMosaic | boolean | Used to access data in:
| |
isPlayerHealth | boolean | Used to access data in:
| |
isOperationalHealth | boolean | Used to access data in:
| |
isLocationCompliance | boolean | Used to access data in:
| |
isBandWidth | boolean | Used to access data in:
| |
isVDAMonitoring | boolean | Used to access data in:
| |
isVDAHealth | boolean | Used to access data in:
| |
isDashboardAnalytics | boolean | Used to access data in:
| |
isPlaybacks | boolean | Used to access data in:
| |
isEvents | boolean | Used to access data in:
| |
isPageViews | boolean | Used to access data in:
| |
isSessions | boolean | Used to access data in:
| |
isDownloadFTP | boolean | Used to access data in:
| |
isManageLocations | boolean | Used to access data in:
| |
isUpdateLocation | boolean | Used to access data in:
| |
isGroupsLocation | boolean | Used to access data in:
| |
isPlayersLocation | boolean | Used to access data in:
| |
isSmartGroups | boolean | Used to access data in:
| |
isTags | boolean | Used to access data in:
| |
isMediaLibrary | boolean | Used to access data in:
| |
isFilesLibrary | boolean | Used to access data in:
| |
isMediaFeed | boolean | Used to access data in:
| |
isPresentations | boolean | Used to access data in:
| |
isAuthorizeContent | boolean | Used to access data in:
| |
isPublishLocation | boolean | Used to access data in:
| |
isPublishLocationGroup | boolean | Used to access data in:
| |
isPublishSmartGroups | boolean | Used to access data in:
| |
isPublishUpdatePresentation | boolean | Used to access data in:
| |
isPublishUpdatePlaylist | boolean | Used to access data in:
| |
isPublishFirmware | boolean | Used to access data in:
| |
isPublishLog | boolean | Used to access data in:
| |
isWall | boolean | Used to access data in:
| |
isContentLog | boolean | Used to access data in:
| |
cmCampaigns | int | Used to access data in:
| |
cmCanApprove | boolean | It is used to change a status campaign to approved | |
cmRundown | boolean | Used to access data in:
| |
cmDayparting | boolean | Used to access data in:
| |
cmBanners | boolean | Used to access data in:
| |
cmProManufacturer | boolean | Used to access data in:
| |
cmProBrands | boolean | Used to access data in:
| |
cmProCategories | boolean | Used to access data in:
| |
cmProRevenueClass | boolean | Used to access data in:
| |
cmProFillers | boolean | Used to access data in:
| |
cmProInserts | boolean | Used to access data in:
| |
cmProPresentations | boolean | Used to access data in:
| |
cmProSettings | boolean | Used to access data in:
| |
cmProReports | boolean | Used to access data in:
| |
cmProInventory | boolean | Used to access data in:
| |
cmInventory | int | Used to access data in:
| |
cmProDisclaimer | boolean | Used to access data in:
| |
cmReports | int | Used to access data in:
| |
isTVControl | boolean | Used to access data in:
| |
isDownloadControl | boolean | Used to access data in:
| |
isRemoteSetup | boolean | Used to access data in:
| |
isBDeploy | boolean | Used to access data in:
| |
isPlayerSetup | boolean | Used to access data in:
| |
isSmartActions | boolean | Used to access data in:
| |
isStocks | boolean | Used to access data in:
| |
isLicenses | boolean | Used to access data in:
| |
isUsers | boolean | Used to access data in:
| |
isSetupUser | boolean | Used to access data in:
| |
isPlayListStandard | boolean | Used to access data in:
| |
isDayparting | boolean | Used to access data in:
| |
isAdminClients | boolean | Used to access data in:
| |
clients | Object | Includes the list of the clients thst have this profile //this field is unavalible no |
Response 400
If there are errors with the request, then you will receive a 400 message response BAD_REQUEST with the errors field present, like the following example:
Copy code{ "header": { "resultCode": "error", "messageCode": "BAD_REQUEST", "messageDescription": "Please check your params fields", "transactionId": "123455566677788" }, "errors": [ { "fieldName": "name", "fieldDesc": "Field is required, and must be of type String " }, { "fieldName": "cmReports", "fieldDesc": "Field is required, and must be of type int and > 0 " }, { "fieldName": "cmInventory", "fieldDesc": "Field is required, and must be of type int and > 0 " }, { "fieldName": "clientsIds", "fieldDesc": "Field is required, and must be of type Array " }, { "fieldName": "isList", "fieldDesc": "Field is required, and must be of type int and > 0 " }, { "fieldName": "cmCampaigns", "fieldDesc": "Field is required, and must be of type int and > 0 " } ] }
Response 401
If you dont send any token, then you will receive a error message of "unauthorized", look at the next example:
Copy code{ "error": "unauthorized", "error_description": "Full authentication is required to access this resource" }
If you send a Token, but the Token you are sending is expired, then you will receive a response message with an "invalid_token" error, look at the next example:
Copy code{ "error": "invalid_token", "error_description": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE3MDM2MTk5NzMsInVzZXJfbmFtZSI6ImFsZWphbmRyby56YW5hYnJpYUBkaWdpd29ya3MuY29tLm14IiwiYXV0aG9yaXRpZXMiOlsiUk9MRV9TWVNURU1BRE1JTiJdLCJqdGkiOiJHTGtQb3hQbVRTZUs2RFhmc1NfNkUxRkMxZmsiLCJjbGllbnRfaWQiOiJ6eW5jaHJvIiwic2NvcGUiOlsicmVhZCIsIndyaXRlIl19.yAFbdU18wMtQXSGUY3_noQn4BQv0RqYjDbw0sr1x6Yk" }
This is the data retrieved when the 401 Unauthorized is retrieved:
Field | SubField | Type | Description |
---|---|---|---|
error | | text | The type of the error, can be:
|
error_description | text | The description of the error, for the "invalid_token", this field retrieves the bearer token you're sending |