moduleAPImoduleV3classVariables<Grape::APIincludePaginationParamsbefore{authenticate!}before{authorize!:admin_build,user_project}paramsdorequires:id,type: String,desc: 'The ID of a project'end
desc'Delete an existing variable from a project'dosuccess::API::Entities::Variableendparamsdorequires:key,type: String,desc: 'The key of the variable'enddelete':id/variables/:key'dovariable=user_project.variables.find_by(key: params[:key])not_found!('Variable')unlessvariablepresentvariable.destroy,with: ::API::Entities::Variableendendendendend