"use strict";
const sheep_request_index = require("../../request/index.js");
const SocialApi = {
  // 获得社交用户
  getSocialUser: (type) => {
    return sheep_request_index.request({
      url: "/member/social-user/get",
      method: "GET",
      params: {
        type
      },
      custom: {
        showLoading: false
      }
    });
  },
  // 社交绑定
  socialBind: (type, code, state) => {
    return sheep_request_index.request({
      url: "/member/social-user/bind",
      method: "POST",
      data: {
        type,
        code,
        state
      },
      custom: {
        custom: {
          showSuccess: true,
          loadingMsg: "绑定中",
          successMsg: "绑定成功"
        }
      }
    });
  },
  // 社交绑定
  socialUnbind: (type, openid) => {
    return sheep_request_index.request({
      url: "/member/social-user/unbind",
      method: "DELETE",
      data: {
        type,
        openid
      },
      custom: {
        showLoading: false,
        loadingMsg: "解除绑定",
        successMsg: "解绑成功"
      }
    });
  }
};
const __vite_glob_0_8 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  default: SocialApi
}, Symbol.toStringTag, { value: "Module" }));
exports.SocialApi = SocialApi;
exports.__vite_glob_0_8 = __vite_glob_0_8;
