API v2 use choice name instead of ID

Hello

I’m using API V2 in Excel to get DXF files.

I have a question when the parameter is a choice List.
Is it possible to pass value of the choice instead of ID of the choice ?

Exemple

URL : https://sdeuc1.eu-central-1.shapediver.com/api/v2/session/12345/export

Body :

{
"max_wait_time":30000,
"exports":{
"id":"0bcf52c961f5db5617e34fe182db09c1"
},
"parameters":{
"f7f219f5-f689-427e-8347-e3a46f9da2e2":true,
"edd673eb-65e8-4ffa-ae97-0e625c46e4ad":"SPM20036-BRIGADINE",
"d7e17137-fda4-464e-9ff0-4318c8e27dd9":false,
"ad64efe7-9303-454e-935e-2c36c387ec9a":true,
"c0482309-d78b-4f38-a96f-d17166bbf987":"COxxxx-T1",
"fff48e91-f893-4734-95c2-244c33213f16":"2000",
"c3965391-e3ab-47fc-943e-b395a461b2df":"1000",
"25b2bd21-14e2-45be-bd73-48f4115abfba":false,
"1c4bfcda-2852-443c-b34f-105efcc1cfca":"#N/A",
"6f226fe7-930d-43e8-bb43-47181126b2a4":"#N/A",
"4900a482-db44-456d-8155-ccee6149a01d":"#N/A",
"3bc2c306-bd31-4967-b141-8226a813de8b":"20",
"bd44d071-8f5f-49cd-a0a1-02b778210438":"20",
"d4620a17-e114-4a42-9a97-218a90aeb779":"20",
"5101238b-d91f-43cb-805f-459535f48458":"20",
"93e98cee-e881-4089-b66f-c3787219bd65":true,
"2353170d-f0f8-43a0-b31e-729e27c18fbf":"6",
"e82d2367-c160-4c15-a15a-f80249c70604":"10",
"48624593-e37c-40f4-a974-5f8dbf7d360a":true,
"cf8e4d22-592c-43cf-b619-347cb69854e6":false,
"df42bce3-f80a-4b54-9535-259ede175e0b":"4",
"b48ae89f-7233-4f5e-a4e3-7feee9a4f008":"10",
"3df7c117-4540-4fe2-ad3f-b6c19d5c8617":"80",
"ad58caf1-7103-4d4d-bd0b-98c83105ca1c":true,
"9ec4135a-2e49-40da-800c-9de1b0abb584":false,
"92ca4886-08c9-4cb9-b124-aeba6b4e71e6":"4",
"fa7bf63b-4c0d-483b-a1bf-9328f1ada404":"10",
"5ec84f77-1426-40d5-a760-82f5f387815b":"80",
"ca700502-690e-48c4-9837-c7c0bd9d915a":true,
"7259c0c1-fa13-4d84-9f70-2c990c429891":false,
"7b913658-2304-4de6-8699-9d0544e5a8f8":"4",
"39114fdb-8260-435a-abac-edbc4ef044b2":"10",
"2c32b0d4-b00a-4fa8-86ba-dc3cb098da0c":"80",
"2c48160c-0476-4007-8899-19a54d3d5ec8":true,
"78914e49-ab50-4bd0-994d-3b2205c64cca":false,
"b96b16e9-20a2-40c2-bce3-4de937b13f46":"4",
"ed6a7a12-6600-4ca7-a094-0c96c3840d64":"10",
"da69cc14-c127-4e22-a7be-87c4d1121f52":"80",
"75a82f30-fb50-43a7-865a-6546f4bbe621":"50",
"4d307c17-23c6-4c7f-9058-a799781a4c43":true,
"64b31c35-4c4f-45e1-b499-a0b8d31b4723":"50",
"977ec86c-1ccb-4df1-9847-2c968c804a0f":true,
"9351b7f8-ae2d-452d-a838-f161c70b7c3a":"50",
"0c427594-f4be-46a9-8791-e6a7863cb563":true,
"0ff99258-3a73-4086-ba9e-0ce9dc8b2eec":"50",
"f51e9499-bcac-4868-9b77-20bdced1b7af":true
}
}

The parameter edd673eb-65e8-4ffa-ae97-0e625c46e4ad is a choice list

"edd673eb-65e8-4ffa-ae97-0e625c46e4ad":{
"id":"edd673eb-65e8-4ffa-ae97-0e625c46e4ad",
"choices":[
"SPM20028-AGREGA",
"SPM20035-AURELIUS-ROC",
"SPM20033-ATLANTIDE",
"SPM20037-LOVE-TREE",
"SPM20036-BRIGADINE",
"SPM20034-ATLAS-VITAL",
"SPM20040-STRILLER-ZEN",
"SPM20041-TRIVIAL",
"SPM20032-ARTHUS",
"SPM20027-AGOSTINE-MAGMA",
"SPM20000-TOLE-PLEINE",
"SPM20030-ARNEM-CATURA",
"SPM20046-OBEDAI",
"SPM20042-MILLENIUM",
"SPM20024-TOLE-CADE",
"SPM20048-DERKIS",
"SPM20031-BORTH-DACHER",
"SPM20049-CODEX",
"SPM20038-OPERA-PARONS",
"SPM20007-LASCALA",
"SPM20057-GAULOISE",
"SPM20051-LONES",
"SPM20043-ARCHIPEL",
"SPM20063-ARTEFACT",
"SPM20047-OTTO-LEM",
"SPM20044-OPALE-GENIUS"
],
"defval":"0",
"name":"PATTERN",
"type":"StringList",
"visualization":"dropdown",
"group":{
"id":"614af559-d6e9-44cf-888f-2b37cccb4c3a",
"name":"PATTERN_DIMENSIONS_ORIENTATION"
},
"order":1,
"tooltip":"",
"displayname":"",
"hidden":false
},

How can i pass “SPM20036-BRIGADINE” value in the body instead of the ID of the choice ??

For the moment it says “Invalid parameter edd673eb-65e8-4ffa-ae97-0e625c46e4ad: StringList choice not a number”

Thanks
Olivia

It is only possible to pass the index of the value in the choices array. Those indices are preserved from the order of values in the list defined in Grasshopper. The parameter definition gives you the full choices array, therefore an option would be to implement a function mapping strings to an index on your side after loading the parameter definition.