Add documentation for all path parameters
This commit is contained in:
parent
02d3b70013
commit
53fb7f4136
19 changed files with 107 additions and 19 deletions
|
@ -1,7 +1,7 @@
|
|||
from flask import request
|
||||
|
||||
from endpoints.api import (resource, nickname, ApiResource, validate_json_request, request_error,
|
||||
log_action, Unauthorized, NotFound, internal_only)
|
||||
log_action, Unauthorized, NotFound, internal_only, path_param)
|
||||
from auth.permissions import AdministerOrganizationPermission
|
||||
from auth.auth_context import get_authenticated_user
|
||||
from data import model
|
||||
|
@ -54,6 +54,7 @@ def log_prototype_action(action_kind, orgname, prototype, **kwargs):
|
|||
|
||||
|
||||
@resource('/v1/organization/<orgname>/prototypes')
|
||||
@path_param('orgname', 'The name of the organization')
|
||||
@internal_only
|
||||
class PermissionPrototypeList(ApiResource):
|
||||
""" Resource for listing and creating permission prototypes. """
|
||||
|
@ -179,6 +180,8 @@ class PermissionPrototypeList(ApiResource):
|
|||
|
||||
|
||||
@resource('/v1/organization/<orgname>/prototypes/<prototypeid>')
|
||||
@path_param('orgname', 'The name of the organization')
|
||||
@path_param('prototypeid', 'The ID of the prototype')
|
||||
@internal_only
|
||||
class PermissionPrototype(ApiResource):
|
||||
""" Resource for managingin individual permission prototypes. """
|
||||
|
|
Reference in a new issue