For a deeper look into our DataScope Select SOAP API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
3 0 0 2

Getting error while appending identifer to instrument using Http Request

Hi,

When I try to append identifiers through http request, Im getting below error:

{'error': {'message': 'Invalid request parameter Identifiers'}}

Im using below code:

OrderedDict([('Identifiers',OrderedDict([('Identifier','US8180971074'),('IdentifierType','Isin')])),('KeepDuplicates',True)]);

Can anyone help?

pythondss-rest-apidatascope-selectdsshttp
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
Accepted
11.3k 25 8 13

The value of "Identifiers" needs to be JSON array. Please verify if your HTTP request.

Below is the sample of format. If the value is not JSON array, I get the same error.

{
    "Identifiers": [
        {
            "Identifier": "US8180971074",
            "IdentifierType": "Isin"
        }
    ],
    "KeepDuplicates": true
}
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

The code should be modified to be JSON arrays as follows.

OrderedDict([('Identifiers',[OrderedDict([('Identifier','US8180971074'),('IdentifierType','Isin')])]),('KeepDuplicates',True)]);

Upvotes
1.1k 4 3 5

One to many OrderedDict()'s I think.

Do you have the JSON that turns into: From the Sample App, this should work:

{
"Identifiers": [{
"Identifier": "IBM.N",
"IdentifierType": "Ric",
"UserDefinedIdentifier": "UserIdent4A"
}],
"KeepDuplicates": false
}

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Click below to post an Idea Post Idea