> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://mediakind.ferndocs.com/harmonic/api/vos/configure-settings/set-service-global-setting/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://mediakind.ferndocs.com/_mcp/server. # Set service global setting PUT https://device.example.com:443/cluster1/vos-api/configure/v1/settings/service Content-Type: application/json Set service global setting. Reference: https://mediakind.ferndocs.com/harmonic/api/vos/configure-settings/set-service-global-setting ## Authentication - `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer `, where token is your auth token. ## Request ### Body (application/json) This endpoint expects a com.harmonicinc.vos.app.configure.model.GlobalServiceSetting. - `dataGrooming` (com.harmonicinc.vos.app.configure.model.source.DataGrooming, required) - `globalAudioSetting` (com.harmonicinc.vos.app.configure.model.GlobalAudioSetting, required) - `globalSourceSetting` (com.harmonicinc.vos.app.configure.model.GlobalSourceSetting, required) - `globalVideoSetting` (com.harmonicinc.vos.app.configure.model.GlobalVideoSetting, required) - `enableAutoUnencrypted` (boolean, optional) — Indicate if auto_unencrypted is enabled - `enablePersistPlaylist` (boolean, optional) — Indicate if persist playlist is enabled for LIVE_EVENT services - `globalCloudDestinationSettings` (com.harmonicinc.vos.app.configure.model.GlobalCloudDestinationSettings, optional) - `globalDailySyncTime` (com.harmonicinc.vos.app.configure.model.GlobalDailySyncTime, optional) - `globalDescramblingSetting` (com.harmonicinc.vos.app.configure.model.GlobalDescramblingSetting, optional) - `globalEsamSetting` (com.harmonicinc.vos.app.configure.model.GlobalEsamSetting, optional) - `globalGeoSyncSetting` (com.harmonicinc.vos.app.configure.model.GlobalGeoSyncSetting, optional) - `globalLiveIngestSetting` (com.harmonicinc.vos.app.configure.model.GlobalLiveIngestSetting, optional) - `globalMuxSetting` (com.harmonicinc.vos.app.configure.model.GlobalMuxSetting, optional) - `globalNielsenSetting` (com.harmonicinc.vos.app.configure.model.GlobalNielsenSetting, optional) - `globalPackagingSetting` (com.harmonicinc.vos.app.configure.model.GlobalPackagingSetting, optional) - `globalScte35Setting` (com.harmonicinc.vos.app.configure.model.GlobalScte35Setting, optional) - `globalSpeechEngineSetting` (com.harmonicinc.vos.app.configure.model.GlobalSpeechServiceSetting, optional) - `globalSynamediaWatermarkSetting` (com.harmonicinc.vos.app.configure.model.GlobalSynamediaWatermarkSetting, optional) - `gpsUtcOffset` (integer, optional) — GPS UTC offset in seconds - `scheduler360Setting` (com.harmonicinc.vos.app.configure.model.Scheduler360Setting, optional) - `sdiLatencyOffset` (integer, optional) — SDI latency offset in seconds, range -100..100ms, step 1ms, default is 0 - `serviceLimit` (com.harmonicinc.vos.app.configure.model.ServiceLimit, optional) ## Response ### 200 Setting Updated ### 201 Created ## Errors ### 400 Bad Request Error Setting Update Failed - `any` ### 401 Unauthorized Error Unauthorized - `any` ### 403 Forbidden Error Forbidden - `any` ### 404 Not Found Error Not Found - `any` ## Types ### com.harmonicinc.vos.app.configure.model.source.DataGrooming - `ccConversionMode` (enum, optional) — Prefered Closed Caption type - Allowed values: `AUTO`, `EIA608`, `CEA708` - `st2038Tracks` (list of com.harmonicinc.vos.app.configure.model.source.St2038Track, optional) — ANC data tracks in ST-2038 PID - `teletextSubtitleMode` (enum, optional) — Teletext subtitle parsing mode - Allowed values: `EBU_TELETEXT`, `CAVENA_P31` - `tracks` (list of com.harmonicinc.vos.app.configure.model.source.DataTrack, optional) — Essential metadata of data tracks ### com.harmonicinc.vos.app.configure.model.GlobalAudioSetting - `copyRight` (enum, required) — Specifies copyRight properties of audio - Allowed values: `COPYRIGHTED_ORIGINAL`, `COPYRIGHTED_COPY`, `UNCOPYRIGHTED_ORIGINAL`, `UNCOPYRIGHTED_COPY` ### com.harmonicinc.vos.app.configure.model.GlobalSourceSetting - `autoSlateDisableConditions` (list of enum, optional) — Specify the auto slate disable conditions - Allowed values: `e_SCRAMBLED_PID` - `playoutLiveSourceProtocol` (enum, optional) — Specify live source protocol for playout - Allowed values: `SRT`, `IP` - `sourceCloudlinkDefaultProtocol` (enum, optional) - Allowed values: `ZIXI`, `HSP` - `sourceDefaultVideoBitrateSizeInMB` (integer, optional) — Specify the Size for video bitrate for pass through profile case if the source is not groomed, default value is 20MB - `sourceFailoverConditions` (list of com.harmonicinc.vos.app.configure.model.SourceFailoverCondition, optional) — Specify the source failover conditions, source data loss will be applied by default - `sourceHspIngestPointSizeInMB` (integer, optional) — Specify the Size for HSP ingest point, default value is 1200MB - `useFragmentingDownloadForHsp` (boolean, optional) — Specify whether to use fragmenting download for HSP input - `visualArtifactWatchdog` (boolean, optional) — Specify enable or disable watchdog for source visual artifact ### com.harmonicinc.vos.app.configure.model.GlobalVideoSetting - `copyRight` (enum, required) — Specifies copyRight properties of video - Allowed values: `COPYRIGHTED_ORIGINAL`, `COPYRIGHTED_COPY`, `UNCOPYRIGHTED_ORIGINAL`, `UNCOPYRIGHTED_COPY` - `stressBias` (enum, required) — Specifies stress bias option applied on video - Allowed values: `SOFT_CLEANER`, `BALANCED`, `SHARPER_BLOCKIER` - `videoStandard` (enum, required) — Specifies video standard of the output - Allowed values: `VS_25_50Hz`, `VS_30_60Hz` - `enableTimecodeNormalization` (boolean, optional) — Indicate if input timecode to UTC timecode normalization is enabled. - `syncMode` (enum, optional) — Specifies sync mode properties of video - Allowed values: `SYNC_TO_SOURCE`, `SYNC_TO_INTERNAL` ### com.harmonicinc.vos.app.configure.model.GlobalCloudDestinationSettings - `dejitterDelayMsec` (integer, optional) — Buffer in milliseconds used to accumulate data before streaming. - `downloadRetryPeriodSec` (integer, optional) — Downloadable time period for data. If the data has not been downloaded during this period, it is discarded. ### com.harmonicinc.vos.app.configure.model.GlobalDailySyncTime - `dailySyncTime` (integer, optional) — Daily sync time (UTC) for the timecode synchronization. Applicable mainly for 29.97/59.94 fps. Range 0..23, default is 0 ### com.harmonicinc.vos.app.configure.model.GlobalDescramblingSetting - `biss2ModeEInjectedId` (string, optional) — Global injected Id for BISS2 mode E descrambling. 32 hexadecimal characters long. On PUT, special value "******" means the value is not modified. GET will return this same special value. ### com.harmonicinc.vos.app.configure.model.GlobalEsamSetting - `defaultFallbackTimeout` (integer, optional) — Default timeout value (seconds) for ESAM source redundancy safety fallback mechanism, a mechanism to fallback to primary source from secondary source if there is no message from POIS, range from 10 to 300, default value is equal to 120 - `defaultPoisEndpoint` (string, optional) — Default POIS endpoint URL. Can be overridden in per-service ESAM configuration. - `enableOobEsam` (boolean, optional) — Enable out-of-band esam server - `oobEsamProtocol` (enum, optional) — (Deprecated) HTTP Protocol of out-of-band esam server - Allowed values: `HTTP`, `HTTPS` - `oobMessagePreroll` (integer, optional) — Pre-roll time for OOB ESAM messages in seconds ranges from 4 to 60, defaults to 4, overrides splice repetition to false if larger than 4 - `scte35PassthruUponEsamUnreachable` (boolean, optional) — Global option to allow in-band SCTE-35 to passthrough to output if the ESAM POIS is unreachable ### com.harmonicinc.vos.app.configure.model.GlobalGeoSyncSetting - `disableAutoRestart` (boolean, optional) — Whether GeoSync service should restart automatically during desynchronization, can be changed at runtime - `mode` (enum, optional) — Specifies the mode of GeoSync, cannot be changed unless all services are offline - Allowed values: `DEFAULT`, `NTP` ### com.harmonicinc.vos.app.configure.model.GlobalLiveIngestSetting - `liveIngestStoragePerService` (boolean, optional) — Support at K8S env only. Live data output will be stored at per service storage with in sspe pod. - `minPvcProvisionedIOPS` (integer, optional) — Support at K8S env only. Minimum provisioned IOPS for PVC. - `minPvcProvisionedThroughput` (integer, optional) — Support at K8S env only. Minimum provisioned throughput in MB/second for PVC. - `minRequiredMemoryInMB` (integer, optional) — Support at K8S env only. The minimum required memory in MB for LIO processes within sspe pod. - `useDiskAsStorage` (boolean, optional) — Support at K8S env only. Live data output will be stored to Azure Disk instead of RAM. ### com.harmonicinc.vos.app.configure.model.GlobalMuxSetting - `divitrackSrtLatency` (integer, optional) — Internal divitrack SRT latency (ms) - `muxStatsReportingSetting` (com.harmonicinc.vos.app.configure.model.MuxStatsReportingSetting, optional) ### com.harmonicinc.vos.app.configure.model.GlobalNielsenSetting - `hostname` (string, required) — IP address or hostname of the Nielsen log publishing server - `password` (string, required) — Password of the Nielsen log publishing server (masked) - `path` (string, required) — Path on the Nielsen log publishing server to store the output files - `port` (integer, required) — TCP port of the Nielsen log publishing server to connect to - `username` (string, required) — Username of the Nielsen log publishing server - `encoderTimezone` (string, optional) — Obsoleted ### com.harmonicinc.vos.app.configure.model.GlobalPackagingSetting - `emptyDataUnitHoldBackInMs` (integer, optional) — Determines how far away from latest PCR will packager generate internal empty data units up to, 0 for automatic. ### com.harmonicinc.vos.app.configure.model.GlobalScte35Setting - `enableScte104Server` (boolean, optional) — Set to true/false to enable/disable the use of SCTE-104 server - `enableScte35AdaptationFieldStuffing` (boolean, optional) — Set to true/false to enable/disable the use of adaptation field stuffing in SCTE35 output - `scte104ServerSetting` (com.harmonicinc.vos.app.configure.model.Scte104ServerSetting, optional) ### com.harmonicinc.vos.app.configure.model.GlobalSpeechServiceSetting - `azureSpeechServiceSetting` (com.harmonicinc.vos.app.configure.model.AzureSpeechServiceSetting, optional) - `nciCaptioning` (com.harmonicinc.vos.app.configure.model.NciCaptioning, optional) ### com.harmonicinc.vos.app.configure.model.GlobalSynamediaWatermarkSetting - `isEnable` (boolean, optional) - `oauthClientId` (string, optional) — Specify Oauth Client ID. - `oauthClientSecret` (string, optional) — Specify Oauth Client Secret. - `oauthServerEndpoint` (string, optional) — Specify Oauth Server Endpoint. The value should contain https at the beginning - `seiUuid` (string, optional) — Retrieve SEI UUID. - `sourceId` (string, optional) — Specify Synamedia source ID - `watermarkManagerEndpoint` (string, optional) — Specify Synamedia Endpoint. The value should contain https at the beginning ### com.harmonicinc.vos.app.configure.model.Scheduler360Setting - `authServer` (string, required) — OAuth Server for Scheduler 360 - `clientID` (string, required) — ClientID for Scheduler 360 OAuth authentication - `clientSecret` (string, required) — ClientSecret for Scheduler 360 OAuth authentication - `endpoint` (string, required) — Endpoint of the Scheduler 360 ### com.harmonicinc.vos.app.configure.model.ServiceLimit - `onlineServiceLimit` (integer, optional) — The maximum limit of total online service - `totalServiceLimit` (integer, optional) — The maximum limit of total service ### com.harmonicinc.vos.app.configure.model.source.St2038Track - `labels` (list of string, optional) — Labels identifier of the data stream - `lineNumber` (list of integer, optional) — Specifies the line(s) where the data is embedded - `scte104OverrideDidSdid` (enum, optional) — When STBmode == STBP_MBR_DPI_PROPRIETARY, SCTE-104 will be decoded from VANC packets with DID == 0x45 and SDID 0x01, INSTEAD of the SCTE-104 standard DID == 0x41 and SDID 0x07 - Allowed values: `e_41_07`, `e_45_01` - `sourceFormat` (enum, optional) — Format of the ANC data - Allowed values: `SCTE_104`, `OP_47`, `SMPTE_2031`, `AFD`, `VITC`, `CLOSED_CAPTION` - `teletextDescriptions` (list of com.harmonicinc.vos.app.configure.model.source.TeletextDescription, optional) — Descriptions of teletext components in source - `teletextMode` (enum, optional) — Specifies which teletext mode is used - Allowed values: `NORMAL`, `LOW_DELAY` ### com.harmonicinc.vos.app.configure.model.source.DataTrack - `countryCode` (string, optional) — Optional Country Code to append to the Language Code - `dataTrackStreamType` (integer, optional) — Type of the data stream; Stream Type defined at http://en.wikipedia.org/wiki/Program-specific_information#Elementary_stream_types - `dpiPidIndex` (integer, optional) — This parameter enables out-of-band SCTE-104, and provides the associated dpi_pid_index. When out-of-band SCTE-104 is enabled, in-band input SCTE-35 messages are discarded - `dtmfSettings` (com.harmonicinc.vos.app.configure.model.source.DtmfSettings, optional) - `labels` (list of string, optional) — Labels identifier of the data stream - `ocrConversionBackgroundColor` (string, optional) — Specifies DVB Subtitles background color for OCR conversion - `pid` (integer, optional) — PID of the stream - `ptsSettings` (com.harmonicinc.vos.app.configure.model.source.PtsSettings, optional) - `skipProcessing` (boolean, optional) — Indicate this data stream will not be processed and will not be mux. - `streamName` (string, optional) — Custom stream name - `teletextToDvbSubsSetting` (com.harmonicinc.vos.app.configure.model.source.TeletextToDvbSubsSetting, optional) ### com.harmonicinc.vos.app.configure.model.SourceFailoverCondition - `type` (enum, optional) — Specify type of SourceFailoverCondition required to support. Note: PID_MISSING may be set to detect a video missing PID or a video decoding issue - Allowed values: `PID_MISSING`, `PCR_MISSING`, `CC_ERROR`, `SCRAMBLED_PID`, `AUDIO_PID_MISSING`, `CUSTOM_PID_MISSING` ### com.harmonicinc.vos.app.configure.model.MuxStatsReportingSetting - `inputPidStatsInterval` (integer, optional) — input pid reporting frequency in seconds [1-600] - `inputProgramStatsInterval` (integer, optional) — input program reporting frequency in seconds [1-600] - `inputTsStatsInterval` (integer, optional) — input ts reporting frequency in seconds [1-600] - `outputPidStatsInterval` (integer, optional) — output pid reporting frequency in seconds [1-600] - `outputProgramStatsInterval` (integer, optional) — output program reporting frequency in seconds [1-59] - `outputTsStatsInterval` (integer, optional) — output ts reporting frequency in seconds [1-600] ### com.harmonicinc.vos.app.configure.model.Scte104ServerSetting - `validateDpiPidIndex` (boolean, optional) — Return error code 126 to alive/inject messages if DPI PID index is not used by any running service. Default is false (return 100). ### com.harmonicinc.vos.app.configure.model.AzureSpeechServiceSetting - `endpointId` (string, optional) — Endpoint ID of custom model, no need to set if using default model - `key` (string, optional) — Subscription key of Azure speech service. Returned value for GET request is '*****'. This specific value '*****' does not modify the key for PUT request - `region` (string, optional) — Region of Azure speech service; if not set, vos region will be used by default ### com.harmonicinc.vos.app.configure.model.NciCaptioning - `enabled` (boolean, optional) — Enable NCI captioning ### com.harmonicinc.vos.app.configure.model.source.TeletextDescription - `teletextHexPageNum` (string, required) — Teletext page number in hexadecimal format. Range: Hex 0x100 - 0x8FF - `language` (enum, optional) — Teletext language. default:English - Allowed values: `ENG`, `DEU`, `SWE`, `FIN`, `HUN`, `ITA`, `FRA`, `POR`, `SPA`, `CES`, `SLK`, `POL`, `TUR`, `SRP`, `HRV`, `SLV`, `RON`, `EST`, `LAV`, `LIT`, `RUS`, `BUL`, `UKR`, `ELL`, `ARA`, `HEB` - `teletextType` (integer, optional) — Teletext type. Initial Teletext page, Teletext Subtitle Page, Additional Information Page, Hearing Impaired, Program Schdule Page ### com.harmonicinc.vos.app.configure.model.source.DtmfSettings - `audioSourceLabel` (string, required) — Label of audio track carrying the DTMF signal - `profiles` (list of com.harmonicinc.vos.app.configure.model.source.DtmfProfile, required) — List of DTMF profiles (min. 1, max. 6) ### com.harmonicinc.vos.app.configure.model.source.PtsSettings - `mode` (enum, required) — e_PASSTHROUGH (default) or e_GENERATE. When e_GENERATE is selected, the input PTS is discarded, and the output PTS is automatically generated. - Allowed values: `e_PASSTHROUGH`, `e_GENERATE` - `delayAdjustment` (integer, optional) — Specifies the data delay in millisecond in order to synchronize with the video stream, range -1250ms to 15000ms, default 0. Applicable to each mode. ### com.harmonicinc.vos.app.configure.model.source.TeletextToDvbSubsSetting - `ancillaryPageId` (integer, required) — Ancillary Page Id, default: 0, range: 0-255 - `font` (string, required) — Font name, default: DejaVuSans.ttf. Value is the file name including dot-extension. Special case 'dejavu' mapped to 'DejaVuSans.ttf' internally. - `forceDDS` (boolean, required) — Force DDS, default: false - `language` (string, required) — Language, default:English - `latency` (integer, required) — Latency in ms, default: 500, range: 40-1000 ms - `pageId` (integer, required) — Page Id, default: 0, range: 0-255 - `pageNumber` (integer, required) — Page Number, default: 256, range: 256 - 2201, For reference in Hex 0x100 - 0x899 - `teletextTimeout` (integer, required) — Teletext Timeout in ms, default: 10, range: 0-9999 ms - `transparencyLevel` (integer, required) — Transparency Level, default: 0, range: 0-100 ### com.harmonicinc.vos.app.configure.model.source.DtmfProfile - `command` (string, required) — 6-character command string built from the character set [0-9,*,#]. - `duration` (integer, required) — For duration-based splice points, duration time in milliseconds. - `preRollTime` (integer, required) — For normal splices points, pre-roll time in milliseconds, within range [4000, 25000], default: 4000. - `spliceMode` (enum, required) — Splice mode: NO_DURATION, AUTO_RETURN, NO_AUTO_RETURN - Allowed values: `NO_DURATION`, `AUTO_RETURN`, `NO_AUTO_RETURN` - `spliceType` (enum, required) — Splice type: START_NORMAL, START_IMMEDIATE, END_NORMAL, END_IMMEDIATE - Allowed values: `START_NORMAL`, `START_IMMEDIATE`, `END_NORMAL`, `END_IMMEDIATE` ## Examples ### Example 1 **Request** ```json { "globalAudioSetting": { "copyRight": "COPYRIGHTED_ORIGINAL" }, "globalVideoSetting": { "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" } } ``` **Response** ```json {} ``` **SDK Code** ```python import requests url = "https://device.example.com/cluster1/vos-api/configure/v1/settings/service" payload = { "globalAudioSetting": { "copyRight": "COPYRIGHTED_ORIGINAL" }, "globalVideoSetting": { "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" } } headers = { "Authorization": "Bearer ", "Content-Type": "application/json" } response = requests.put(url, json=payload, headers=headers) print(response.json()) ``` ```javascript const url = 'https://device.example.com/cluster1/vos-api/configure/v1/settings/service'; const options = { method: 'PUT', headers: {Authorization: 'Bearer ', 'Content-Type': 'application/json'}, body: '{"globalAudioSetting":{"copyRight":"COPYRIGHTED_ORIGINAL"},"globalVideoSetting":{"copyRight":"COPYRIGHTED_ORIGINAL","stressBias":"SOFT_CLEANER","videoStandard":"VS_25_50Hz"}}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://device.example.com/cluster1/vos-api/configure/v1/settings/service" payload := strings.NewReader("{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("Authorization", "Bearer ") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://device.example.com/cluster1/vos-api/configure/v1/settings/service") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["Authorization"] = 'Bearer ' request["Content-Type"] = 'application/json' request.body = "{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://device.example.com/cluster1/vos-api/configure/v1/settings/service") .header("Authorization", "Bearer ") .header("Content-Type", "application/json") .body("{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}") .asString(); ``` ```php request('PUT', 'https://device.example.com/cluster1/vos-api/configure/v1/settings/service', [ 'body' => '{ "globalAudioSetting": { "copyRight": "COPYRIGHTED_ORIGINAL" }, "globalVideoSetting": { "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" } }', 'headers' => [ 'Authorization' => 'Bearer ', 'Content-Type' => 'application/json', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://device.example.com/cluster1/vos-api/configure/v1/settings/service"); var request = new RestRequest(Method.PUT); request.AddHeader("Authorization", "Bearer "); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = [ "Authorization": "Bearer ", "Content-Type": "application/json" ] let parameters = [ "globalAudioSetting": ["copyRight": "COPYRIGHTED_ORIGINAL"], "globalVideoSetting": [ "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://device.example.com/cluster1/vos-api/configure/v1/settings/service")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` ### Example 2 **Request** ```json { "globalAudioSetting": { "copyRight": "COPYRIGHTED_ORIGINAL" }, "globalVideoSetting": { "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" } } ``` **Response** ```json {} ``` **SDK Code** ```python import requests url = "https://device.example.com/cluster1/vos-api/configure/v1/settings/service" payload = { "globalAudioSetting": { "copyRight": "COPYRIGHTED_ORIGINAL" }, "globalVideoSetting": { "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" } } headers = { "Authorization": "Bearer ", "Content-Type": "application/json" } response = requests.put(url, json=payload, headers=headers) print(response.json()) ``` ```javascript const url = 'https://device.example.com/cluster1/vos-api/configure/v1/settings/service'; const options = { method: 'PUT', headers: {Authorization: 'Bearer ', 'Content-Type': 'application/json'}, body: '{"globalAudioSetting":{"copyRight":"COPYRIGHTED_ORIGINAL"},"globalVideoSetting":{"copyRight":"COPYRIGHTED_ORIGINAL","stressBias":"SOFT_CLEANER","videoStandard":"VS_25_50Hz"}}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://device.example.com/cluster1/vos-api/configure/v1/settings/service" payload := strings.NewReader("{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}") req, _ := http.NewRequest("PUT", url, payload) req.Header.Add("Authorization", "Bearer ") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://device.example.com/cluster1/vos-api/configure/v1/settings/service") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Put.new(url) request["Authorization"] = 'Bearer ' request["Content-Type"] = 'application/json' request.body = "{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.put("https://device.example.com/cluster1/vos-api/configure/v1/settings/service") .header("Authorization", "Bearer ") .header("Content-Type", "application/json") .body("{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}") .asString(); ``` ```php request('PUT', 'https://device.example.com/cluster1/vos-api/configure/v1/settings/service', [ 'body' => '{ "globalAudioSetting": { "copyRight": "COPYRIGHTED_ORIGINAL" }, "globalVideoSetting": { "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" } }', 'headers' => [ 'Authorization' => 'Bearer ', 'Content-Type' => 'application/json', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://device.example.com/cluster1/vos-api/configure/v1/settings/service"); var request = new RestRequest(Method.PUT); request.AddHeader("Authorization", "Bearer "); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"globalAudioSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\"\n },\n \"globalVideoSetting\": {\n \"copyRight\": \"COPYRIGHTED_ORIGINAL\",\n \"stressBias\": \"SOFT_CLEANER\",\n \"videoStandard\": \"VS_25_50Hz\"\n }\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = [ "Authorization": "Bearer ", "Content-Type": "application/json" ] let parameters = [ "globalAudioSetting": ["copyRight": "COPYRIGHTED_ORIGINAL"], "globalVideoSetting": [ "copyRight": "COPYRIGHTED_ORIGINAL", "stressBias": "SOFT_CLEANER", "videoStandard": "VS_25_50Hz" ] ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://device.example.com/cluster1/vos-api/configure/v1/settings/service")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "PUT" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```