Delete custom fields?

https://help.wrike.com/hc/en-us/articles/209603049-Custom-Fields

That link is cool...but we now have too many custom fields which aren't addressed anywhere on the forums. Over time, people have created & customized these areas, but it's too cluttered & we don't need them. I've marked them as "DELETE" but don't have a way to access the "master area" storing all the custom field titles in order to go through & delete them. Please advise. TY!

Julia Marantidi Home Automation Executive Account Manager & System Engineer

96
43 comments
Spot On Innovative Approach Stellar Advice
Avatar

I am having the same problems, there is too many fields that keeps popping up when I'm trying to add a column! Please do something about this as this issue has been raised for 2 years, and there hasn't been a reply yet. 

Please give us the ability to delete custom fields

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Hi everyone! It seems that we have a similar Product Feedback thread on the Community

https://help.wrike.com/hc/en-us/community/posts/360029407073--Status-Investigating-Allow-users-to-delete-custom-fields-without-having-to-contact-tech-support-

This post already has a Product status, and I'll be updating it next month after checking with the Product team. Please upvote it if you haven't already, and sorry for the confusion!  

Lisa Community Team at Wrike Become a Wrike expert with Wrike Discover

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Hello Wrike.  The inability to delete a custom field is frustrating and inefficient.

In the interest of reporting and efficiency, please allow a custom field to be deleted.

1
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar
Hugh

Hi Matt Aldridge, thank you for this feedback! It's been passed on to the Product team.

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

+1

Please implement the possibility to delete custom fields.

Thx

2
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Really need the ability to delete custom fields.

 

Thanks.

1
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar
Hugh

Hi Johannes Zettl and Essam Elbahr,

Thank you for sharing your feedback here. If there are any updates about this, I'll be sure to keep you posted.

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

For those who are able to use the API: With it, it is possible to delete custom fields. It is a bit cumbersome (some extra calls) to find out the ID to use but overall it works. But I do not know if there is a risk of any side-effects doing so. Actually, I do not expect any. But I am just using it in a sandbox system...

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Hi Andreas Wastl,

this is actually the first helpful information in this thread. 😀 Can you please share some technical info to point us in the right direction? 

Wrike Administrator, please advise about possible side effects.

Thank you

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

I looked into my code... Just recognized I use an undocumented API function... So it might not work any more or in the future... Anyhow, below is my Python script. You should run it with Python 3.7 or later. You may of course also just use a command line tool like curl.exe to send API requests... Or use PowerShell even... Python was for me just more convenient... The tool could also take the name of a field from the command line but I obviously did not finish this... Not a big deal to change for a developer.

You need to prepare a permanent access token to the API. Maybe this helps:

https://help.wrike.com/hc/en-us/community/posts/211849065-Get-Started-with-Wrike-s-API 

https://developers.wrike.com/oauth-20-authorization/ (Section: Permanent Access Token)

Good luck!

Here is my code (be aware, the paste here destroyed the indenting which is essential for Python! You need to correct this.):

import requests
import sys
import json
import traceback

permanentAccessToken = "<put in the correct permanent access token>"


# Write API wrapper functions

def loadCustomFields(auth, dump):
url = 'https://www.wrike.com/api/v4/customfields'
rGet = requests.get(url, headers = auth)
print("loadCustomFields: " + str(rGet.status_code))
response = rGet.json()
if (dump):
for field in response["data"]:
print(field)
return response["data"]

def getCustomFieldIdByName(customFields, name):
for field in customFields:
if (field["title"] == name):
print("Found Shared Field by Name: ", name)
return field["id"]
return None

def updateCustomField(auth, customFieldId, update):
url = "https://www.wrike.com/api/v4/customfields/" + customFieldId
rPut = requests.put(url, headers = auth, data = update)
print("updateCustomField: " + str(rPut.status_code))
response = rPut.json()
print(response)

# THIS IS UNDOCUMENTED API CALL BUT IT WORKS!
def deleteCustomField(auth, customFieldId):
url = "https://www.wrike.com/api/v4/customfields/" + customFieldId
rDelete = requests.delete(url, headers = auth)
print("deleteCustomField: " + str(rDelete.status_code))
response = rDelete.json()
print(response)


# The main program section; to be optimized to reduce the needed calls e.g. by use of objects instead of attribute values

if (len(sys.argv) != 1):
print("Call with wrong number of " + str(len(sys.argv)) + " parameter!", file=sys.stderr)
print("Usage: " + sys.argv[0], file=sys.stderr)
exit(-1)

try:
auth = {'Authorization':'Bearer ' + permanentAccessToken}
customFields = loadCustomFields(auth, True) # print them True/False
customFieldId = getCustomFieldIdByName(customFields, "Innternational Birth Date")
deleteCustomField(auth, customFieldId)
#updateCustomField(auth, customFieldId, {"title":"API-Custom-Field1"})

except:
print("Call to Python program failed! EXCEPTION occured.")
traceback.print_exc()

print("Done.")

 

 

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Johannes Zettl

If you can tell a way how to reach you, we may also get in contact directly.

0
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Andreas Wastl,

sure, that would be great. Would you mind taking a look at our website https://www.code-deck.io/ . You will find all contact info there.

Thanks
Johannes

1
Comment actions Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Andreas Wastl,

thanks for the code and your instructions. I did not see that comment yesterday. But this will actually be really helpful and I guess, you saved me a lot of time.

I hope I will find some time on the weekend to give it a shot. Will provide feedback here afterwards.

Best
Johannes

1
Comment actions Permalink

Folllowing List for Post: Delete custom fields?
[this list is visible for admins and agents only]

Didn’t find what you were looking for? Write new post