Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Get this error "customfield_10008": "The Actual start must be a string"

Choubey, Abhishek January 9, 2022

{
"fields":{
"summary":"None",
"issuetype":{
"id":"10000"
},
"project":{
"key":"CI"
},
"customfield_10007": {
"id":"10007",
"Change reason":"Upgrade"
},
"customfield_10008":{
"id":"10008",

"Actual start":"Jan 05,2022,12:00 AM"
},
"customfield_10009":{
"id":"10009",
"Actual end":"Jan 05, 2022, 12:00 AM"
},

"customfield_10011":{
"id":"10011",
"Epic Name":"CI-1",
},
"description": {
"type": "doc",
"version": 1,
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "description"
}
]
}
]
}
}
}

1 answer

1 accepted

6 votes
Answer accepted
Vishwas
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 9, 2022

Hey @Choubey, Abhishek 

Welcome to Atlassian Community !!

I guess you are trying to set these fields in JSON in automation ?

For date fields we have to pass values in these formats:

Automation_for_jira_Dates_JSON.png

So please check if the field you are mentioning "Actual Start" is Date picker or Date time picker and based on that pass the values.

Regards,

Vishwas

Choubey, Abhishek January 9, 2022

Thanks @Vishwas 

Choubey, Abhishek January 9, 2022

Hi @Vishwas  can you please look into it

Error:-"customfield_10007": "Specify a valid value for 'Change reason'. The allowed values are 10011[Repair], 10012[Upgrade], 10013[Maintenance], 10014[New functionality], 10015[Other], -1"

 

JSON:-

{
"fields":{
"summary":"None",
"issuetype":{
"id":"10000"
},
"project":{
"key":"CI"
},
"customfield_10007": {
"id":"10007",
"Change reason":"Maintenance"

},
"customfield_10008":"2015-11-10",
"customfield_10009":"2019-11-10",

"customfield_10011":"CI-1",
"description": {
"type": "doc",
"version": 1,
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "description"
}
]
}
]
}
}
}

Vishwas
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 9, 2022

Hey @Choubey, Abhishek 

Check this part. I hope customfield_10007 is change reason rite ?

"customfield_10007": {
"id":"10007",
"Change reason":"Maintenance"

}

When you are using id to set values don't provide text part like this : "Change reason":"Maintenance"

Modify the above part like this:

"customfield_10007": {"id":"10011"}

This sets "Change reason" to "Repair"

so you can give appropriate value only ids based on this list: 10011[Repair], 10012[Upgrade], 10013[Maintenance], 10014[New functionality], 10015[Other]

 

Regards,

Vishwas

Choubey, Abhishek January 9, 2022

script running perfectly

Thanks @Vishwas 

Like Vishwas likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events