diff --git a/arkindex/process/api.py b/arkindex/process/api.py index f5da3b0ef4467db6b00b3825c247dabe418d824c..e26d73bb2443712224b52f394e963c2d8c3aa06c 100644 --- a/arkindex/process/api.py +++ b/arkindex/process/api.py @@ -1752,8 +1752,17 @@ class CreateProcessTemplate(ProcessACLMixin, WorkerACLMixin, CreateAPIView): @extend_schema_view(post=extend_schema( operation_id='ApplyProcessTemplate', + parameters=[ + OpenApiParameter( + 'id', + type=UUID, + location=OpenApiParameter.PATH, + description='ID of the template to apply', + required=True, + ), + ], responses={200: ProcessSerializer, 403: None}, - tags=['process'] + tags=['process'], )) class ApplyProcessTemplate(ProcessACLMixin, WorkerACLMixin, CreateAPIView): """ diff --git a/arkindex/process/serializers/imports.py b/arkindex/process/serializers/imports.py index ecfb9fc8a6e02c7bb0a83bc8998f15248d29fc8d..552942a1fe7b820eba210c8c309df60a598a9807 100644 --- a/arkindex/process/serializers/imports.py +++ b/arkindex/process/serializers/imports.py @@ -286,7 +286,12 @@ class CreateProcessTemplateSerializer(serializers.ModelSerializer): class ApplyProcessTemplateSerializer(ProcessACLMixin, serializers.Serializer): - process_id = serializers.PrimaryKeyRelatedField(queryset=Process.objects.all(), source='process', required=True) + process_id = serializers.PrimaryKeyRelatedField( + queryset=Process.objects.all(), + source='process', + required=True, + help_text='ID of the process to apply the template to', + ) def create(self, validated_data): # The endpoint should copy all the worker runs content from the source template