Kaseya Community

editing org custom fields via the API

  • Hi All,

    I have not been able to get this right so far. I'm trying to add a secondary address to my organizations via the API. I see in the sample request model there is  a section for custom fields, but it does not seem to matter what I put there it does not update the field.

    I have tried updating Contact Details 1 as it already exists and creating new ones by providing the new name and values in the API request.

    Has anyone been able to accomplish something like this?

    Regards, 

  • We use this feature all the time to define or obtain customer-specific settings. When I mocked up some code on our dev server to update the org custom field, the BODY looks like this:

    {

     "OrgId": 325325############22448121,

     "Website": "www.mspbuilder.com",

     "NoOfEmployees": 15,

     "ContactInfo": {

     },

     "CustomFields": [

       {

       "FieldName": "Notify",

       "FieldValue": "the guy"

       }

     ],

     "Attributes": {}

    }

    I renamed one of the org custom fields to "Notify", so the above reference is clear. This is usually an email address at the customer that's notified when alerts are processed and sent to the PSA.

    When I'm diagnosing API calls that PUT/POST, I always display the body before passing it to the URL. This helps me to understand where things may have gone wrong. Sometimes its a simple thing, like an extra comma!

    Hope this helps,

    Glenn

  • Hi Glenn

    Thanks for your response it did indeed help me! I have managed to update the custom field I was trying to edit. :)

    Regards,

    Gareth