Changeset - 88b9cc4ba52f
[Not reviewed]
default
0 1 0
Rasmus Selsmark - 11 years ago 2014-08-21 23:05:23
rasmuss@unity3d.com
Corrected method names in documentation, to match API
1 file changed with 25 insertions and 25 deletions:
0 comments (0 inline, 0 general)
docs/api/api.rst
Show inline comments
 
@@ -219,25 +219,25 @@ OUTPUT::
 
                 "locked_by": "<username>",
 
                 "msg": "User `<username>` set lock state for repo `<reponame>` to `<false|true>`"
 
             }
 
    error :  null
 

	
 

	
 
show_ip
 
-------
 
get_ip
 
------
 

	
 
Shows IP address as seen from Kallithea server, together with all
 
defined IP addresses for given user.
 
This command can be executed only using api_key belonging to user with admin
 
rights.
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "show_ip"
 
    method :  "get_ip"
 
    args :    {
 
                "userid" : "<user_id or username>",
 
              }
 

	
 
OUTPUT::
 

	
 
@@ -454,26 +454,26 @@ OUTPUT::
 
              "msg" : "deleted user ID:<userid> <username>",
 
              "user": null
 
            }
 
    error:  null
 

	
 

	
 
get_users_group
 
---------------
 
get_user_group
 
--------------
 

	
 
Gets an existing user group. This command can be executed only using api_key
 
belonging to user with admin rights.
 

	
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "get_users_group"
 
    method :  "get_user_group"
 
    args :    {
 
                "usersgroupid" : "<user group id or name>"
 
                "usergroupid" : "<user group id or name>"
 
              }
 

	
 
OUTPUT::
 

	
 
    id : <id_given_in_input>
 
    result : None if group not exist
 
@@ -498,24 +498,24 @@ OUTPUT::
 
 
                            ]
 
             }
 
    error : null
 

	
 

	
 
get_users_groups
 
----------------
 
get_user_groups
 
---------------
 

	
 
Lists all existing user groups. This command can be executed only using
 
api_key belonging to user with admin rights.
 

	
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "get_users_groups"
 
    method :  "get_user_groups"
 
    args :    { }
 

	
 
OUTPUT::
 

	
 
    id : <id_given_in_input>
 
    result : [
 
@@ -526,24 +526,24 @@ OUTPUT::
 
               },
 
 
              ]
 
    error : null
 

	
 

	
 
create_users_group
 
------------------
 
create_user_group
 
-----------------
 

	
 
Creates new user group. This command can be executed only using api_key
 
belonging to user with admin rights
 

	
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "create_users_group"
 
    method :  "create_user_group"
 
    args:     {
 
                "group_name": "<groupname>",
 
                "owner" :     "<onwer_name_or_id = Optional(=apiuser)>",
 
                "active":     "<bool> = Optional(True)"
 
              }
 

	
 
@@ -558,25 +558,25 @@ OUTPUT::
 
                     "active":          "<bool>",
 
               },
 
            }
 
    error:  null
 

	
 

	
 
add_user_to_users_group
 
-----------------------
 
add_user_to_user_group
 
----------------------
 

	
 
Adds a user to a user group. If user exists in that group success will be
 
`false`. This command can be executed only using api_key
 
belonging to user with admin rights
 

	
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "add_user_users_group"
 
    method :  "add_user_user_group"
 
    args:     {
 
                "usersgroupid" : "<user group id or name>",
 
                "userid" : "<user_id or username>",
 
              }
 

	
 
OUTPUT::
 
@@ -587,25 +587,25 @@ OUTPUT::
 
              "msg": "added member `<username>` to user group `<groupname>` |
 
                      User is already in that group"
 
            }
 
    error:  null
 

	
 

	
 
remove_user_from_users_group
 
----------------------------
 
remove_user_from_user_group
 
---------------------------
 

	
 
Removes a user from a user group. If user is not in given group success will
 
be `false`. This command can be executed only
 
using api_key belonging to user with admin rights
 

	
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "remove_user_from_users_group"
 
    method :  "remove_user_from_user_group"
 
    args:     {
 
                "usersgroupid" : "<user group id or name>",
 
                "userid" : "<user_id or username>",
 
              }
 

	
 
OUTPUT::
 
@@ -954,25 +954,25 @@ OUTPUT::
 
              "msg" : "Revoked perm for user: `<username>` in repo: `<reponame>`",
 
              "success": true
 
            }
 
    error:  null
 

	
 

	
 
grant_users_group_permission
 
----------------------------
 
grant_user_group_permission
 
---------------------------
 

	
 
Grant permission for user group on given repository, or update
 
existing one if found. This command can be executed only using
 
api_key belonging to user with admin rights.
 

	
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method :  "grant_users_group_permission"
 
    method :  "grant_user_group_permission"
 
    args:     {
 
                "repoid" : "<reponame or repo_id>"
 
                "usersgroupid" : "<user group id or name>"
 
                "perm" : "(repository.(none|read|write|admin))",
 
              }
 

	
 
@@ -983,23 +983,23 @@ OUTPUT::
 
              "msg" : "Granted perm: `<perm>` for group: `<usersgroupname>` in repo: `<reponame>`",
 
              "success": true
 
            }
 
    error:  null
 

	
 

	
 
revoke_users_group_permission
 
-----------------------------
 
revoke_user_group_permission
 
----------------------------
 

	
 
Revoke permission for user group on given repository.This command can be
 
executed only using api_key belonging to user with admin rights.
 

	
 
INPUT::
 

	
 
    id : <id_for_response>
 
    api_key : "<api_key>"
 
    method  : "revoke_users_group_permission"
 
    method  : "revoke_user_group_permission"
 
    args:     {
 
                "repoid" : "<reponame or repo_id>"
 
                "usersgroupid" : "<user group id or name>"
 
              }
 

	
 
OUTPUT::
0 comments (0 inline, 0 general)