PageSourceSearch

https://j2proxy.vn/_next/static/chunks/1978.601844a684227141.js

js j2proxy.vn collected 2026-10-02 02:14:42 UTC 66,775 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1978],{1978:(e,t,s)=>{s.r(t),s.d(t,{default:()=>eo});var a=s(95155),l=s(16899),n=s(6912),r=s(9474),i=s(11e3),c=s(96199),o=s(12115),x=s(13406),d=s(18720),m=s(4595),p=s(55635);let h=e=>{navigator.clipboard.writeText(e),d.toast.success("Đ\xe3 copy!")},u=e=>{let{code:t}=e;return(0,a.jsxs)("div",{className:"flex w-full items-start justify-between gap-2 rounded-xl p-3 sm:rounded-2xl sm:p-4",style:{background:"#202B49"},children:[(0,a.jsx)("pre",{className:"flex-1 overflow-x-auto whitespace-pre-wrap break-all font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:t}),(0,a.jsx)("button",{onClick:()=>h(t),className:"shrink-0 transition-opacity hover:opacity-80",children:(0,a.jsx)(m.F.CopyIcon,{className:"h-5 w-5 text-primary sm:h-6 sm:w-6"})})]})},f=e=>{let{title:t}=e;return(0,a.jsxs)("div",{className:"relative flex h-auto min-h-[36px] w-full items-center justify-between rounded-lg px-3 py-2 sm:h-10 sm:min-h-[40px] sm:px-6",style:{background:"#212B46",border:"2px solid transparent",backgroundClip:"padding-box"},children:[(0,a.jsx)("div",{className:"pointer-events-none absolute inset-0 rounded-lg",style:{padding:"1px",background:"linear-gradient(90deg, rgb(from var(--primary) calc(r + 11) calc(g - 105) calc(b - 132)) 0%, rgb(from var(--primary) calc(r + 36) calc(g - 60) calc(b - 45)) 33%, rgb(from var(--primary) calc(r + 19) calc(g - 42) calc(b + 44)) 66%, rgb(from var(--primary) calc(r + 11) calc(g - 105) calc(b - 132)) 100%)",WebkitMask:"linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0)",WebkitMaskComposite:"xor",maskComposite:"exclude"}}),(0,a.jsx)("span",{className:"font-inter text-xs font-semibold leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:t})]})},g=e=>{let{children:t,className:s=""}=e;return(0,a.jsx)("div",{className:"flex w-full flex-col items-start rounded-lg border border-sidebar-foreground px-3 py-3 sm:px-6 sm:py-4 ".concat(s),children:t})},y=e=>{let{name:t,type:s,required:l,description:n}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col gap-2 sm:flex-row sm:flex-wrap sm:items-center sm:justify-between",children:[(0,a.jsxs)("div",{className:"flex flex-wrap items-center gap-1.5 sm:gap-2",children:[(0,a.jsx)("button",{className:"flex h-[30px] items-center justify-center gap-2 rounded-lg px-2.5 py-1.5 font-inter text-sm font-semibold leading-[17px] text-primary sm:h-[35px] sm:px-4 sm:py-2 sm:text-base sm:leading-[19px]",style:{background:"linear-gradient(0deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.3)), #BBFFFF"},children:t}),(0,a.jsx)("button",{className:"flex h-[30px] items-center justify-center gap-2 rounded-lg border border-primary px-2.5 py-1.5 font-inter text-sm font-semibold leading-[17px] text-primary sm:h-[35px] sm:px-4 sm:py-2 sm:text-base sm:leading-[19px]",children:s}),l&&(0,a.jsx)("button",{className:"flex h-[30px] items-center justify-center gap-2 rounded-lg bg-primary px-2.5 py-1.5 font-inter text-sm font-semibold leading-[17px] text-white sm:h-[35px] sm:px-4 sm:py-2 sm:text-base sm:leading-[19px]",children:"required"})]}),(0,a.jsx)("span",{className:"font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:n})]})},j=e=>{let{code:t,hostName:s,children:l}=e,n=(0,p.KB)(s||"",t);return(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(f,{title:"Endpoint",onCopy:()=>h(n)}),(0,a.jsxs)(g,{children:[(0,a.jsxs)("div",{className:"flex w-full items-center justify-between gap-2",children:[(0,a.jsx)("span",{className:"flex-1 break-all font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:n}),(0,a.jsx)("button",{onClick:()=>h(n),className:"shrink-0 transition-opacity hover:opacity-80",children:(0,a.jsx)(m.F.CopyIcon,{className:"h-5 w-5 text-primary sm:h-6 sm:w-6"})})]}),l]})]})},b=e=>{let{children:t}=e;return(0,a.jsx)("div",{className:"w-full border-t border-[#D7D9DF] pt-2",children:(0,a.jsx)("span",{className:"font-inter text-[10px] font-normal leading-[13px] text-[#E67F00] sm:text-xs sm:leading-[15px]",children:t})})},v=e=>{let{code:t,children:s}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(f,{title:"Headers",onCopy:()=>h(t)}),(0,a.jsx)(g,{className:"gap-0",children:(0,a.jsxs)("div",{className:"flex w-full flex-col gap-2",children:[(0,a.jsxs)("div",{className:"flex w-full items-start justify-between gap-2",children:[(0,a.jsx)("span",{className:"flex-1 whitespace-pre-line break-all font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:t}),(0,a.jsx)("button",{onClick:()=>h(t),className:"shrink-0 transition-opacity hover:opacity-80",children:(0,a.jsx)(m.F.CopyIcon,{className:"h-5 w-5 text-primary sm:h-6 sm:w-6"})})]}),s]})})]})},N=e=>{let{children:t,infoNote:s,exampleCode:l}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(f,{title:"Request Body",onCopy:l?()=>h(l):void 0}),(0,a.jsxs)(g,{className:"gap-3 sm:gap-4",children:[t&&(0,a.jsx)("div",{className:"flex w-full flex-col gap-2 sm:gap-3",children:t}),s,l&&(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 py-2 sm:py-4",children:[(0,a.jsx)("span",{className:"font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:"V\xed dụ Request"}),(0,a.jsx)(u,{code:l})]})]})]})},w=e=>{let{title:t="Response th\xe0nh c\xf4ng (200)",exampleCode:s,children:l}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(f,{title:t,onCopy:s?()=>h(s):void 0}),(0,a.jsxs)(g,{children:[l&&(0,a.jsx)("div",{className:"w-full",children:l}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 py-2 sm:py-4",children:[(0,a.jsx)("span",{className:"font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:"V\xed dụ Response"}),(0,a.jsx)(u,{code:s})]})]})]})},k=[{code:"200",label:"OK",description:"Th\xe0nh c\xf4ng",color:"#00FF11"},{code:"201",label:"CREATED",description:"Tạo resource th\xe0nh c\xf4ng",color:"#00FF11"},{code:"401",label:"UNAUTHORIZED",description:"Chưa x\xe1c thực hoặc token kh\xf4ng hợp lệ",color:"#FF1212"},{code:"404",label:"NOT_FOUND",description:"Kh\xf4ng t\xecm thấy resource",color:"#FF1212"},{code:"500",label:"INTERNAL_SERVER_ERROR",description:"Lỗi server nội bộ",color:"#FF1212"},{code:"403",label:"FORBIDDEN",description:"Kh\xf4ng c\xf3 quyền truy cập",color:"#FF1212"},{code:"422",label:"UNPROCESSABLE_ENTITY",description:"Dữ liệu kh\xf4ng hợp lệ",color:"#FF1212"}],T=()=>(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(f,{title:"Tổng hợp Status Code"}),(0,a.jsx)(g,{children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 py-2 sm:py-4",children:[(0,a.jsx)("span",{className:"font-inter text-xs font-normal leading-[15px] text-white sm:text-sm sm:leading-[17px]",children:"C\xe1c m\xe3 trạng th\xe1i HTTP được sử dụng trong API"}),(0,a.jsx)("div",{className:"flex w-full flex-col items-start justify-center gap-4 roun
1ded-lg px-3 py-3 sm:gap-6 sm:rounded-xl sm:px-6 sm:py-5",style:{background:"#202B49"},children:k.map((e,t)=>(0,a.jsxs)("div",{className:"flex w-full flex-col",children:[(0,a.jsxs)("div",{className:"flex flex-col gap-1 sm:hidden",children:[(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:"w-[40px] shrink-0 font-inter text-xs font-semibold leading-[15px]",style:{color:e.color},children:e.code}),(0,a.jsx)("span",{className:"font-inter text-xs font-normal leading-[15px] text-white",children:e.label})]}),(0,a.jsx)("span",{className:"font-inter text-xs font-normal leading-[15px] text-white/70",children:e.description})]}),(0,a.jsxs)("div",{className:"hidden w-full grid-cols-[52px_180px_minmax(0,1fr)] items-center gap-4 sm:grid lg:grid-cols-[60px_220px_minmax(0,1fr)] lg:gap-8",children:[(0,a.jsx)("span",{className:"font-inter text-sm font-semibold leading-[17px] whitespace-nowrap",style:{color:e.color},children:e.code}),(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal whitespace-nowrap text-white",children:e.label}),(0,a.jsx)("span",{className:"font-inter min-w-0 text-sm leading-[17px] font-normal whitespace-nowrap text-white",children:e.description})]}),t<k.length-1&&(0,a.jsx)("div",{className:"mt-4 h-px w-full bg-[#DBDBDC] sm:mt-6"})]},e.code))})]})})]}),I="flex w-full flex-col items-start gap-2 py-6 pl-6 lg:w-[220px] lg:shrink-0 xl:w-[240px]",A="font-inter flex min-h-[33px] w-full items-center justify-start rounded-2xl px-3 py-2.5 text-left text-sm leading-[17px] font-normal whitespace-nowrap text-[#83878F] transition-all data-[state=active]:bg-[#202B49] data-[state=active]:font-semibold data-[state=inactive]:bg-transparent",P="block w-full whitespace-nowrap text-left",C={background:"linear-gradient(\n    268.15deg,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g - 17) calc(b + 0)) 1.4%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 16) calc(b + 0)) 41%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 0) calc(b + 0)) 98.32%\n  )",WebkitBackgroundClip:"text",backgroundClip:"text",WebkitTextFillColor:"transparent"};function _(e){let{hostName:t}=e,[s,l]=(0,o.useState)("recharge-pos"),n=JSON.stringify({amount:1e5},null,2),r=JSON.stringify({code:"TXN20250113001234",accountName:"ACCOUNT NAME",bankCode:"BANK CODE",bankName:"BANK NAME",accountNumber:"0123456789",amount:1e5,qrCode:"QR CODE",status:"PENDING",description:"Nạp tiền v\xe0o t\xe0i khoản - TXN20250113001234",createdAt:"2025-01-13T10:30:00.000Z"},null,2),c=JSON.stringify({id:"550e8400-e29b-41d4-a716-446655440000",coin:"5000000",phone:"0123456789",userName:"john_doe",email:"[email protected]",fullName:"Nguyễn Văn A",merchant:{id:"660e8400-e29b-41d4-a716-446655440000",code:"MERCHANT001",name:"Merchant"},role:{id:"role-id",name:"USER",description:"Người d\xf9ng th\xf4ng thường"},status:{id:"status-id",name:"ACTIVE",description:"T\xe0i khoản đang hoạt động"},createdAt:"2024-01-01T00:00:00.000Z",updatedAt:"2025-01-13T10:30:00.000Z"},null,2);return(0,a.jsx)(i.tU,{value:s,onValueChange:l,className:"flex flex-col gap-6",children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-center rounded-2xl bg-[rgb(from_var(--sidebar)_calc(r_+_14)_calc(g_+_13)_calc(b_+_9))] lg:flex-row lg:items-stretch",children:[(0,a.jsx)("div",{className:I,children:(0,a.jsxs)(x.j7,{className:"flex h-auto w-full flex-col gap-2 bg-transparent",children:[(0,a.jsx)(i.Xi,{value:"recharge-pos",className:A,children:(0,a.jsx)("span",{className:P,style:"recharge-pos"===s?C:void 0,children:"POST Nạp tiền"})}),(0,a.jsx)(i.Xi,{value:"information-account",className:A,children:(0,a.jsx)("span",{className:P,style:"information-account"===s?C:void 0,children:"Th\xf4ng tin nạp tiền"})})]})}),(0,a.jsx)("div",{className:"flex w-full flex-1 flex-col items-center justify-center rounded-2xl p-6",children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-6 rounded-2xl p-4",style:{background:"#151A30"},children:[(0,a.jsxs)(x.av,{value:"recharge-pos",className:"mt-0 flex w-full flex-col gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start justify-center gap-4",children:[(0,a.jsx)("h2",{className:"font-inter w-full text-base leading-[19px] font-bold text-white",children:"API Endpoints"}),(0,a.jsx)("p",{className:"font-inter w-full text-base leading-[19px] font-normal text-white",children:"Tạo giao dịch nạp tiền v\xe0o t\xe0i khoản, trả về th\xf4ng tin chuyển khoản v\xe0 m\xe3 QR"})]}),(0,a.jsx)(j,{code:"/transactions",hostName:t}
1),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>",children:(0,a.jsx)(b,{children:"API n\xe0y chỉ y\xeau cầu Bearer Token từ response API đăng nhập"})}),(0,a.jsx)(N,{exampleCode:n,children:(0,a.jsx)(y,{name:"amount",type:"number",required:!0,description:"Số tiền cần nạp (đơn vị: VNĐ, tối thiểu 10,000)"})}),(0,a.jsx)(w,{exampleCode:r}),(0,a.jsx)(T,{})]}),(0,a.jsxs)(x.av,{value:"information-account",className:"mt-0 flex w-full flex-col gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start justify-center gap-4",children:[(0,a.jsx)("h2",{className:"font-inter w-full text-base leading-[19px] font-bold text-white",children:"API Lấy th\xf4ng tin t\xe0i khoản"}),(0,a.jsx)("p",{className:"font-inter w-full text-base leading-[19px] font-normal text-white",children:"Lấy th\xf4ng tin chi tiết của t\xe0i khoản đang đăng nhập"})]}),(0,a.jsx)(j,{code:"/auth/me",hostName:t}),(0,a.jsx)(v,{code:"Authorization: Bearer <accessToken>",children:(0,a.jsx)(b,{children:"API n\xe0y chỉ y\xeau cầu Bearer Token từ response API đăng nhập"})}),(0,a.jsx)(N,{children:(0,a.jsx)(b,{children:"API n\xe0y kh\xf4ng y\xeau cầu request body"})}),(0,a.jsx)(w,{exampleCode:c}),(0,a.jsx)(T,{})]})]})})]})})}function E(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Lấy danh s\xe1ch sản phẩm Proxy tĩnh"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Lấy danh s\xe1ch tất cả c\xe1c g\xf3i Proxy tĩnh c\xf3 sẵn"})]}),(0,a.jsx)(j,{code:'/products?filters={"category":{"categorytype":{"id":1}}}',hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>\nx-merchant-id: <merchantId>",children:(0,a.jsx)(b,{children:"API n\xe0y y\xeau cầu cả Bearer Token v\xe0 x-merchant-id"})}),(0,a.jsx)(N,{exampleCode:JSON.stringify({amount:1e5},null,2),children:(0,a.jsx)(y,{name:"amount",type:"number",required:!0,description:"Số tiền cần nạp (đơn vị: VNĐ, tối thiểu 10,000)"})}),(0,a.jsx)(w,{exampleCode:JSON.stringify({data:[{id:"550e8400-e29b-41d4-a716-446655440000",name:"Proxy Tĩnh VIETTEL",provider:"VIETTEL",price:5e4,category:{categorytype:{id:1,name:"Proxy Tĩnh"},description:"Proxy tĩnh chất lượng cao"},merchant:{id:"660e8400-e29b-41d4-a716-446655440000",code:"MERCHANT001"},status:{name:"ACTIVE"},imageUrl:"https://example.com/image.jpg"}],total:15,hasNextPage:!1},null,2)}),(0,a.jsx)(T,{})]})}function S(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col gap-4 sm:gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 sm:gap-4",children:[(0,a.jsx)("h2",{className:"text-lg leading-[145%] font-bold text-white sm:text-xl md:text-2xl",children:"API Tạo đơn h\xe0ng Proxy tĩnh"}),(0,a.jsx)("p",{className:"text-sm leading-[130%] font-normal text-white sm:text-base",children:"Tạo đơn h\xe0ng mua Proxy tĩnh mới"})]}),(0,a.jsx)(j,{code:"/orders",hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>"}),(0,a.jsxs)(N,{exampleCode:JSON.stringify({paymentMethod:"WALLET",products:[{dayOfUse:30,password:"mypass123",user:"myuser",protocolType:"HTTP",location:"HCM",provider:"VIETTEL",quantity:5,product:{id:"550e8400-e29b-41d4-a716-446655440000"}}]},null,2),children:[(0,a.jsx)(y,{name:"paymentMethod",type:"string",required:!0,description:'Phương thức thanh to\xe1n (gi\xe1 trị: "WALLET")'}),(0,a.jsx)(y,{name:"products",type:"array",required:!0,description:"Danh s\xe1ch sản phẩm cần mua"}),(0,a.jsx)(y,{name:"products[].dayOfUse",type:"number",required:!0,description:"Số ng\xe0y sử dụng"}),(0,a.jsx)(y,{name:"products[].password",type:"string",required:!0,description:"Mật khẩu proxy mong muốn"}),(0,a.jsx)(y,{name:"products[].user",type:"string",required:!0,description:"Username proxy mong muốn"}),(0,a.jsx)(y,{name:"products[].protocolType",type:"string",required:!0,description:'Loại giao thức: "HTTP" hoặc "SOCKS"'}),(0,a.jsx)(y,{name:"products[].location",type:"string",description:"M\xe3 v\xf9ng: BDG, HCM, HNI (Loại bỏ trường n\xe0y để RANDOM) "}),(0,a.jsx)(y,{name:"products[].provider",type:"string",required:!0,description:"Nh\xe0 mạng: VIETTEL, FPT, VNPT"}),(0,a.jsx)(y,{name:"products[].quantity",type:"number",required:!0,description:"Số lượng proxy muốn mua"}),(0,a.jsx)(y,{name:"products[].product.id",type:"string",required:!0,description:"ID sản phẩm từ API danh s\xe1ch"})]}),(0,a.jsx)(w,{exampleCode:JSON.stringify({orderId:"ORD20250113001234",status:"SUCCESS",amount:25e4,createdAt:"2025-01-13T10:30:00.000Z",products:[{id:"550e8400-e29b-41d4-a716-446655440000",quantity:5,price:5e4}]},null,2)}),(0,a.jsx)(T,{})]})}var O=s(23327);function F(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col gap-4 sm:gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 sm:gap-4",children:[(0,a.jsx)("h2",{className:"text-white text-lg leading-[145%] font-bold sm:text-xl md:text-2xl",children:"API Xem danh s\xe1ch Proxy đ\xe3 mua"}),(0,a.jsx)("p",{className:"text-white text-sm leading-[130%] font-normal sm:text-base",children:"Lấy danh s\xe1ch tất cả Proxy tĩnh đ\xe3 mua"})]}),(0,a.jsx)(j,{code:'/users/proxies?sort=[{"orderBy":"createdAt","order":"desc"}]&filters={"proxy":{"ipaddress":{"categorytype":{"id":1}}}}',hostName:t}),(0,a.jsxs)("div",{className:"flex items-start gap-3 rounded-lg border border-sidebar-foreground  p-3 shadow-sm dark:border-blue-800 dark:from-blue-950/30 dark:to-blue-900/20",children:[(0,a.jsx)(O.A,{className:"text-primary mt-0.5 size-4 shrink-0"}),(0,a.jsxs)("div",{className:"text-sm leading-relaxed text-white",children:[(0,a.jsxs)("p",{className:"mb-2 text-white",children:[(0,a.jsx)("strong",{className:"text-primary dark:text-blue-300",children:"Lọc theo đơn h\xe0ng:"})," ","Nếu muốn lấy danh s\xe1ch proxy theo đơn h\xe0ng vừa tạo, th\xeam parameter sau v\xe0o URL:"]}),(0,a.jsx)("code",{className:"block rounded border border-border-template-6 bg-[#202B49] px-3 py-2 font-mono text-xs dar
1k:border-blue-700 dark:bg-slate-800",children:"&filter=orderId:$eq:string:{orderId}"}),(0,a.jsxs)("p",{className:"mt-2 text-xs text-white dark:text-slate-400",children:["Trong đ\xf3"," ",(0,a.jsx)("code",{className:"rounded bg-[#202B49] px-1 dark:bg-blue-900",children:"{orderId}"})," ","l\xe0 ID đơn h\xe0ng nhận được từ API tạo đơn (v\xed dụ: ORD20250113001234)"]})]})]}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>"}),(0,a.jsx)(w,{exampleCode:JSON.stringify({data:[{id:12345,code:"PROXY-001",protocol:"HTTP",proxy:{ipaddress:{domain:"domain.vn",location:"HCM",provider:"VIETTEL",ip:"123.45.67.89"},username:"myuser",password:"mypass123",port:8080},status:{name:"ACTIVE"},expiredAt:17366976e5}],total:10,hasNextPage:!1},null,2)}),(0,a.jsx)(T,{})]})}function q(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Đổi th\xf4ng tin Proxy"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Thay đổi th\xf4ng tin đăng nhập v\xe0 cấu h\xecnh proxy"})]}),(0,a.jsx)(j,{code:"/orders/change-info-proxies",hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>"}),(0,a.jsxs)(N,{exampleCode:JSON.stringify({userProxyIds:[12345,12346],username:"newuser",password:"newpass456",protocol:"SOCKS"},null,2),children:[(0,a.jsx)(y,{name:"userProxyIds",type:"array<number>",required:!0,description:"Danh s\xe1ch ID proxy cần thay đổi th\xf4ng tin"}),(0,a.jsx)(y,{name:"username",type:"string",required:!0,description:"Username mới cho proxy"}),(0,a.jsx)(y,{name:"password",type:"string",required:!0,description:"Mật khẩu mới cho proxy"}),(0,a.jsx)(y,{name:"protocol",type:"string",required:!0,description:'Giao thức mới: "HTTP" hoặc "SOCKS"'})]}),(0,a.jsx)(w,{exampleCode:JSON.stringify({updated:!0,message:"Đ\xe3 cập nhật th\xf4ng tin proxy th\xe0nh c\xf4ng"},null,2)}),(0,a.jsx)(T,{})]})}function D(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col gap-4 sm:gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 sm:gap-4",children:[(0,a.jsx)("h2",{className:"text-white text-lg leading-[145%] font-bold sm:text-xl md:text-2xl",children:"API Gia hạn Proxy tĩnh"}),(0,a.jsx)("p",{className:"text-white text-sm leading-[130%] font-normal sm:text-base",children:"Gia hạn thời gian sử dụng cho c\xe1c Proxy đ\xe3 mua"})]}),(0,a.jsx)(j,{code:"/orders/renewal-proxies",hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>"}),(0,a.jsxs)(N,{exampleCode:JSON.stringify({userProxyIds:[12345,12346,12347],dayOfRenewal:30,isRenewal:!1,categoryTypeId:1},null,2),children:[(0,a.jsx)(y,{name:"userProxyIds",type:"array<number>",required:!0,description:"Danh s\xe1ch ID proxy cần gia hạn"}),(0,a.jsx)(y,{name:"dayOfRenewal",type:"number",required:!0,description:"Số ng\xe0y muốn gia hạn th\xeam"}),(0,a.jsx)(y,{name:"isRenewal",type:"boolean",required:!0,description:"Lu\xf4n lu\xf4n c\xf3 gi\xe1 trị false"}),(0,a.jsx)(y,{name:"categoryTypeId",type:"number",required:!0,description:"ID loại danh mục (Proxy tĩnh = 1)"})]}),(0,a.jsx)(w,{exampleCode:JSON.stringify({success:!0,message:"Đ\xe3 gia hạn proxy th\xe0nh c\xf4ng"},null,2)}),(0,a.jsx)(T,{})]})}let L={background:"linear-gradient(\n    268.15deg,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g - 17) calc(b + 0)) 1.4%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 16) calc(b + 0)) 41%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 0) calc(b + 0)) 98.32%\n  )",WebkitBackgroundClip:"text",backgroundClip:"text",WebkitTextFillColor:"transparent"};function B(e){let{hostName:t}=e,[s,l]=(0,o.useState)("get-products");return(0,a.jsx)(x.tU,{value:s,onValueChange:l,className:"flex flex-col gap-6",children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-center rounded-2xl bg-[rgb(from_var(--sidebar)_calc(r_+_14)_calc(g_+_13)_calc(b_+_9))] lg:flex-row lg:items-stretch",children:[(0,a.jsx)("div",{className:I,children:(0,a.jsxs)(x.j7,{className:"flex h-auto w-full flex-col gap-2 bg-transparent",children:[(0,a.jsx)(i.Xi,{value:"get-products",className:A,children:(0,a.jsx)("span",{className:P,style:"get-products"===s?L:void 0,children:"GET Danh s\xe1ch sản phẩm"})}),(0,a.jsx)(i.Xi,{value:"create-order",className:A,children:(0,a.jsx)("span",{className:P,style:"create-order"===s?L:void 0,children:"POST Tạo đơn"})}),(0,a.jsx)(i.Xi,{value:"get-list",className:A,children:(0,a.jsx)("span",{className:P,style:"get-list"===s?L:void 0,children:"GET Danh s\xe1ch đ\xe3 mua"})}),(0,a.jsx)(i.Xi,{value:"change-info",className:A,children:(0,a.jsx)("span",{className:P,style:"change-info"===s?L:void 0,children:"POST Đổi th\xf4ng tin"})}),(0,a.jsx)(i.Xi,{value:"renewal",className:A,children:(0,a.jsx)("span",{className:P,style:"renewal"===s?L:void 0,children:"POST Gia hạn"})})]})}),(0,a.jsx)("div",{className:"flex w-full flex-1 flex-col items-center justify-center rounded-2xl p-6",children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-6 rounded-2xl p-4",style:{background:"#151A30"},children:[(0,a.jsx)(x.av,{value:"get-products",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(E,{hostName:t})}),(0,a.jsx)(x.av,{value:"create-order",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(S,{hostName:t})}),(0,a.jsx)(x.av,{value:"get-list",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(F,{hostName:t})}),(0,a.jsx)(x.av,{value:"change-info",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(q,{hostName:t})}),(0,a.jsx)(x.av,{value:"renewal",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(D,{hostName:t})})]})})]})})}function R(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Lấy danh s\xe1ch sản phẩm Proxy xoay"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Lấy danh s\xe1ch tất cả c\xe1c g\xf3i Proxy xoay c\xf3 sẵn"})]}),(0,a.jsx)(j,{code:'/products?filters={"category":{"categorytype":{"id":2}}}',hostName:t}
1),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>\nx-merchant-id: <merchantId>",children:(0,a.jsx)(b,{children:"API n\xe0y y\xeau cầu cả Bearer Token v\xe0 x-merchant-id"})}),(0,a.jsx)(w,{exampleCode:JSON.stringify({data:[{id:"550e8400-e29b-41d4-a716-446655440000",name:"Proxy Xoay VIETTEL",provider:"VIETTEL",price:8e4,category:{categorytype:{id:2,name:"Proxy Xoay"},description:"Proxy xoay chất lượng cao"},merchant:{id:"660e8400-e29b-41d4-a716-446655440000",code:"MERCHANT001"},status:{name:"ACTIVE"},imageUrl:"https://example.com/image.jpg"}],total:15,hasNextPage:!1},null,2)}),(0,a.jsx)(T,{})]})}function M(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex w-full flex-col gap-4 sm:gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 sm:gap-4",children:[(0,a.jsx)("h2",{className:"text-lg leading-[145%] font-bold text-white sm:text-xl md:text-2xl",children:"API Tạo đơn h\xe0ng Proxy xoay"}),(0,a.jsx)("p",{className:"text-sm leading-[130%] font-normal text-white sm:text-base",children:"Tạo đơn h\xe0ng mua Proxy xoay mới"})]}),(0,a.jsx)(j,{code:"/orders",hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>\nx-merchant-id: <merchantId>"}),(0,a.jsxs)(N,{exampleCode:JSON.stringify({paymentMethod:"WALLET",products:[{dayOfUse:30,rotateInterval:5,password:"mypass123",user:"myuser",protocolType:"HTTP",location:"HCM",provider:"VIETTEL",quantity:5,product:{id:"550e8400-e29b-41d4-a716-446655440000"}}]},null,2),children:[(0,a.jsx)(y,{name:"paymentMethod",type:"string",required:!0,description:'Phương thức thanh to\xe1n (gi\xe1 trị: "WALLET")'}),(0,a.jsx)(y,{name:"products",type:"array",required:!0,description:"Danh s\xe1ch sản phẩm cần mua"}),(0,a.jsx)(y,{name:"products[].dayOfUse",type:"number",required:!0,description:"Số ng\xe0y sử dụng"}),(0,a.jsx)(y,{name:"products[].rotateInterval",type:"number",required:!0,description:"0 = kh\xf4ng xoay, 1 = 1 ph\xfat xoay 1 lần, n = n ph\xfat xoay 1 lần"}),(0,a.jsx)(y,{name:"products[].password",type:"string",required:!0,description:"Mật khẩu proxy mong muốn"}),(0,a.jsx)(y,{name:"products[].user",type:"string",required:!0,description:"Username bỏ trống"}),(0,a.jsx)(y,{name:"products[].protocolType",type:"string",required:!0,description:'Loại giao thức: "HTTP" hoặc "SOCKS"'}),(0,a.jsx)(y,{name:"products[].location",type:"string",description:"M\xe3 v\xf9ng: BDG, HCM, HNI (Loại bỏ trường n\xe0y để RANDOM) "}),(0,a.jsx)(y,{name:"products[].provider",type:"string",required:!0,description:"Nh\xe0 mạng: VIETTEL, FPT, VNPT"}),(0,a.jsx)(y,{name:"products[].quantity",type:"number",required:!0,description:"Số lượng proxy muốn mua"}),(0,a.jsx)(y,{name:"products[].product.id",type:"string",required:!0,description:"ID sản phẩm từ API danh s\xe1ch"})]}),(0,a.jsx)(w,{exampleCode:JSON.stringify({orderId:"ORD20250113001234",status:"SUCCESS",amount:4e5,createdAt:"2025-01-13T10:30:00.000Z",products:[{id:"550e8400-e29b-41d4-a716-446655440000",quantity:5,price:8e4}]},null,2)}),(0,a.jsx)(T,{})]})}function X(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Xem danh s\xe1ch Proxy đ\xe3 mua"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Lấy danh s\xe1ch tất cả Proxy xoay đ\xe3 mua"})]}),(0,a.jsx)(j,{code:'/users/proxies?sort=[{"orderBy":"createdAt","order":"desc"}]&filters={"proxy":{"ipaddress":{"categorytype":{"id":2}}}}',hostName:t}),(0,a.jsxs)("div",{className:"flex items-start gap-3 rounded-lg border border-sidebar-foreground p-3 shadow-sm dark:border-blue-800 dark:from-blue-950/30 dark:to-blue-900/20",children:[(0,a.jsx)(O.A,{className:"mt-0.5 size-4 shrink-0 text-primary"}),(0,a.jsxs)("div",{className:"text-sm leading-relaxed text-slate-700",children:[(0,a.jsxs)("p",{className:"mb-2 text-white",children:[(0,a.jsx)("strong",{className:"text-primary dark:text-blue-300",children:"Lọc theo đơn h\xe0ng:"})," ","Nếu muốn lấy danh s\xe1ch proxy theo đơn h\xe0ng vừa tạo, th\xeam parameter sau v\xe0o URL:"]}),(0,a.jsx)("code",{className:"block rounded border border-sidebar-foreground text-white bg-[#202B49] px-3 py-2 font-mono text-xs dar
1k:border-blue-700 dark:bg-slate-800",children:"&filter=orderId:$eq:string:{orderId}"}),(0,a.jsxs)("p",{className:"mt-2 text-xs text-white",children:["Trong đ\xf3"," ",(0,a.jsx)("code",{className:"rounded bg-[#202B49] px-1 dark:bg-blue-900",children:"{orderId}"})," ","l\xe0 ID đơn h\xe0ng nhận được từ API tạo đơn"]})]})]}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>\nx-merchant-id: <merchantId>"}),(0,a.jsx)(w,{exampleCode:JSON.stringify({data:[{id:12345,code:"PROXY-ROTATE-001",protocol:"HTTP",proxy:{ipaddress:{domain:"domain.vn",location:"HCM",provider:"VIETTEL",ip:"123.45.67.89"},username:"myuser",password:"mypass123",port:8080,rotateInterval:5},status:{name:"ACTIVE"},expiredAt:17366976e5}],total:10,hasNextPage:!1},null,2)}),(0,a.jsx)(T,{})]})}function V(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Xoay IP Proxy"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Xoay IP cho proxy đ\xe3 mua"})]}),(0,a.jsx)(j,{code:"/proxies/{id}/rotate",hostName:t,children:(0,a.jsxs)(b,{children:["Lưu \xfd: Thay thế ","{id}"," bằng ID của proxy cần xoay IP (lấy từ API danh s\xe1ch đ\xe3 mua)"]})}),(0,a.jsx)(v,{code:"Authorization: Bearer <accessToken>",children:(0,a.jsx)(b,{children:"API n\xe0y chỉ y\xeau cầu Bearer Token"})}),(0,a.jsxs)(w,{exampleCode:JSON.stringify({status:"success",proxy:"123.45.67.89:4263:elyse45707:ndu3odgwnjy5",ip:"123.45.67.89"},null,2),children:[(0,a.jsx)(y,{name:"status",type:"string",required:!0,description:'Trạng th\xe1i xoay IP (gi\xe1 trị: "success")'}),(0,a.jsx)(y,{name:"proxy",type:"string",required:!0,description:"Th\xf4ng tin proxy đầy đủ (format: ip:port:username:password)"}),(0,a.jsx)(y,{name:"ip",type:"string",required:!0,description:"Địa chỉ IP mới sau khi xoay"})]}),(0,a.jsx)(T,{})]})}function U(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Đổi th\xf4ng tin Proxy"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Thay đổi th\xf4ng tin đăng nhập v\xe0 cấu h\xecnh proxy"})]}),(0,a.jsx)(j,{code:"/orders/change-info-proxies",hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>\nx-merchant-id: <merchantId>"}),(0,a.jsxs)(N,{exampleCode:JSON.stringify({userProxyIds:[12345,12346],password:"newpass456",rotateInterval:10},null,2),children:[(0,a.jsx)(y,{name:"userProxyIds",type:"array<number>",required:!0,description:"Danh s\xe1ch ID proxy cần thay đổi th\xf4ng tin"}),(0,a.jsx)(y,{name:"password",type:"string",required:!0,description:"Mật khẩu mới cho proxy"}),(0,a.jsx)(y,{name:"rotateInterval",type:"number",required:!0,description:"Thời gian xoay IP (t\xednh theo ph\xfat)"})]}),(0,a.jsx)(w,{exampleCode:JSON.stringify({updated:!0,message:"Đ\xe3 cập nhật th\xf4ng tin proxy th\xe0nh c\xf4ng"},null,2)}),(0,a.jsx)(T,{})]})}function z(e){let{hostName:t}=e;return(0,a.jsxs)("div",{className:"flex flex-col gap-4 sm:gap-6 w-full",children:[(0,a.jsxs)("div",{className:"flex flex-col items-start gap-2 sm:gap-4 w-full",children:[(0,a.jsx)("h2",{className:"text-lg sm:text-xl md:text-2xl font-bold leading-[145%] text-white",children:"API Gia hạn Proxy xoay"}),(0,a.jsx)("p",{className:"text-sm sm:text-base font-normal leading-[130%] text-white",children:"Gia hạn thời gian sử dụng cho c\xe1c Proxy đ\xe3 mua"})]}),(0,a.jsx)(j,{code:"/orders/renewal-proxies",hostName:t}),(0,a.jsx)(v,{code:"Content-Type: application/json\nAuthorization: Bearer <accessToken>\nx-merchant-id: <merchantId>"}),(0,a.jsxs)(N,{exampleCode:JSON.stringify({userProxyIds:[12345,12346,12347],dayOfRenewal:30,isRenewal:!1,categoryTypeId:2},null,2),children:[(0,a.jsx)(y,{name:"userProxyIds",type:"array<number>",required:!0,description:"Danh s\xe1ch ID proxy cần gia hạn"}),(0,a.jsx)(y,{name:"dayOfRenewal",type:"number",required:!0,description:"Số ng\xe0y muốn gia hạn th\xeam"}),(0,a.jsx)(y,{name:"isRenewal",type:"boolean",required:!0,description:"Lu\xf4n lu\xf4n c\xf3 gi\xe1 trị false"}),(0,a.jsx)(y,{name:"categoryTypeId",type:"number",required:!0,description:"ID loại danh mục (Proxy xoay = 2)"})]}),(0,a.jsx)(w,{exampleCode:JSON.stringify({success:!0,message:"Đ\xe3 gi
1a hạn proxy th\xe0nh c\xf4ng"},null,2)}),(0,a.jsx)(T,{})]})}let H={background:"linear-gradient(\n    268.15deg,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g - 17) calc(b + 0)) 1.4%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 16) calc(b + 0)) 41%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 0) calc(b + 0)) 98.32%\n  )",WebkitBackgroundClip:"text",backgroundClip:"text",WebkitTextFillColor:"transparent"};function J(e){let{hostName:t}=e,[s,l]=(0,o.useState)("get-products-rotate");return(0,a.jsx)(x.tU,{value:s,onValueChange:l,className:"flex flex-col gap-6",children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-center rounded-2xl bg-[rgb(from_var(--sidebar)_calc(r_+_14)_calc(g_+_13)_calc(b_+_9))] lg:flex-row lg:items-stretch",children:[(0,a.jsx)("div",{className:I,children:(0,a.jsxs)(x.j7,{className:"flex h-auto w-full flex-col gap-2 bg-transparent",children:[(0,a.jsx)(i.Xi,{value:"get-products-rotate",className:A,children:(0,a.jsx)("span",{className:P,style:"get-products-rotate"===s?H:void 0,children:"GET Danh s\xe1ch sản phẩm"})}),(0,a.jsx)(i.Xi,{value:"create-order-rotate",className:A,children:(0,a.jsx)("span",{className:P,style:"create-order-rotate"===s?H:void 0,children:"POST Tạo đơn"})}),(0,a.jsx)(i.Xi,{value:"get-list-rotate",className:A,children:(0,a.jsx)("span",{className:P,style:"get-list-rotate"===s?H:void 0,children:"GET Danh s\xe1ch đ\xe3 mua"})}),(0,a.jsx)(i.Xi,{value:"IP-rotation",className:A,children:(0,a.jsx)("span",{className:P,style:"IP-rotation"===s?H:void 0,children:"GET Xoay IP"})}),(0,a.jsx)(i.Xi,{value:"change-info-rotate",className:A,children:(0,a.jsx)("span",{className:P,style:"change-info-rotate"===s?H:void 0,children:"POST Đổi th\xf4ng tin"})}),(0,a.jsx)(i.Xi,{value:"renewal-rotate",className:A,children:(0,a.jsx)("span",{className:P,style:"renewal-rotate"===s?H:void 0,children:"POST Gia hạn"})})]})}),(0,a.jsx)("div",{className:"flex w-full flex-1 flex-col items-center justify-center rounded-2xl p-6",children:(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-6 rounded-2xl p-4",style:{background:"#151A30"},children:[(0,a.jsx)(x.av,{value:"get-products-rotate",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(R,{hostName:t})}),(0,a.jsx)(x.av,{value:"create-order-rotate",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(M,{hostName:t})}),(0,a.jsx)(x.av,{value:"get-list-rotate",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(X,{hostName:t})}),(0,a.jsx)(x.av,{value:"IP-rotation",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(V,{hostName:t})}),(0,a.jsx)(x.av,{value:"change-info-rotate",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(U,{hostName:t})}),(0,a.jsx)(x.av,{value:"renewal-rotate",className:"mt-0 flex w-full flex-col gap-6",children:(0,a.jsx)(z,{hostName:t})})]})})]})})}let W=e=>{navigator.clipboard.writeText(e),d.toast.success("Đ\xe3 copy!")},K=e=>{let{code:t}=e;return(0,a.jsxs)("div",{className:"flex w-full items-start justify-between gap-2 rounded-2xl p-4",style:{background:"#202B49"},children:[(0,a.jsx)("pre",{className:"font-inter flex-1 text-sm leading-[17px] font-normal whitespace-pre-wrap text-white",children:t}),(0,a.jsx)("button",{onClick:()=>W(t),className:"shrink-0 transition-opacity hover:opacity-80",children:(0,a.jsx)(m.F.CopyIcon,{className:"text-primary h-6 w-6"})})]})},G=e=>{let{title:t}=e;return(0,a.jsxs)("div",{className:"relative flex h-10 w-full items-center justify-between rounded-lg px-6 py-2",style:{background:"#212B46",border:"2px solid transparent",backgroundClip:"padding-box"},children:[(0,a.jsx)("div",{className:"pointer-events-none absolute inset-0 rounded-lg",style:{padding:"1px",background:"linear-gradient(90deg,\n          rgb(from var(--primary) calc(r - 50) calc(g - 50) calc(b - 50)) 0%,\n          rgb(from var(--primary) calc(r - 20) calc(g - 20) calc(b + 20)) 33%,\n          rgb(from var(--primary) r g b) 66%,\n          rgb(from var(--primary) calc(r - 50) calc(g - 50) calc(b - 50)) 100%)",WebkitMask:"linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0)",WebkitMaskComposite:"xor",maskComposite:"exclude"}}),(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-semibold text-white",children:t})]})},Z=e=>{let{children:t,className:s=""}=e;return(0,a.jsx)("div",{className:"border-sidebar-foreground flex w-full flex-col items-start rounded-lg border px-6 py-4 ".concat(s),children:t})},$=e=>{let{step:t}=e;return(0,a.jsx)("div",{className:"flex h-[25px] items-center justify-center gap-2.5 rounded px-1 py-1",style:{background:"linear-gradient(268.15deg, #FF6F00 1.4%, #FF9100 41%, #FF8000 98.32%)"},children:(0,a.jsxs)("span",{className:"font-inter text-sm leading-[17px] font-semibold text-white",children:["Bước ",t]})})},Y=e=>{let{children:t}=e;return(0,a.jsx)("span",{className:"inline-flex items-center justify-center bg-white px-1 py-1",children:(0,a.jsx)("span",{className:'font-["Segoe_UI"] text-[13px] leading-[130%] font-normal text-black',children:t})})};function Q(e){let{hostName:t}=e,s=(0,p.p8)(t||"","/users/rotatev2?token={key}"),l=(0,p.p8)(t||"","/users/rotatev2?token={key}&checkOnly=true"),n=JSON.stringify({success:!0,status:"success",message:"Xoay proxy th\xe0nh c\xf4ng",proxy:"123.45.67.89:8386:myuser:mypass123",location:"HCM",provider:"VIETTEL",lastRotate:"2030-11-10T17:10:31.716Z",timeRemaining:0},null,2),r=JSON.stringify({status:"success",message:"Lấy th\xf4ng tin proxy th\xe0nh c\xf4ng",proxy:"123.45.67.89:8386:myuser:mypass123",location:"HCM",provider:"VIETTEL",lastRotate:"2030-11-10T17:10:31.716Z",timeRemaining:99},null,2);return(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-6",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start justify-center gap-4",children:[(0,a.jsx)("h2",{className:"font-inter w-full text-base leading-[19px] font-bold text-white",children:"C\xe1ch sử dụng Key Xoay"}),(0,a.jsx)("p",{className:"font-inter w-full text-sm leading-[17px] font-normal text-white",children:"Hướng dẫn chi tiết c\xe1ch lấy v\xe0 sử dụng Key Xoay"}),(0,a.jsxs)("div",{className:"flex w-full flex-row items-center gap-2",children:[(0,a.jsx)($,{step:1}),(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal text-white",children:"Lấy 
1Key sau khi mua"})]}),(0,a.jsxs)("div",{className:"flex w-full flex-row items-center gap-2",children:[(0,a.jsx)($,{step:2}),(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal text-white",children:"Gọi API để xoay proxy"})]})]}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(G,{title:"Endpoint để xoay proxy với phương thức GET"}),(0,a.jsxs)(Z,{children:[(0,a.jsxs)("div",{className:"flex w-full items-center justify-between gap-2",children:[(0,a.jsx)("span",{className:"font-inter flex-1 text-sm leading-[17px] font-normal text-white",children:s}),(0,a.jsx)("button",{onClick:()=>W(s),className:"transition-opacity hover:opacity-80",children:(0,a.jsx)(m.F.CopyIcon,{className:"text-primary h-6 w-6"})})]}),(0,a.jsxs)(b,{children:["Lưu \xfd: Thay ","{key}"," bằng key thực tế của bạn"]})]})]}),(0,a.jsx)("h3",{className:"font-inter w-full text-base leading-[19px] font-bold text-white",children:"Xem th\xf4ng tin proxy hiện tại (kh\xf4ng xoay)"}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-center justify-center gap-2.5 px-1",children:[(0,a.jsxs)("div",{className:"flex w-full flex-row flex-wrap items-center gap-2",children:[(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal text-white",children:"Nếu bạn chỉ muốn xem th\xf4ng tin proxy hiện tại m\xe0 kh\xf4ng xoay IP, th\xeam tham số"}),(0,a.jsx)(Y,{children:"checkOnly=true:"})]}),(0,a.jsxs)("div",{className:"flex w-full items-center justify-between gap-2 rounded-lg px-6 py-4",style:{background:"#202B49"},children:[(0,a.jsx)("span",{className:"font-inter flex-1 text-sm leading-[17px] font-normal text-white",children:l}),(0,a.jsx)("button",{onClick:()=>W(l),className:"transition-opacity hover:opacity-80",children:(0,a.jsx)(m.F.CopyIcon,{className:"h-6 w-6 text-white"})})]})]}),(0,a.jsx)("h3",{className:"font-inter w-full text-base leading-[19px] font-bold text-white",children:"Chi tiết API Key Xoay"}),(0,a.jsx)("div",{className:"flex w-full flex-row items-center gap-2",children:(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal text-white",children:"Th\xf4ng tin chi tiết về response trả về khi gọi API Key Xoay"})}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(G,{title:"Response th\xe0nh c\xf4ng (200)"}),(0,a.jsxs)(Z,{children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 py-4",children:[(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal text-white",children:"V\xed dụ Request"}),(0,a.jsx)(K,{code:n})]}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 py-4",children:[(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-normal text-white",children:"V\xed dụ Response khi xem th\xf4ng tin (checkOnly=true)"}),(0,a.jsx)(K,{code:r})]})]})]}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2",children:[(0,a.jsx)(G,{title:"Response th\xe0nh c\xf4ng (200)"}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-2 rounded-lg border border-[#FFC5B9] px-6 py-4",style:{background:"#FFDFD4"},children:[(0,a.jsx)("span",{className:"font-inter text-sm leading-[17px] font-semibold text-[#D40902]",children:"Lưu \xfd quan trọng"}),(0,a.jsx)("span",{className:"font-inter w-full text-sm leading-[17px] font-semibold text-black",children:"Bảo mật Key: Key xoay rất quan trọng, kh\xf4ng chia sẻ key cho người kh\xe1c"}),(0,a.jsx)("span",{className:"font-inter w-full text-sm leading-[17px] font-semibold text-black",children:"Thời gian xoay: Kiểm tra timeRemaining để biết khi n\xe0o c\xf3 thể xoay IP tiếp theo"})]})]}),(0,a.jsx)(T,{})]})}var ee=s(39180);function et(){let{config:e}=(0,ee.r)(),t=null==e?void 0:e.hostName;return(0,a.jsx)("div",{className:"flex w-full flex-1 flex-col gap-6",children:(0,a.jsxs)(x.tU,{defaultValue:"overview",className:"flex w-ful flex-1 gap-6",children:[(0,a.jsx)(x.j7,{className:"!flex h-auto w-full flex-col items-start justify-center gap-4 roun
1ded-2xl bg-[rgb(from_var(--sidebar)_calc(r_+_14)_calc(g_+_13)_calc(b_+_9))] p-4 sm:p-6 lg:h-[83px]",children:(0,a.jsxs)("div",{className:"grid w-full grid-cols-2 gap-2 self-stretch sm:gap-3 lg:flex lg:h-[35px] lg:flex-row lg:items-center lg:justify-between lg:gap-[34px]",children:[(0,a.jsx)(i.Xi,{value:"overview",className:"font-inter flex h-[35px] cursor-pointer items-center justify-center gap-2 rounded-lg bg-transparent px-3 py-2 text-sm leading-[17px] font-semibold text-white transition-all duration-200 hover:opacity-80 data-[state=active]:bg-primary data-[state=active]:text-white data-[state=active]:shadow-none sm:px-4 sm:text-base sm:leading-[19px] lg:flex-1",children:"Tổng quan"}),(0,a.jsx)(i.Xi,{value:"proxy-static",className:"font-inter flex h-[35px] cursor-pointer items-center justify-center gap-2 rounded-lg bg-transparent px-3 py-2 text-sm leading-[17px] font-semibold text-white transition-all duration-200 hover:opacity-80 data-[state=active]:bg-primary data-[state=active]:text-white data-[state=active]:shadow-none sm:px-4 sm:text-base sm:leading-[19px] lg:flex-1",children:"Proxy tĩnh"}),(0,a.jsx)(i.Xi,{value:"proxy-rotating",className:"font-inter flex h-[35px] cursor-pointer items-center justify-center gap-2 rounded-lg bg-transparent px-3 py-2 text-sm leading-[17px] font-semibold text-white transition-all duration-200 hover:opacity-80 data-[state=active]:bg-primary data-[state=active]:text-white data-[state=active]:shadow-none sm:px-4 sm:text-base sm:leading-[19px] lg:flex-1",children:"Proxy xoay"}),(0,a.jsx)(i.Xi,{value:"key-rotating",className:"font-inter flex h-[35px] cursor-pointer items-center justify-center gap-2 rounded-lg bg-transparent px-3 py-2 text-sm leading-[17px] font-semibold text-white transition-all duration-200 hover:opacity-80 data-[state=active]:bg-primary data-[state=active]:text-white data-[state=active]:shadow-none sm:px-4 sm:text-base sm:leading-[19px] lg:flex-1",children:"Key xoay"})]})}),(0,a.jsxs)("div",{className:"flex w-full flex-col",children:[(0,a.jsx)(x.av,{value:"overview",className:"mt-0 w-full",children:(0,a.jsx)(_,{hostName:t})}),(0,a.jsx)(x.av,{value:"proxy-static",className:"mt-0 w-full",children:(0,a.jsx)(B,{hostName:t})}),(0,a.jsx)(x.av,{value:"proxy-rotating",className:"mt-0 w-full",children:(0,a.jsx)(J,{hostName:t})}),(0,a.jsx)(x.av,{value:"key-rotating",className:"mt-0 w-full",children:(0,a.jsx)(Q,{hostName:t})})]})]})})}var es=s(35299),ea=s(5917),el=s(13744);let en={background:"linear-gradient(\n    268.15deg,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g - 17) calc(b + 0)) 1.4%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 16) calc(b + 0)) 41%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 0) calc(b + 0)) 98.32%\n  )"};function er(){let{data:e}=(0,c.wV)(),[t,s]=(0,o.useState)([]),[l,n]=(0,o.useState)(null),[r,i]=(0,o.useState)(!1),[x,p]=(0,o.useState)(!0),[h,u]=(0,o.useState)(!1),[f,g]=(0,o.useState)(!1);(0,o.useEffect)(()=>{(null==e?void 0:e.accessToken)&&y()},[null==e?void 0:e.accessToken]);let y=async()=>{try{p(!0);let t=null==e?void 0:e.accessToken,a=await el.A.fetchApi("/api/v1/users/me/api-tokens",t);s(a);let l=a.find(e=>e.isActive);n(l||null)}catch(e){d.toast.error("Error fetching API tokens")}finally{p(!1)}},j=async()=>{try{i(!0);let a=null==e?void 0:e.accessToken,l=await el.A.fetchApi("/api/v1/users/me/api-tokens/generate",a);n(l),s([...t,l]),d.toast.success("API Token activated successfully!")}catch(e){d.toast.error("Failed to generate API token")}finally{i(!1)}},b=async()=>{if(l)try{i(!0);let a=null==e?void 0:e.accessToken;await el.A.deleteApi("/api/v1/users/me/api-tokens/".concat(l.id),a),n(null),s(t.map(e=>e.id===l.id?{...e,isActive:!1}:e)),d.toast.success("API Token disabled")}catch(e){d.toast.error("Failed to disable API token")}finally{i(!1)}},v=null!==l,N=(e,t)=>{navigator.clipboard.writeText(e),"token"===t?(u(!0),setTimeout(()=>u(!1),2e3)):(g(!0),setTimeout(()=>g(!1),2e3)),d.toast.success("Copied!")};return(0,a.jsxs)("div",{className:"flex w-full flex-col items-center gap-6 rounded-2xl lg:flex-row lg:items-stretch",children:[(0,a.jsxs)("div",{className:"flex h-[280px] w-full flex-col items-start justify-between self-stretch rounded-2xl bg-[rgb(from_var(--sidebar)_calc(r_+_14)_calc(g_+_13)_calc(b_+_9))] px-6 py-5 lg:w-[313px] lg:shrink-0",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-4",children:[(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-3",children:[(0,a.jsx)("h3",{className:"font-inter w-full self
1-stretch text-sm leading-[17px] font-semibold text-white",children:"Phương thức x\xe1c thực API"}),(0,a.jsx)("p",{className:"font-inter w-full self-stretch text-[14px] leading-[17px] font-normal text-white",children:"Nhiều API chỉ y\xeau cầu Bearer Token. Một số API y\xeau cầu x-merchant-id ( sẽ được chỉ định)"})]}),x?(0,a.jsxs)("button",{disabled:!0,className:"font-inter flex h-[35px] w-full items-center justify-center gap-2 self-stretch rounded-full px-4 py-2 text-base leading-[19px] font-semibold text-white",style:en,children:[(0,a.jsx)(es.A,{className:"h-5 w-5 animate-spin"}),"Loading..."]}):v?(0,a.jsx)("button",{onClick:b,disabled:r,className:"font-inter flex h-[35px] w-full items-center justify-center gap-2 self-stretch rounded-full bg-[#C8C9CC] px-4 py-2 text-base leading-[19px] font-semibold text-[#9E9E9F] transition-colors hover:bg-[#9E9E9F] hover:text-white",children:r?"Processing...":"Disable API"}):(0,a.jsx)("button",{onClick:j,disabled:r,className:"font-inter flex h-[35px] w-full cursor-pointer items-center justify-center gap-2 self-stretch rounded-full px-4 py-2 text-base leading-[19px] font-semibold text-white transition-opacity hover:opacity-90",style:en,children:r?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(es.A,{className:"h-5 w-5 animate-spin"}),"Processing..."]}):"Active API"})]}),(0,a.jsxs)("div",{className:"flex w-full flex-col items-start gap-3 self-stretch",children:[(0,a.jsx)("h3",{className:"font-inter w-full self-stretch text-sm leading-[17px] font-semibold text-white",children:"Lưu \xfd quan trọng:"}),(0,a.jsxs)("ul",{className:"font-inter text-sidebar-foreground marker:text-sidebar-foreground flex w-full list-outside list-disc flex-col gap-1 self-stretch pl-5 text-sm leading-[17px] font-normal",children:[(0,a.jsx)("li",{className:"pl-0",children:"Bạn cần k\xedch hoạt API Token để sử dụng c\xe1c API"}),(0,a.jsx)("li",{className:"pl-0",children:"Bạn c\xf3 thể v\xf4 hiệu h\xf3a v\xe0 tạo token mới bất cứ l\xfac n\xe0o"})]})]})]}),(0,a.jsx)("div",{className:"flex h-[280px] w-full flex-1 flex-col items-center justify-center gap-2.5 self-stretch overflow-y-auto rounded-2xl bg-[rgb(from_var(--sidebar)_calc(r_+_14)_calc(g_+_13)_calc(b_+_9))] p-6",children:v?(0,a.jsxs)("div",{className:"flex w-full flex-col gap-6",children:[(0,a.jsxs)("div",{className:"flex flex-col items-center gap-4",children:[(0,a.jsx)("p",{className:"font-inter text-center text-base leading-[19px] font-bold text-white",children:"Th\xf4ng tin x\xe1c thực API"}),(0,a.jsxs)("div",{className:"flex items-center gap-2 rounded-full bg-[#F0FFED] px-3 py-1",children:[(0,a.jsx)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,a.jsx)("path",{d:"M12 22C6.477 22 2 17.523 2 12C2 6.477 6.477 2 12 2C17.523 2 22 6.477 22 12C22 17.523 17.523 22 12 22ZM11.003 16L18.074 8.929L16.659 7.515L11.003 13.172L8.174 10.343L6.76 11.757L11.003 16Z",fill:"#239B00"})}),(0,a.jsx)("span",{className:"font-inter text-sm leading-[19px] font-bold text-[#239B00]",children:"API Token active"})]})]}),(0,a.jsxs)("div",{className:"flex w-full flex-col gap-1",children:[(0,a.jsxs)("div",{className:"flex h-10 items-center justify-between rounded-lg px-4 py-2",style:en,children:[(0,a.jsx)("span",{className:"font-inter text-sm font-semibold text-white uppercase",children:"AUTHORIZATION"}),(0,a.jsx)("button",{onClick:()=>N("Bearer ".concat(l.token),"token"),className:"flex h-8 w-8 items-center justify-center rounded transition-colors hover:bg-white/10",children:h?(0,a.jsx)(ea.A,{className:"h-4 w-4 text-green-400"}):(0,a.jsx)(m.F.CopyIcon,{className:"h-6 w-6 text-white"})})]}),(0,a.jsx)("div",{className:"rounded-lg border border-[#3A3D4E] bg-[#2A2D3E] px-4 py-3",children:(0,a.jsxs)("p",{className:"font-inter text-sm leading-[19px] break-all text-white",children:["Authorization: Bearer ",l.token]})})]}),(0,a.jsxs)("div",{className:"flex w-full flex-col gap-1",children:[(0,a.jsxs)("div",{className:"flex h-10 items-center justify-between rounded-lg px-4 py-2",style:en,children:[(0,a.jsx)("span",{className:"font-inter text-sm font-semibold text-white uppercase",children:"X-MERCHANT-ID"}),(0,a.jsx)("button",{onClick:()=>N(l.merchantId,"merchant"),className:"flex h-8 w-8 items-center justify-center rounded transition-colors hover:bg-white/10",children:f?(0,a.jsx)(ea.A,{className:"h-4 w-4 text-green-400"}):(0,a.jsx)(m.F.CopyIcon,{className:"h-6 w-6 text-white"})})]}),(0,a.jsx)("div",{className:"rounded-lg border border-[#3A3D4E] bg-[#2A2D3E] px-4 py-3",children:(0,a.jsxs)("p",{className:"font-inter text-sm leading-[19px] text-white",children:["x-merchant-id: ",l.merchantId]})})]})]}):(0,a.jsxs)("div",{className:"flex w-full flex-col items-center gap-4 self-stretch",children:[(0,a.jsx)("p",{className:"font-inter w-full self
1-stretch text-center text-base leading-[19px] font-bold text-white",children:"Kh\xf4ng c\xf3 API Token active"}),(0,a.jsxs)("p",{className:"font-inter w-full self-stretch text-center text-base leading-[19px] font-normal text-white",children:["Nhấn ","",(0,a.jsx)("span",{className:"text-[#00FF11]",children:"Active API"})," ","","để tạo token mới"]})]})})]})}let ei={background:"linear-gradient(\n    268.15deg,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g - 17) calc(b + 0)) 1.4%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 16) calc(b + 0)) 41%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 0) calc(b + 0)) 98.32%\n  )",WebkitBackgroundClip:"text",backgroundClip:"text",WebkitTextFillColor:"transparent"},ec={background:"linear-gradient(\n    268.15deg,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g - 17) calc(b + 0)) 1.4%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 16) calc(b + 0)) 41%,\n    rgb(from var(--primary-hover) calc(r + 0) calc(g + 0) calc(b + 0)) 98.32%\n  )"},eo=function(){let{data:e}=(0,c.wV)(),[t,s]=(0,o.useState)(!1),[x,d]=(0,o.useState)("api-authentication");return(0,o.useEffect)(()=>{void 0!==e&&s(!0)},[e]),(0,a.jsx)(l.A,{scrollable:!0,openMarqueeTop:!0,children:(0,a.jsx)(n.A,{isDataReady:t,minLoadingTime:300,children:(0,a.jsxs)("div",{className:"flex w-full max-w-[90vw] flex-col items-start gap-4",children:[(0,a.jsx)(r.D,{title:"T\xe0i liệu API"}),(0,a.jsxs)(i.tU,{value:x,onValueChange:d,className:"w-full gap-6",children:[(0,a.jsxs)(i.j7,{className:"relative flex h-[39px] w-full flex-1 flex-row items-center justify-start gap-6 overflow-visible border-b border-[#D7D9DF] bg-transparent",children:[(0,a.jsxs)(i.Xi,{value:"api-authentication",className:"font-inter relative flex h-[39px] shrink-0 flex-row items-center justify-center gap-2.5 overflow-visible bg-transparent px-2.5 py-2.5 text-base leading-[19px] font-bold text-white transition-all duration-300 hover:!bg-transparent hover:opacity-80 data-[state=active]:text-transparent data-[state=active]:shadow-none",style:"api-authentication"===x?ei:void 0,children:["X\xe1c thực API","api-authentication"===x&&(0,a.jsx)("span",{className:"absolute right-0 bottom-[-1px] left-0 z-10 h-[2px] w-full",style:ec})]}),(0,a.jsxs)(i.Xi,{value:"proxy-center",className:"font-inter relative flex h-[39px] shrink-0 flex-row items-center justify-center gap-2.5 overflow-visible bg-transparent px-2.5 py-2.5 text-base leading-[19px] font-bold text-white transition-all duration-300 hover:!bg-transparent hover:opacity-80 data-[state=active]:text-transparent data-[state=active]:shadow-none",style:"proxy-center"===x?ei:void 0,children:["Trung t\xe2m Proxy","proxy-center"===x&&(0,a.jsx)("span",{className:"absolute right-0 bottom-[-1px] left-0 z-10 h-[2px] w-full",style:ec})]})]}),(0,a.jsx)(i.av,{value:"api-authentication",children:(0,a.jsx)(er,{})}),(0,a.jsx)(i.av,{value:"proxy-center",children:(0,a.jsx)(et,{})})]})]})})})}},6554:(e,t,s)=>{s.d(t,{S:()=>a});let a=(0,s(25959).v)(e=>({pathname:"",isAdminPath:!1,setPathname:t=>e({pathname:t,isAdminPath:t.startsWith("/admin")})}))},6912:(e,t,s)=>{s.d(t,{A:()=>i});var a=s(95155),l=s(12115),n=s(64269);function r(e){let{className:t,isDataReady:s=!1,minLoadingTime:r=1e3}=e,[i,c]=(0,l.useState)(0),[o]=(0,l.useState)(()=>Date.now());(0,l.useEffect)(()=>{let e,t=()=>{let a,l=Date.now()-o;c(a=l>=r&&s?100:l<r?l/r*90:90+5*Math.min((l-r)/5e3,1)),a<100&&(e=requestAnimationFrame(t))};return e=requestAnimationFrame(t),()=>{e&&cancelAnimationFrame(e)}},[s,r,o]);let x=0;x=i<=60?i/60*30:30-(i-60)/40*30;let d=10+90*i/100,m=x,p=Math.max(0,100-x-d);return(0,a.jsxs)("div",{className:(0,n.cn)("flex h-full w-full flex-col items-center justify-center gap-8",t),children:[(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[(0,a.jsxs)("span",{className:"text-lg font-bold text-[#152752]",children:[Math.round(i),"%"]}),(0,a.jsx)("h2",{className:"text-center text-lg font-bold leading-6 tracking-[0%] text-text-normal-template-4",children:"LOADING..."})]}),(0,a.jsxs)("div",{className:"flex w-full max-w-[512px] gap-1",children:[m>0&&(0,a.jsx)("div",{className:"h-2 rounded-full bg-[#8A92A6] transition-all duration-100",style:{width:"".concat(m,"%")}}),d>0&&(0,a.jsx)("div",{className:"h-2 rounded-full bg-[#152752] transition-all duration-100",style:{width:"".concat(d,"%")}}),p>0&&(0,a.jsx)("div",{className:"h-2 rounded-full bg-[#8A92A6] transition-all duration-100",style:{width:"".concat(p,"%")}})]})]})}function i(e){let{children:t,isDataReady:s,minLoadingTime:n=1e3}=e,[i,c]=(0,l.useState)(!1);return((0,l.useEffect)(()=>
1{if(s){let e=setTimeout(()=>{c(!0)},n);return()=>clearTimeout(e)}},[s,n]),i)?(0,a.jsx)(a.Fragment,{children:t}):(0,a.jsx)(r,{isDataReady:s,minLoadingTime:n})}},9474:(e,t,s)=>{s.d(t,{D:()=>l});var a=s(95155);let l=e=>{let{title:t,description:s}=e;return(0,a.jsx)("div",{className:"mx-auto flex w-full items-center justify-between",children:(0,a.jsxs)("div",{children:[(0,a.jsx)("span",{className:"text-center text-[20px] font-bold tracking-tight text-white",children:t}),s&&(0,a.jsx)("p",{className:"text-muted-foreground mt-3 text-sm",children:s})]})})}},11e3:(e,t,s)=>{s.d(t,{Xi:()=>c,av:()=>o,j7:()=>i,tU:()=>r});var a=s(95155);s(12115);var l=s(25667),n=s(64269);function r(e){let{className:t,...s}=e;return(0,a.jsx)(l.bL,{"data-slot":"tabs",className:(0,n.cn)("flex flex-col gap-2",t),...s})}function i(e){let{className:t,...s}=e;return(0,a.jsx)(l.B8,{"data-slot":"tabs-list",className:(0,n.cn)("inline-flex h-9 w-fit items-center justify-center",t),...s})}function c(e){let{className:t,...s}=e;return(0,a.jsx)(l.l9,{"data-slot":"tabs-trigger",className:(0,n.cn)("cursor-pointer hover:bg-sidebar-hover-template-7 inline-flex items-center justify-center gap-1.5 px-2 py-1 text-base font-normal whitespace-nowrap transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",t),...s})}function o(e){let{className:t,...s}=e;return(0,a.jsx)(l.UC,{"data-slot":"tabs-content",className:(0,n.cn)("flex-1 outline-none",t),...s})}},13406:(e,t,s)=>{s.d(t,{Xi:()=>c,av:()=>o,j7:()=>i,tU:()=>r});var a=s(95155);s(12115);var l=s(25667),n=s(64269);function r(e){let{className:t,...s}=e;return(0,a.jsx)(l.bL,{"data-slot":"tabs",className:(0,n.cn)("flex flex-col gap-2",t),...s})}function i(e){let{className:t,...s}=e;return(0,a.jsx)(l.B8,{"data-slot":"tabs-list",className:(0,n.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",t),...s})}function c(e){let{className:t,...s}=e;return(0,a.jsx)(l.l9,{"data-slot":"tabs-trigger",className:(0,n.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",t),...s})}function o(e){let{className:t,...s}=e;return(0,a.jsx)(l.UC,{"data-slot":"tabs-content",className:(0,n.cn)("flex-1 outline-none",t),...s})}},16899:(e,t,s)=>{s.d(t,{A:()=>c});var a=s(95155),l=s(39180),n=s(64269),r=s(6554),i=s(72557);function c(e){var t,s;let{children:c,scrollable:o=!0,className:x="",openMarqueeTop:d=!0}=e,m=(0,l.r)(e=>e.config),p=(0,r.S)(e=>e.isAdminPath),h=null!=(s=null==m||null==(t=m.theme)?void 0:t.textmarquee)?s:"",u=(0,a.jsx)("div",{className:"relative flex h-[33px] min-h-[33px] w-full items-center justify-center overflow-hidden rounded-full py-0",style:{background:"var(--button-gradient-template-7)"},children:(0,a.jsxs)("div",{className:"[container-type:inline-size] relative mx-4 w-full overflow-hidden",children:[(0,a.jsx)("span",{className:"animate-marquee absolute left-full text-sm font-medium whitespace-nowrap text-white sm:text-base",children:h}),(0,a.jsx)("span",{className:"invisible text-base",children:"\xa0"})]})});return(0,a.jsx)(a.Fragment,{children:o?(0,a.jsx)(i.F,{className:(0,n.cn)("z-0 h-[var(--template-7-vh,100%)] min-h-0 w-full bg-[rgb(from_var(--sidebar)_calc(r_+_3)_calc(g_+_3)_calc(b_+_5))]","[&_[data-slot=scroll-area-viewport]>div]:!block [&_[data-slot=scroll-area-viewport]>div]:!w-full [&_[data-slot=scroll-area-viewport]>div]:!max-w-full [&_[data-slot=scroll-area-viewport]>div]:!min-w-0"),children:(0,a.jsx)("div",{className:"flex w-full min-w-0 flex-col justify-between gap-4 p-6",children:(0,a.jsxs)("div",{className:(0,n.cn)("mx-auto flex w-full max-w-[var(--template-7-content-max-width,1136px)] min-w-0 flex-col justify-between gap-4",x),children:[!p&&d&&h&&u,(0,a.jsx)("div",{className:"flex w-full min-w-0 flex-1 flex-col pb-12",children:c})]})})}):(0,a.jsx)("div",{className:"z-0 flex min-h-0 w-full flex-1 bg-[rgb(from_var(--sidebar)_calc(r_+_3)_calc(g_+_3)_calc(b_+_5))]",children:(0,a.jsx)("div",{className:"flex min-h-0 w-full min-w-0 flex-1 flex-col justify-between gap-4 p-6",children:(0,a.jsxs)("div",{className:(0,n.cn)("mx-auto flex min-h-0 w-full max-w-[var(--template-7-content-max-width,1136px)] flex-1 flex-col justify-between gap-4",x),children:[!p&&d&&h&&u,(0,a.jsx)("div",{className:"flex w-full min-w-0 flex-1 flex-col pb-8",children:c})]})})})})}s(12115)},39180:(e,t,s)=>{s.d(t,{r:()=>l});var a=s(68019);let l=(0,s(25959).v)((e,t)=>({config:null,affiliateProgram:null,setConfig:t=>{var s,l;return e({config:{...t,theme:(null==t?void 0:t.theme)?{...t.theme,textmarquee:null!=(l=null!=(s=t.theme.textmarquee)?s:t.theme.textMarquee)?l:"",...t.theme.logo&&{logo:(0,a.V)(t.theme.logo,t.hostName)},...t.theme["logo-l"]&&{"logo-l":(0,a.V)(t.theme["logo-l"],t.hostName)}}:t.theme}})},setAffiliateProgram:t=>e({affiliateProgram:t}),getRotateUrl:()=>{var e,s;return null==(s=t().config)||null==(e=s.theme)?void 0:e.rotateUrl}}))},55635:(e,t,s)=>{s.d(t,{KB:()=>a,T1:()=>r,oX:()=>n,p8:()=>l}),s(53279),s(87358).env.NEXT_PUBLIC_DEMO_MODE;let a=(e,t)=>{if(!e)return"https://api.homeproxy.vn/api/v1".concat(t);let s=e.replace(/^https?:\/\//,"");return"https://".concat(s,"/api/v2").concat(t)},l=(e,t)=>
1{if(!e)return"https://api.homeproxy.vn/api/v3".concat(t);let s=e.replace(/^https?:\/\//,"");return"https://".concat(s,"/api/v3").concat(t)},n=(e,t)=>{let s=a(e,"/products"),l=JSON.stringify({category:{categorytype:{id:t}}});return"".concat(s,"?filters=").concat(l)},r=async()=>{try{let e=await fetch("https://api.ipify.org?format=json",{cache:"no-store"});if(!e.ok)return"N/A";return(await e.json()).ip||"N/A"}catch(e){return"N/A"}}},68019:(e,t,s)=>{s.d(t,{V:()=>a});let a=(e,t)=>{if(!e||"string"!=typeof e)return"";let s=e.trim();if(s.startsWith("https://")||s.startsWith("http://"))return s.replace("/api/v1","");if((e=>e.startsWith("/api/v1/files")||e.startsWith("/files/")||e.includes("/files/"))(s)){let e="https://api.homeproxy.vn".replace(/\/$/,"");if(e){let t=s.startsWith("/")?s:"/".concat(s);return"".concat(e).concat(t).replace("/api/v1","")}}let a=(t||"https://app.homeproxy.vn").trim().replace(/^https?:\/\//,"").replace(/\/$/,"");return a?s.startsWith("/")?"https://".concat(a).concat(s).replace("/api/v1",""):"https://".concat(a,"/").concat(s).replace("/api/v1",""):s}},72557:(e,t,s)=>{s.d(t,{F:()=>i});var a=s(95155),l=s(12115),n=s(83360),r=s(64269);let i=l.forwardRef((e,t)=>{let{className:s,children:l,...i}=e;return(0,a.jsxs)(n.bL,{ref:t,"data-slot":"scroll-area",className:(0,r.cn)("relative overflow-hidden",s),...i,children:[(0,a.jsx)(n.LM,{"data-slot":"scroll-area-viewport",className:(0,r.cn)("h-full w-full rounded-[inherit]",(null==s?void 0:s.includes("!rounded-none"))&&"!rounded-none"),children:l}),(0,a.jsx)(c,{}),(0,a.jsx)(n.OK,{})]})});i.displayName=n.bL.displayName;let c=l.forwardRef((e,t)=>{let{className:s,orientation:l="vertical",...i}=e;return(0,a.jsx)(n.VM,{ref:t,"data-slot":"scroll-area-scrollbar",orientation:l,className:(0,r.cn)("flex touch-none transition-colors select-none","vertical"===l&&"h-full w-2.5 border-l border-l-transparent p-[1px]","horizontal"===l&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",s),...i,children:(0,a.jsx)(n.lr,{"data-slot":"scroll-area-thumb",className:"bg-border relative flex-1 rounded-full"})})});c.displayName=n.VM.displayName}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.