Skip to content

Possible statuscodes from the OCS share API #10899

Description

@uncovery

The API lists at URL https://docs.nextcloud.com/server/latest/developer_manual/client_apis/OCS/ocs-share-api.html under "Create a new Share" possible status codes:

100 - successful
400 - unknown share type
403 - public upload was disabled by the admin
404 - file couldn’t be shared

However, when I create a new share on the current stable version 27.0.1 an d create a new share, I get the following XML back after a successful creation, indicating that the statuscode for a successful share creation is 200, not 100.

<?xml version="1.0"?> <ocs> <meta> <status>ok</status> <statuscode>200</statuscode> <message>OK</message> </meta> <data> [...]

Activity

  1. skjnldsv commented on May 14, 2026

    @skjnldsv
    Member

    Still present and confirmed. In developer_manual/client_apis/OCS/ocs-share-api.rst, almost every endpoint lists 100 - successful as the success status code. This is the OCS v1 meta statuscode. When using /ocs/v2.php/ (which is standard now), the success meta statuscode is 200, not 100.

    The doc is also internally inconsistent: the /shares/<share_id>/send-email endpoint already correctly lists 200 - successful (line 219), while all other endpoints still say 100.

    The fix is either a note at the top of the page explaining that OCS v1 returns statuscode 100 and OCS v2 returns 200 for success, or a full pass replacing 100 - successful with 200 - successful across all endpoints in the v2 context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions