For context, I’m trying to implement a searchable custom field in Jira. My understanding is that I need to update the custom field value via the API to achieve this. My code snippet is as follows:
Unfortunately, when trying to use the example code provided I receive an error that "Custom field with id 'customfield_10100' doesn't exist." This is despite being able to verify that the custom field definitely exists in my test instance according to the /field API, as follows:
I tried replicating this behavior by creating a read-only jira:customField of type object, but my calls to PUT /rest/api/3/app/field/${context.extensionContext.fieldId}/value were successful (HTTP 204). In order to have more context, can you share your manifest, specifically the jira:customField module?
The only thing I updated from your snippet is let value = "foo" since you are assigning a string where a JSON object is expected (with the assumption that your customfield’s data type is object based on the results of your GET /rest/api/2/field) but this should be a different error (HTTP 400) and not the one you are getting.
FYI I’m also unable to install Forge apps on my test instance at the moment, even blank ‘hello world’ ones. The error message I’m getting is as follows:
This is interesting, @BradQ, as I cannot replicate the issue. I created a new app from scratch, copied the scopes you provided for consistency, and was able to install it on my instance; the PUT /rest/api/3/app/field/${context.extensionContext.fieldId}/value call was also successful.
Based on the error you shared (with the assumption that these logs came from forge install --verbose), it might be an instance related issue. If Forge app installation continues to fail on your instance, feel free to raise this issue in Developer Support Service Desk.
Also, I edited your previous message to remove cloudId since I noticed that you also removed information like hostname and such.