HTTP Operation Disable body

Hi All,

I noticed that some attributes that I included in the body does not get updated (only the first attribute gets updated to false) but when I tried to do the same call and body in Postman, everything works fine.

HTTP Operation body:
image

Postman:
image

Has anyone encountered this? If so, how were you able to resolve it?

Thank you!

I think its an issue with attribute mapping and nesting issue.

p_deactivated and p_corporate_user_status has the same level of path notation as p_activate so I think mapping is not the issue since p_activate is working and I just pattern the attribute mapping of that attribute with the other two

@jasmedina Make sure values you are passing are correct, is your p_deactivated attribute expecting a Boolean (what is the target value look like?)

If any of the value in the request body which does not come correct rest of the attribute tends to skip the update (that’s the behavior i observed in past).

Can you share a sample JSON of the user details? Just to check how these attributes are updated.

Regards,
Shekhar Das

Here’s the sample JSON of the user details.

{
    "success": true,
    "data": {
        "_id": "xxx",
        "id": "xxx,
        "app_id": "xxx",
        "atom_dictionary_id": "558b2ee4e9f5fab8c0000002",
        "atom_number": xxxx,
        "status": "Pending",
        "current_step": {
            "id": "xxxx",
            "name": "Phase 1",
            "order": 1,
            "description": "",
            "auto_advance": true,
            "auto_advance_with_one_approval": false,
            "reset_on_rewind": true,
            "deactivate_on_rewind": false,
            "deactivate_on_forward": false,
            "hide_from_picker": false,
            "label": null,
            "created_at": "2015-06-24T22:27:48.712Z",
            "updated_at": "2020-04-02T18:48:56.048Z",
            "deleted_at": null,
            "mongo_id": null,
            "app_id": "xxxx"
        },
        "p_bson_id": "xxxx",
        "name": "[email protected]",
        "p_activate": false,
        "requester_name": "John Smith",
        "requester_email": "[email protected]",
        "p_user_name": "John Smith",
        "p_one_legal_team_name": "Administration",
        "p_region": "Americas",
        "p_country": "United States",
        "p_default_suite_name": "Onit",
        "p_default_navigation_item": "Matter Management Home",
        "p_suite_navigation_items": "{\"Onit\":{\"nav-items\": [\"Matter Management Home\",\"Split3\",\"Matters\",\"Budgets\",\"Tasks\",\"Contacts\",\"Invoices\",\"Split1\",\"Reports Split\",\"Tableau - Matter Suite Template\",\"Tableau - Spend Suite Template\",\"Split2\",\"How-To Documentation\",\"Split4\",\"Logout\"], \"action-items\":[\"Add Matter\",\"Add Matter Status\",\"Matters - Add Accrual Process\",\"Add Contact\",\"Add Task\"]}}",
        "p_group_name": "Standard Users",
        "p_view_admin_workday_info": "No",
        "p_tableau_report_user": "No",
        "p_paralegal": "",
        "p_enable_out_of_office": false,
        "p_out_of_office_selector": "",
        "p_new_ui": true,
        "p_last_login_date": "2022-09-14T00:00:00Z",
        "p_corporate_user_status": "Inactive",
        "p_deactivated": "Yes"
    }
}

@jasmedina based on the user response I can say you are sending correct values.

Also assuming you are sending the request body based on your target API documentation.

Query: are you using patch call to update user object or there is a specific API provided for the disable account?

Regards,
Shekhar Das

Hi Shekhar,

I am using PUT call to update those attributes because there is no specific API endpoint for disabling the accounts. This is based on the API documentation of the application.

Ok got it.

I would try with below looking at user response

{
    "data": {
        "p_activate": false,
        "p_corporate_user_status": "Inactive",
        "p_deactivated": "Yes"
    }
}

Not sure about the API documentation just assuming.

Regards,
Shekhar Das

1 Like

Tried this one and it is still only the p_activate attribute gets updated. Thank you still for giving your insight :slight_smile:

To troubleshoot the issue you can deploy a sample beforeOperation and afterOperation rule to check if the connector is getting the correct request body and processing it at the same time.

BeforeOperation rule just print following:
requestEndPoint

AfterOperation rule print following
requestEndPoint
rawResponseObject
processedResponseObject

totally up to you till you wait for other experts response on this.

Regards,
Shekhar Das

1 Like

Hi @jasmedina,

You may add headers Content-Type:application/json, then try again.

Thank You.

Tried this but didnt work :frowning:

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.