Are you in the loop? Keep up with the latest by making sure you're subscribed to Community Announcements. Just click Watch and select Articles.

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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

While updating the custom field "errors":{"customfield_10800":"The Team must be a string"}}

I am trying to update custom field but it not changing and throws error 

 

"errors":{"customfield_10800":"The Team must be a string"}}

 

I am updating through python jira api following is the input dict

"customfield_10800": {
"id": "485",
"title": "Facilities IT",
"isShared": True
}
self.jira = self.LogInJira()
issue = self.jira.issue(jiraid)
issue.update(fields=updatedict)

 

2 answers

1 accepted

1 vote
Answer accepted
Sebastian Krzewiński
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Nov 24, 2021

Hi @ssubramani_3pc 

 

Field customfield_10800 is a text field so you should use:

"customfield_10800": "An example text"

 

Regards,

Seba

 

"customfield_10800": "485"

I passed only ID and it worked thank you 

Like # people like this

 

@Sebastian Krzewiński sorry to bother you, but i've the same problem with a custom field type: date time picker.

i'm trying to update the value of the field using python, i've the value that i need to set on a variable

but when i try the update, it fails with:

DEBUG:atlassian.rest_client:HTTP: Response text -> {"errorMessages":[],"errors":{"customfield_10403":"The ST-InProgressTime must be a string"}}

 

i'm passing this:

data["fields"][field_id['ST-InProgressTime']] = {"value": 'First_STInProgressTimeET' }

 

where First_STInProgressTimeET is a variable with the value: 2014-11-21T09:11:00.000+0100

have you some solutions?

Sebastian Krzewiński
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Jan 13, 2022

Hi @Simone Piras 

You need to check type of you field and use correct format. Based on: https://developer.atlassian.com/cloud/jira/service-desk/rest/intro/#fieldformats

Date picker custom field - A custom UI field that enables a date in 'YYYY-MM-DD' format to be picked.

"customfield_11441" : "2015-11-18"

Date time picker custom field - A custom UI field enables a datetime in ISO 8601 ('YYYY-MM-DDThh:mm:ss.sTZD') format to be picked.

"customfield_11442" : "2015-11-18T14:39:00.000+1100"

Hi @Sebastian Krzewiński , yes, the format is correct, my data is: 

2014-11-21T09:11:00.000+0100 and it's correct.

I've also checked that in my script i'm passing a string:

2014-11-21T09:11:00.000+0100 #print of the variable with the data
<class 'str'> #print type of variable

I don't understand.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events