Having issue with workflow extension definition update

The old defination is like:

const fieldMetadata = [
 {
 key: 'phoneNumbers',
 label: 'Phone Numbers',
 fieldType: 'TEXTAREA',
 required: true,
 values: [
 {
 allowsMergeTags: true,
 type: 'STATIC_VALUE'
 }
 ]
 },
 {
 key: 'sms',
 label: 'Message',
 fieldType: 'TEXTAREA',
 required: true,
 values: [
 {
 allowsMergeTags: true,
 type: 'STATIC_VALUE'
 }
 ]
 },
 {
 key: 'owner',
 label: 'Owner(Make sure the contact owner already authorized to RingCentral from integration install page)',
 fieldType: 'OWNER',
 required: true,
 values: [
 {
 allowsMergeTags: false,
 type: 'OBJECT_PROPERTY'
 }
 ]
 }
]

Try to add one more key like this:

const fieldMetadata = [
 {
 key: 'phoneNumbers',
 label: 'Phone Numbers',
 fieldType: 'TEXTAREA',
 required: true,
 values: [
 {
 allowsMergeTags: true,
 type: 'STATIC_VALUE'
 }
 ]
 },
 {
 key: 'sms',
 label: 'Message',
 fieldType: 'TEXTAREA',
 required: true,
 values: [
 {
 allowsMergeTags: true,
 type: 'STATIC_VALUE'
 }
 ]
 },
 {
 key: 'logSMS',
 label: 'Log SMS to contact timeline',
 fieldType: 'SELECT',
 required: true,
 values: [
 {
 type: 'STATIC_VALUE',
 allowsMergeTags: false,
 options: [
 {
 text: 'Yes',
 value: 'true'
 },
 {
 text: 'No',
 value: 'false'
 }
 ]
 }
 ]
 },
 {
 key: 'owner',
 label: 'Owner(Make sure the contact owner already authorized to RingCentral from integration install page)',
 fieldType: 'OWNER',
 required: true,
 values: [
 {
 allowsMergeTags: false,
 type: 'OBJECT_PROPERTY'
 }
 ]
 }
]

This will get an error says:

status: 'error',
message: 'There was a problem with the request.',
correlationId: 'c07348ff-8230-4ef4-a059-fb9bf288583b'

However, if I only change some labels of old definition, update request would work, hope someone can help with this.

Thank you.

Hi @DrakeZhao ,
Please use postman for the same and passed the parameters, because when we passed value through postman extension then its updated. Hope this will for you.

Hope this helps!

If we were able to answer your query, kindly help the community by marking it as a solution.
Thanks and Regards.

Thank you for the quick response, I tried in postman, get same error message, another things is as I tested if use same defination to create new extension, it would work.

Hello @DrakeZhao ,
If you set the ‘required’ field to ‘false’ for the new field you are adding to the definition it will work .
The system won’t allow adding new ‘required’ fields to existing workflow definitions because this breaks backwards compatibility. We will update the API documentation to reflect this.
Hope this helps, apologies for any inconvience.

Thank you, this works!