def preview
      if @step.preview_enabled
        request_headers = PreviewContext.convert_headers request.headers.to_h
        definition = @step.definition_hash

        use_case = ::Riddler::UseCases::PreviewStep.new definition,
          params: params.to_unsafe_h,
          headers: request_headers

        render json: use_case.process
      else
        render json: {status: "disabled"}
      end
    end
def preview
      if @step.preview_enabled
        request_headers = PreviewContext.convert_headers request.headers.to_h
        definition = @step.definition_hash

        use_case = ::Riddler::UseCases::PreviewStep.new definition,
          params: params.to_unsafe_h,
          headers: request_headers

        render json: use_case.process
      else
        render json: {status: "disabled"}
      end
    end
POST /steps/1/preview