import request from '@/utils/request'

const baseurl="http://127.0.0.1:9001"
// 保存脚本
export function save(param, data) {
  return request({
    baseURL: baseurl,
    url: '/script/save',
    method: 'post',
    params: param,
    data: data
  })
}
// 读取脚本
export function read() {
  return request({
    baseURL: baseurl,
    url: '/script/read',
    method: 'get'
  })
}
// 运行脚本
export function run(data) {
  return request({
    baseURL: baseurl,
    url: '/script/run',
    method: 'post',
    data: data
  })
}