Opportunity - Update with API

Do you want to: Suggest a feature / Report a bug / Ask a how-to question
For feature suggestions, describe the result you would like to achieve in detail: N/A
For bug reports, provide the steps to reproduce and if possible a minimal demo of the problem:

When running the “Update an opportunity” using the PUT API I am getting a 400 error. WIth the message being “Value does not fall within the expected range.”. I am using Postman and sending the data in the body as a JSON object. It looks as follows:

{
    "responsibleid": "GUID of user",
    "accessList": [
        "GUID of user"
    ]
}

Here is the error message from postman:

{
    "status": 1,
    "statusCode": 400,
    "error": {
        "message": "Value does not fall within the expected range.",
        "hresult": -2147024809,
        "data": {}
    }
}

Community Server/Control Panel version: 12.6.0.21
Type of installation of Workspace (docker, deb/rpm, exe, please point us to the installation guide that you used as well): N/A
OS: N/A
Browser version: N/A
Additional information: This is for our cloud based onlyoffice portal.
Any relevant details about the situation. If you’ve modified configuration files or are using a proxy server that might affect the situation, please mention it. You can also attach images and videofile to the post (or to place them to external storage)

Hello @aloreaux :handshake:

We need some time to reproduce this issue. If we find any information, solutions, or have additional questions regarding this problem, we will notify you.

Thank you.

Hi is there any update on this?

Hello @aloreaux :wave:

First of all, I sincerely apologize for losing track of your task—it was not intentional. I also realized that I might not fully understand what exactly you’re trying to achieve.

Could you please provide more details about your request? Specifically, it would be helpful if you could clarify:

  • What exactly you would like to update?
  • Any specific details or scenarios related to the task?

Additionally, I wanted to suggest a potential improvement for your request. Have you considered adding the "isPrivate": true or "isPrivate": false field to your request body? This might be useful if the opportunity needs specific privacy settings. For example:

{
    "responsibleid": "GUID of user",
    "isPrivate": true,
    "accessList": [
        "GUID of user"
    ]

}

This could address some of the issues related to visibility or data restrictions.

Lastly, could you let me know which API documentation you’ve been using as a reference? It would help ensure we’re aligned and looking at the same guidelines.

Hi @Nikolas ,

I am using this documentation: OnlyOffice API Docs

An issue we run into is if someone leaves our company there is not a bulk way to update the companies, opportunities and persons so that a new person can have access to them.

So I was trying to write a little script that can take a list of opportunities by id and add the new user to the access list.

Thanks!

Hello @aloreaux

I believe it is possible to achieve with following APIs: