curl --request POST \
--url https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json-patch+json' \
--data '
{
"$type": "Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core",
"market_data_environment_name": "Example market data",
"provider_id": "<string>",
"cmdty_futures_data": [
{
"$type": "Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core",
"provider_id": "<string>",
"derivitec_created": "<string>",
"derivitec_modified": "<string>",
"uploaded_date_time": "<string>",
"derivitec_modified_by": "<string>",
"uploaded_by": "<string>",
"rolled": false,
"ask": 123,
"bid": 123,
"close": 123,
"currency": "<string>",
"date": "2023-11-07T05:31:56Z",
"expiration_date": "2023-11-07T05:31:56Z",
"high": 123,
"low": 123,
"identifier": {
"$type": "Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core",
"code": "<string>",
"market_identification_code": "<string>"
},
"settle": 123,
"volume": 123,
"futures_market_id": "<string>"
}
]
}
'import requests
url = "https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData"
payload = {
"$type": "Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core",
"market_data_environment_name": "Example market data",
"provider_id": "<string>",
"cmdty_futures_data": [
{
"$type": "Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core",
"provider_id": "<string>",
"derivitec_created": "<string>",
"derivitec_modified": "<string>",
"uploaded_date_time": "<string>",
"derivitec_modified_by": "<string>",
"uploaded_by": "<string>",
"rolled": False,
"ask": 123,
"bid": 123,
"close": 123,
"currency": "<string>",
"date": "2023-11-07T05:31:56Z",
"expiration_date": "2023-11-07T05:31:56Z",
"high": 123,
"low": 123,
"identifier": {
"$type": "Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core",
"code": "<string>",
"market_identification_code": "<string>"
},
"settle": 123,
"volume": 123,
"futures_market_id": "<string>"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json-patch+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({
$type: 'Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core',
market_data_environment_name: 'Example market data',
provider_id: '<string>',
cmdty_futures_data: [
{
$type: 'Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core',
provider_id: '<string>',
derivitec_created: '<string>',
derivitec_modified: '<string>',
uploaded_date_time: '<string>',
derivitec_modified_by: '<string>',
uploaded_by: '<string>',
rolled: false,
ask: 123,
bid: 123,
close: 123,
currency: '<string>',
date: '2023-11-07T05:31:56Z',
expiration_date: '2023-11-07T05:31:56Z',
high: 123,
low: 123,
identifier: {
$type: 'Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core',
code: '<string>',
market_identification_code: '<string>'
},
settle: 123,
volume: 123,
futures_market_id: '<string>'
}
]
})
};
fetch('https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'$type' => 'Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core',
'market_data_environment_name' => 'Example market data',
'provider_id' => '<string>',
'cmdty_futures_data' => [
[
'$type' => 'Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core',
'provider_id' => '<string>',
'derivitec_created' => '<string>',
'derivitec_modified' => '<string>',
'uploaded_date_time' => '<string>',
'derivitec_modified_by' => '<string>',
'uploaded_by' => '<string>',
'rolled' => false,
'ask' => 123,
'bid' => 123,
'close' => 123,
'currency' => '<string>',
'date' => '2023-11-07T05:31:56Z',
'expiration_date' => '2023-11-07T05:31:56Z',
'high' => 123,
'low' => 123,
'identifier' => [
'$type' => 'Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core',
'code' => '<string>',
'market_identification_code' => '<string>'
],
'settle' => 123,
'volume' => 123,
'futures_market_id' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json-patch+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData"
payload := strings.NewReader("{\n \"$type\": \"Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core\",\n \"market_data_environment_name\": \"Example market data\",\n \"provider_id\": \"<string>\",\n \"cmdty_futures_data\": [\n {\n \"$type\": \"Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core\",\n \"provider_id\": \"<string>\",\n \"derivitec_created\": \"<string>\",\n \"derivitec_modified\": \"<string>\",\n \"uploaded_date_time\": \"<string>\",\n \"derivitec_modified_by\": \"<string>\",\n \"uploaded_by\": \"<string>\",\n \"rolled\": false,\n \"ask\": 123,\n \"bid\": 123,\n \"close\": 123,\n \"currency\": \"<string>\",\n \"date\": \"2023-11-07T05:31:56Z\",\n \"expiration_date\": \"2023-11-07T05:31:56Z\",\n \"high\": 123,\n \"low\": 123,\n \"identifier\": {\n \"$type\": \"Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core\",\n \"code\": \"<string>\",\n \"market_identification_code\": \"<string>\"\n },\n \"settle\": 123,\n \"volume\": 123,\n \"futures_market_id\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json-patch+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"$type\": \"Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core\",\n \"market_data_environment_name\": \"Example market data\",\n \"provider_id\": \"<string>\",\n \"cmdty_futures_data\": [\n {\n \"$type\": \"Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core\",\n \"provider_id\": \"<string>\",\n \"derivitec_created\": \"<string>\",\n \"derivitec_modified\": \"<string>\",\n \"uploaded_date_time\": \"<string>\",\n \"derivitec_modified_by\": \"<string>\",\n \"uploaded_by\": \"<string>\",\n \"rolled\": false,\n \"ask\": 123,\n \"bid\": 123,\n \"close\": 123,\n \"currency\": \"<string>\",\n \"date\": \"2023-11-07T05:31:56Z\",\n \"expiration_date\": \"2023-11-07T05:31:56Z\",\n \"high\": 123,\n \"low\": 123,\n \"identifier\": {\n \"$type\": \"Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core\",\n \"code\": \"<string>\",\n \"market_identification_code\": \"<string>\"\n },\n \"settle\": 123,\n \"volume\": 123,\n \"futures_market_id\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json-patch+json'
request.body = "{\n \"$type\": \"Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core\",\n \"market_data_environment_name\": \"Example market data\",\n \"provider_id\": \"<string>\",\n \"cmdty_futures_data\": [\n {\n \"$type\": \"Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core\",\n \"provider_id\": \"<string>\",\n \"derivitec_created\": \"<string>\",\n \"derivitec_modified\": \"<string>\",\n \"uploaded_date_time\": \"<string>\",\n \"derivitec_modified_by\": \"<string>\",\n \"uploaded_by\": \"<string>\",\n \"rolled\": false,\n \"ask\": 123,\n \"bid\": 123,\n \"close\": 123,\n \"currency\": \"<string>\",\n \"date\": \"2023-11-07T05:31:56Z\",\n \"expiration_date\": \"2023-11-07T05:31:56Z\",\n \"high\": 123,\n \"low\": 123,\n \"identifier\": {\n \"$type\": \"Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core\",\n \"code\": \"<string>\",\n \"market_identification_code\": \"<string>\"\n },\n \"settle\": 123,\n \"volume\": 123,\n \"futures_market_id\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"$type": "Derivitec.Web.Core.ApiBaseResponse, Derivitec.Web.Core",
"is_success": true,
"error_messages": []
}Store commodity-futures observations.
Use this operation to publish commodity-futures prices to a writable provider. Each row identifies a futures contract, using a Bloomberg, RIC, or recognised unspecified namespace, and a date; it can supply close, settlement, bid, ask, high, low, volume, and currency values. The contract code and market date determine the expiry used for the accepted row. Unsupported or ambiguous contracts and duplicate rows for the same identifier/date are reported and skipped; other valid rows can be stored, and processing completes before return.
curl --request POST \
--url https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json-patch+json' \
--data '
{
"$type": "Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core",
"market_data_environment_name": "Example market data",
"provider_id": "<string>",
"cmdty_futures_data": [
{
"$type": "Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core",
"provider_id": "<string>",
"derivitec_created": "<string>",
"derivitec_modified": "<string>",
"uploaded_date_time": "<string>",
"derivitec_modified_by": "<string>",
"uploaded_by": "<string>",
"rolled": false,
"ask": 123,
"bid": 123,
"close": 123,
"currency": "<string>",
"date": "2023-11-07T05:31:56Z",
"expiration_date": "2023-11-07T05:31:56Z",
"high": 123,
"low": 123,
"identifier": {
"$type": "Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core",
"code": "<string>",
"market_identification_code": "<string>"
},
"settle": 123,
"volume": 123,
"futures_market_id": "<string>"
}
]
}
'import requests
url = "https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData"
payload = {
"$type": "Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core",
"market_data_environment_name": "Example market data",
"provider_id": "<string>",
"cmdty_futures_data": [
{
"$type": "Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core",
"provider_id": "<string>",
"derivitec_created": "<string>",
"derivitec_modified": "<string>",
"uploaded_date_time": "<string>",
"derivitec_modified_by": "<string>",
"uploaded_by": "<string>",
"rolled": False,
"ask": 123,
"bid": 123,
"close": 123,
"currency": "<string>",
"date": "2023-11-07T05:31:56Z",
"expiration_date": "2023-11-07T05:31:56Z",
"high": 123,
"low": 123,
"identifier": {
"$type": "Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core",
"code": "<string>",
"market_identification_code": "<string>"
},
"settle": 123,
"volume": 123,
"futures_market_id": "<string>"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json-patch+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({
$type: 'Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core',
market_data_environment_name: 'Example market data',
provider_id: '<string>',
cmdty_futures_data: [
{
$type: 'Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core',
provider_id: '<string>',
derivitec_created: '<string>',
derivitec_modified: '<string>',
uploaded_date_time: '<string>',
derivitec_modified_by: '<string>',
uploaded_by: '<string>',
rolled: false,
ask: 123,
bid: 123,
close: 123,
currency: '<string>',
date: '2023-11-07T05:31:56Z',
expiration_date: '2023-11-07T05:31:56Z',
high: 123,
low: 123,
identifier: {
$type: 'Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core',
code: '<string>',
market_identification_code: '<string>'
},
settle: 123,
volume: 123,
futures_market_id: '<string>'
}
]
})
};
fetch('https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'$type' => 'Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core',
'market_data_environment_name' => 'Example market data',
'provider_id' => '<string>',
'cmdty_futures_data' => [
[
'$type' => 'Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core',
'provider_id' => '<string>',
'derivitec_created' => '<string>',
'derivitec_modified' => '<string>',
'uploaded_date_time' => '<string>',
'derivitec_modified_by' => '<string>',
'uploaded_by' => '<string>',
'rolled' => false,
'ask' => 123,
'bid' => 123,
'close' => 123,
'currency' => '<string>',
'date' => '2023-11-07T05:31:56Z',
'expiration_date' => '2023-11-07T05:31:56Z',
'high' => 123,
'low' => 123,
'identifier' => [
'$type' => 'Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core',
'code' => '<string>',
'market_identification_code' => '<string>'
],
'settle' => 123,
'volume' => 123,
'futures_market_id' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json-patch+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData"
payload := strings.NewReader("{\n \"$type\": \"Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core\",\n \"market_data_environment_name\": \"Example market data\",\n \"provider_id\": \"<string>\",\n \"cmdty_futures_data\": [\n {\n \"$type\": \"Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core\",\n \"provider_id\": \"<string>\",\n \"derivitec_created\": \"<string>\",\n \"derivitec_modified\": \"<string>\",\n \"uploaded_date_time\": \"<string>\",\n \"derivitec_modified_by\": \"<string>\",\n \"uploaded_by\": \"<string>\",\n \"rolled\": false,\n \"ask\": 123,\n \"bid\": 123,\n \"close\": 123,\n \"currency\": \"<string>\",\n \"date\": \"2023-11-07T05:31:56Z\",\n \"expiration_date\": \"2023-11-07T05:31:56Z\",\n \"high\": 123,\n \"low\": 123,\n \"identifier\": {\n \"$type\": \"Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core\",\n \"code\": \"<string>\",\n \"market_identification_code\": \"<string>\"\n },\n \"settle\": 123,\n \"volume\": 123,\n \"futures_market_id\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json-patch+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"$type\": \"Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core\",\n \"market_data_environment_name\": \"Example market data\",\n \"provider_id\": \"<string>\",\n \"cmdty_futures_data\": [\n {\n \"$type\": \"Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core\",\n \"provider_id\": \"<string>\",\n \"derivitec_created\": \"<string>\",\n \"derivitec_modified\": \"<string>\",\n \"uploaded_date_time\": \"<string>\",\n \"derivitec_modified_by\": \"<string>\",\n \"uploaded_by\": \"<string>\",\n \"rolled\": false,\n \"ask\": 123,\n \"bid\": 123,\n \"close\": 123,\n \"currency\": \"<string>\",\n \"date\": \"2023-11-07T05:31:56Z\",\n \"expiration_date\": \"2023-11-07T05:31:56Z\",\n \"high\": 123,\n \"low\": 123,\n \"identifier\": {\n \"$type\": \"Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core\",\n \"code\": \"<string>\",\n \"market_identification_code\": \"<string>\"\n },\n \"settle\": 123,\n \"volume\": 123,\n \"futures_market_id\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.riskportal.activeviam.com/api/MarketData/UploadCmdtyFuturesData")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json-patch+json'
request.body = "{\n \"$type\": \"Derivitec.Web.Core.MarketData.ApiUploadCmdtyFuturesDataRequest, Derivitec.Web.Core\",\n \"market_data_environment_name\": \"Example market data\",\n \"provider_id\": \"<string>\",\n \"cmdty_futures_data\": [\n {\n \"$type\": \"Derivitec.Web.Core.MarketData.CmdtyFuturesData, Derivitec.Web.Core\",\n \"provider_id\": \"<string>\",\n \"derivitec_created\": \"<string>\",\n \"derivitec_modified\": \"<string>\",\n \"uploaded_date_time\": \"<string>\",\n \"derivitec_modified_by\": \"<string>\",\n \"uploaded_by\": \"<string>\",\n \"rolled\": false,\n \"ask\": 123,\n \"bid\": 123,\n \"close\": 123,\n \"currency\": \"<string>\",\n \"date\": \"2023-11-07T05:31:56Z\",\n \"expiration_date\": \"2023-11-07T05:31:56Z\",\n \"high\": 123,\n \"low\": 123,\n \"identifier\": {\n \"$type\": \"Derivitec.Web.Core.MarketData.InstrumentIdentifier, Derivitec.Web.Core\",\n \"code\": \"<string>\",\n \"market_identification_code\": \"<string>\"\n },\n \"settle\": 123,\n \"volume\": 123,\n \"futures_market_id\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"$type": "Derivitec.Web.Core.ApiBaseResponse, Derivitec.Web.Core",
"is_success": true,
"error_messages": []
}Authorizations
Body
The upload payload. Provide either ProviderId or MarketDataEnvironmentName, not both; omitting both selects the caller's organisation scope. CmdtyFuturesData must be non-empty and each row supplies a contract identifier, date-only market date, prices, currency, and optional volume; a supplied ExpirationDate is replaced by the date implied by the contract.
Submits dated commodity-futures observations.
Response
Returns whether any rows were stored and errors for invalid providers, unsupported or ambiguous contracts, duplicate dates, or write failures.
Common operation outcome containing a success indicator and any error messages.
Was this page helpful?