Skip to content

Commit

Permalink
Added swagger schema
Browse files Browse the repository at this point in the history
  • Loading branch information
mcanu committed Dec 2, 2024
1 parent 53aa73d commit 13ea023
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions label_studio/organizations/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,25 @@ def get_queryset(self):
return org.members.order_by('user__username')


@method_decorator(
name='get',
decorator=swagger_auto_schema(
tags=['Organizations'],
x_fern_sdk_group_name=['organizations', 'members'],
x_fern_sdk_method_name='get',
operation_summary='Get organization member details',
operation_description='Get organization member details by user ID.',
manual_parameters=[
openapi.Parameter(
name='user_pk',
type=openapi.TYPE_INTEGER,
in_=openapi.IN_PATH,
description='A unique integer value identifying the user to get organization details for.',
),
],
responses={200: OrganizationMemberSerializer()},
),
)
@method_decorator(
name='delete',
decorator=swagger_auto_schema(
Expand Down

0 comments on commit 13ea023

Please sign in to comment.