import request from '@/utils/request'

// 查询腾讯云IM群组列表
export function listImGroup(query) {
  return request({
    url: '/service/imGroup/list',
    method: 'get',
    params: query
  })
}

// 查询腾讯云IM群组详细
export function getImGroup(id) {
  return request({
    url: '/service/imGroup/' + id,
    method: 'get'
  })
}

// 新增腾讯云IM群组
export function addImGroup(data) {
  return request({
    url: '/service/imGroup',
    method: 'post',
    data: data
  })
}

// 修改腾讯云IM群组
export function updateImGroup(data) {
  return request({
    url: '/service/imGroup',
    method: 'put',
    data: data
  })
}

// 删除腾讯云IM群组
export function delImGroup(id) {
  return request({
    url: '/service/imGroup/' + id,
    method: 'delete'
  })
}

// 发送群组通知
export function sendGroupNotif(data) {
  return request({
    url: '/service/imGroup/sendGroupNotification',
    method: 'post',
    data: data
  })
}
