Fail to update user's “Manage Account” permiss

2019-03-04 02:52发布

问题:

We are using DocuSign REST API v2, and we are using the "Modify User Account Settings" method

Endpoint: /accounts/{accountId}/users/{userId}/settings

The JSON we had used in the API is:

{
    "userSettings": [
        {
            "name": "canManageAccount",
            "value": "false"
        },
        {
            "name": "canSendEnvelope",
            "value": "true"
        }
    ]
}

We found that we are able to use the API to enable or disable the "Send Envelopes" permission for a user; but not for the "Manage Account" permission.

Please help troubleshooting the problem.

回答1:

The updating of this setting (canManageAccount) has been broken in REST for awhile now, it works in SOAP though. There is a bug with DocuSign Engineering to address the REST portion, I do not know when it will be fixed and live in Production though.

How to do it in SOAP

SOAP: https://demo.docusign.net/api/3.0/dsapi.asmx

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
 <UpdateMemberSettings xmlns="http://www.docusign.net/API/AccountManagement">
  <AccountId>{accountId}</AccountId>
  <UserId>{userId}</UserId>
  <MemberSettings>
    <CanManageAccount>true</CanManageAccount>
  </MemberSettings>
 </UpdateMemberSettings>
</soap:Body>
</soap:Envelope>


回答2:

Note the User Settings doc permissions comment:

Authorization required for changing the canManageAccount permission: Admin & not setting for self

So I would first check that the API user is itself an Administrator for the account. Check this by using the loginInformation method with login_settings=all

and looking for

....
"loginUserSettings": [
    {
      "name": "canManageAccount",
      "value": "true"
    },

in the response.

Also check that you are not doing a SOBO request for the Modify User Account Settings call.



标签: docusignapi