import request from '@/utils/request'

import axios from 'axios'
export function getSignature() {
    return request({
      url: '/common/getSignature',
      method: 'post',
    })
  }

export function uploadHuaWeiVod(file) {
  const formData = new FormData();
  formData.append('file', file);

  return axios({
    url: '/hwcloud/uploadHuaWeiVod',
    method: 'post',
    data: formData,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  });
}

export function uploadHuaWeiObs(file) {
  const formData = new FormData();
  formData.append('file', file);
  console.log("data",formData)
  return request({
    url: '/hwcloud/uploadHuaWeiObs',
    method: 'post',
    data: formData,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  });
}

export function getTmpSecretKey(type) {
  return request({
    url: '/common/getTmpSecretKey',
    method: 'get',
    params:{
      type:type
    }
  })
}
