How to get the value of a jira custom field using rest api and curl

How do I get the value of a custom_field using curl? I have this command

curl -u [username]:[password] --request GET --url "https://jira/rest/api/2/issue/PCD-12345?expand=editmeta&fields=customfield_18420&value

Which returns

{“expand”:“renderedFields,names,schema,operations,editmeta,changelog,versionedRepresentations”,“id”:“752543”,“self”:“https://jira/rest/api/2/issue/752543",“key”:“PCD-10573”,“fields”:{“customfield_18420”:{“self”:“https://jira/rest/api/2/customFieldOption/21761”,“value”:“Yes”,“id”:“21761”}},“editmeta”:{“fields”:{“customfield_18420”:{“required”:false,“schema”:{“type”:“option”,“custom”:“com.atlassian.jira.plugin.system.customfieldtypes:select”,“customId”:18420},“name”:"Substantial Update?”,“fieldId”:“customfield_18420”,“operations”:[“set”],“allowedValues”:[{“self”:“https://jira/rest/api/2/customFieldOption/21760",“value”:“No”,“id”:“21760”},{“self”:“https://jira/rest/api/2/customFieldOption/21761”,“value”:“Yes”,“id”:"21761”}]}}}}

However, I just want to get the actual value of the custom field as it appears in jira, which is “value”:“Yes”

However, I just want to get the actual value of the custom field as it appears in jira,

You asked the endpoint to tell you the value the user has chosen for the field in the issue (Yes), but you added expand=editmeta, so you asked it to also include the field values that are available to the user (No / Yes).

The endpoint is just returning exactly what you asked it for.

PS. There is no such parameter called value, so the endpoint just ignored that part of your request.