리셀러 API
고객용 프록시를 프로그래밍으로 배분 — 서브계정 생성, 대역폭 배분, 자격 증명 발급, 사용량 조회.
이 페이지에서
리셀러 API
개요
이용 방법. 리셀러 API는 계정 활성화 후 사용할 수 있습니다. 이후 API 키를 만들어 아래 엔드포인트를 호출하세요.
- 대역폭 풀
- 선불 잔액입니다. 서브계정에 배분하면 차감되고, 회수하면 되돌아옵니다.
- 서브계정
- 고객 각각은 고유의 대역폭·자격 증명·사용량을 가진 서브계정입니다.
https://socksnode.com/api/v1/reseller상품
세 가지 상품을 판매할 수 있습니다. 각각 별도의 풀, 도매가, 서브 계정별 잔액이 있어 한 상품의 GB가 다른 상품으로 소진되지 않습니다. allocate, proxies, usage, locations에서 product 필드로 선택하세요.
| product | 상품 | 타기팅 | Sticky IP |
|---|---|---|---|
| residential | 로테이팅 레지덴셜 | 국가, 주, 도시, ASN | 1–1440 min |
| datacenter | 로테이팅 데이터센터 | 국가, 도시, ASN | 1–1440 min |
| mobile_rotating | 로테이팅 모바일 (4G/5G 통신사 IP) | 국가; 주·도시·ASN은 트래픽 2배 | 1–120 min |
product를 생략하면 모든 호출은 이전과 똑같이 레지덴셜로 처리됩니다. 데이터센터와 로테이팅 모바일은 계정에서 활성화되면 사용할 수 있으며, 그 전에는 403 product_not_enabled를 반환합니다.
# Allocate 10 GB of DATACENTER to a sub-account
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/allocate" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{"gb": 10, "product": "datacenter"}'
# Generate a ROTATING MOBILE proxy for it
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/proxies" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{"product": "mobile_rotating", "country": "us",
"protocol": "http", "sessionMode": "rotating"}'
# No "product" = residential, exactly as beforePools
주거용 대역폭은 세 풀 모두에서 같은 가격으로 사용할 수 있습니다. POST /proxies에 pool을 보내 풀을 선택하고, 생략하면 이전과 같이 Pool 1입니다. Mix는 mixPools의 풀들에 요청을 균등하게 나눕니다. 타깃을 처리할 수 없는 풀은 빠지고, 한 풀만 처리할 수 있는 타깃은 Pool 1에서 실행됩니다. 각 줄의 pool, mixPools, poolNote가 실제로 어디서 실행되는지 알려 줍니다.
| pool | 타깃팅 | Sticky | |
|---|---|---|---|
| 1 | Pool 1 | 국가, 주, 도시, ISP(ASN)를 자유롭게 조합 | 1–1440 min |
| 2 | Pool 2 | 국가, 그다음 주, 도시, ISP 중 하나 | 1–60 min |
| 3 | Pool 3 | 국가, 주, 도시; ISP 불가 | 1–1440 min |
| mix | Mix | Pool 1의 위치; Mix의 각 풀이 가능한 만큼 처리 | Pools 1 + 3 포함 시 1–1440분(60분 초과 시 Pool 2 제외), 그 외 1–60분 |
Pool 2와 Pool 3의 위치: GET /locations?pool=2(또는 3). 이름과 코드 모두 됩니다: "Los Angeles", "losangeles", "los_angeles"는 같은 도시입니다.
# Pool 3, Los Angeles, the same IP for 30 minutes
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/proxies" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{"pool": "3", "protocol": "http", "country": "us",
"state": "california", "city": "losangeles",
"sessionMode": "sticky", "stickyDurationMinutes": 30}'
# A Mix of all three pools, a new IP on every request
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/proxies" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{"pool": "mix", "mixPools": "123", "protocol": "http",
"country": "gb", "sessionMode": "rotating", "count": 5}'
# Pool 2's own states, cities and ISPs in one country
curl "https://socksnode.com/api/v1/reseller/locations/GB?pool=2" \
-H "Authorization: Bearer sk_live_xxx"인증
모든 요청은 API 키를 Bearer 토큰으로 인증합니다. 풀에서 대역폭을 배분할 수 있으므로 비밀로 유지하세요.
속도 제한: 키당 분당 120개 요청 (프록시 생성은 추가로 제한됩니다). 키는 비밀로 유지하고 서버 측에 보관하세요.
GET /api/v1/reseller/pool HTTP/1.1
Host: socksnode.com
Authorization: Bearer sk_live_xxx오류
오류는 해당 HTTP 상태와 함께 JSON 본문 { "error": { "code", "message" } }을 반환합니다:
| 상태 | 의미 |
|---|---|
| 400 | 잘못된 요청 본문 또는 매개변수 |
| 401 | 누락되거나 잘못되었거나 취소된 API 키 |
| 402 | 프록시를 생성하기에 대역폭 잔액이 부족함 |
| 403 | API 키에 필요한 범위가 없음 |
| 404 | 찾을 수 없거나 본인 소유가 아닙니다. |
| 422 | 하위 계정 한도에 도달했습니다. |
| 429 | 속도 제한 초과 — Retry-After 헤더 참조 |
| 503 | 제품 점검 중입니다. 잠시 후 다시 시도하세요. |
HTTP/1.1 402 Payment Required
Content-Type: application/json
{
"error": {
"code": "insufficient_pool",
"message": "…"
}
}세션 ID 셀프 생성
각 자격 증명의 username은 단순한 토큰 문자열이며, password는 서브계정이 존재하는 동안 그대로 유지됩니다. 한 번 발급받으면 원하는 만큼 rotating 또는 sticky 세션을 로컬에서 직접 조합할 수 있습니다 — 추가 API 호출도, 요청당 20개 제한도 없습니다.
이렇게 만든 세션은 개별 자격 증명으로 추적되지 않습니다 — 서브계정의 프록시 목록에 나타나지 않고 개별적으로 폐기할 수도 없습니다. 대역폭은 여전히 할당량에 맞게 정확히 제한되며, 합계 사용량은 usage 엔드포인트에서 계속 확인할 수 있습니다.
# Base credential, from any POST …/proxies call
username: acme-country-us
password: 3f9c2a1b-7e4d-4a2c-9f1a-8b6c5d4e3f2a
# Rotating: no session token, a fresh IP every request
acme-country-us
# Sticky: append your own session id + lifetime (1-1440 minutes).
# Build as many as you want locally, no API call needed:
acme-country-us-session-req0001-lifetime-30
acme-country-us-session-req0002-lifetime-30
acme-country-us-session-req0003-lifetime-30
# State and city targeting work the same way (see /locations):
acme-country-us-state-california-session-req0004-lifetime-30게이트웨이에 자체 브랜드 입히기
프록시가 저희 도메인이 아닌 고객님 자체 도메인을 거치도록 설정합니다. gatewayId는 진입 리전(fr/us/sg)을 선택하는 값으로 — exit 국가에는 영향을 주지 않으며, exit 국가는 country 필드로 별도 설정합니다.
| Region | gatewayId | CNAME target |
|---|---|---|
| Nearest (default) | auto | global.socksnode.com |
| France | fr | fr.socksnode.com |
| United States | us | us.socksnode.com |
| Singapore | sg | sg.socksnode.com |
- 1
Add a DNS record.
For each region you want branded, create a
CNAMEfrom your own subdomain (e.g.us.yourbrand.com) to that region's target above. Only set up the regions you'll use; anything left blank falls back to your default host. If your DNS provider can't do a CNAME there, use anArecord and ask us for the current IPs. A CNAME follows automatically if they change; an A record won't. - 2
Wait for DNS to propagate.
Usually a few minutes, sometimes a few hours, depending on your provider and TTL.
- 3
Set it in your dashboard.
Go to Reseller → White-label gateway. With more than one region you'll see a field per region plus a Default field. Enter the domain you set up and save.
- 4
Verify.
Generate a test proxy for that region, check that the
hostin the response is your domain, then connect through it once.
gatewayId picks your customer's entry point, not their exit country; the exit country is the country field. A DNS lookup on your CNAME still shows it resolves to socksnode.com. To hide that from your own customers, run your own relay (nginx or HAProxy stream) in front instead of a plain CNAME, and ask us if you need help.
; One CNAME per region you brand
proxy.yourbrand.com. CNAME global.socksnode.com.
fr.yourbrand.com. CNAME fr.socksnode.com.
us.yourbrand.com. CNAME us.socksnode.com.
sg.yourbrand.com. CNAME sg.socksnode.com.엔드포인트
대역폭 풀 잔액을 조회합니다
GET/pool
범위: reseller:read
파라미터 없음.
curl "https://socksnode.com/api/v1/reseller/pool" \
-H "Authorization: Bearer sk_live_xxx"{
"poolGb": 812.5,
"allocatedGb": 187.5,
"subAccounts": 42,
"products": {
"residential": { "poolGb": 812.5, "allocatedGb": 187.5, "ratePerGb": 0.54, "pricing": "wholesale" },
"datacenter": { "poolGb": 300, "allocatedGb": 23.2, "ratePerGb": null, "pricing": "site" }
}
}고객용 서브계정을 생성합니다
POST/subaccounts
범위: reseller:manage
본문 파라미터
labelstring선택 사항이 고객에게 붙이는 이름, 최대 80자.
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"label": "customer-acme"
}'{
"id": "sub_9f2a…",
"label": "customer-acme",
"balanceGb": 0,
"usedGb": 0,
"status": "active",
"createdAt": "2026-09-30T08:12:44.000Z",
"products": {
"residential": { "balanceGb": 8.4, "usedGb": 1.6 },
"datacenter": { "balanceGb": 20, "usedGb": 3.2 },
"mobile_rotating": { "balanceGb": 0, "usedGb": 0 }
}
}잔액과 사용량과 함께 서브계정을 나열합니다
GET/subaccounts
범위: reseller:read
파라미터 없음.
curl "https://socksnode.com/api/v1/reseller/subaccounts" \
-H "Authorization: Bearer sk_live_xxx"{
"data": [
{
"id": "sub_9f2a…",
"label": "customer-acme",
"balanceGb": 8.4,
"usedGb": 1.6,
"status": "active",
"createdAt": "2026-09-30T08:12:44.000Z",
"products": {
"residential": { "balanceGb": 8.4, "usedGb": 1.6 },
"datacenter": { "balanceGb": 20, "usedGb": 3.2 },
"mobile_rotating": { "balanceGb": 0, "usedGb": 0 }
}
}
]
}하위 계정 하나 조회
GET/subaccounts/{id}
범위: reseller:read
경로 파라미터
idstring필수하위 계정 id.
curl "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID" \
-H "Authorization: Bearer sk_live_xxx"{
"id": "sub_9f2a…",
"label": "customer-acme",
"balanceGb": 8.4,
"usedGb": 1.6,
"status": "active",
"createdAt": "2026-09-30T08:12:44.000Z",
"products": {
"residential": { "balanceGb": 8.4, "usedGb": 1.6 },
"datacenter": { "balanceGb": 20, "usedGb": 3.2 },
"mobile_rotating": { "balanceGb": 0, "usedGb": 0 }
}
}하위 계정 이름 변경 또는 재활성화
PATCH/subaccounts/{id}
범위: reseller:manage
경로 파라미터
idstring필수하위 계정 id.
본문 파라미터
labelstring | null선택 사항이 고객에게 붙이는 이름, 최대 80자.
reactivateboolean선택 사항true면 하위 계정의 프록시를 다시 활성화합니다. 대역폭은 복원되지 않습니다.
curl -X PATCH "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"label": "customer-acme-eu"
}'{
"id": "sub_9f2a…",
"label": "customer-acme-eu",
"balanceGb": 8.4,
"usedGb": 1.6,
"status": "active",
"createdAt": "2026-09-30T08:12:44.000Z",
"products": {
"residential": { "balanceGb": 8.4, "usedGb": 1.6 },
"datacenter": { "balanceGb": 20, "usedGb": 3.2 },
"mobile_rotating": { "balanceGb": 0, "usedGb": 0 }
}
}풀에서 서브계정으로 대역폭을 배분합니다
POST/subaccounts/{id}/allocate
음수 gb를 보내면 다시 회수됩니다.
범위: reseller:manage
경로 파라미터
idstring필수하위 계정 id.
본문 파라미터
gbnumber필수풀에서 옮길 GB. 음수면 하위 계정 잔액 한도 내에서 GB를 되돌립니다.
productstring선택 사항상품: residential(기본), datacenter 또는 mobile_rotating. 각각 별도의 풀, 도매가, 서브 계정 잔액이 있으며 계정에서 활성화되면 사용할 수 있습니다.
residentialdatacentermobile_rotating기본값:residential
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/allocate" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"gb": 10,
"product": "datacenter"
}'{
"id": "sub_9f2a…",
"product": "datacenter",
"balanceGb": 10,
"poolGb": 290
}
// With a negative gb:
// { "id": "sub_9f2a…", "product": "datacenter", "reclaimedGb": 4, "balanceGb": 6, "poolGb": 294 }서브계정의 프록시 자격 증명을 발급합니다
POST/subaccounts/{id}/proxies
rotating(요청마다 새 IP) 또는 sticky(stickyDurationMinutes로 1–1440분 동안 동일 IP 유지).
범위: reseller:manage
경로 파라미터
idstring필수하위 계정 id.
본문 파라미터
productstring선택 사항상품: residential(기본), datacenter 또는 mobile_rotating. 각각 별도의 풀, 도매가, 서브 계정 잔액이 있으며 계정에서 활성화되면 사용할 수 있습니다. mobile_rotating은 국가 타기팅이 기본이며, 주·도시·ASN 타기팅은 트래픽이 2배로 계산되고 sticky IP는 최대 120분 유지됩니다.
residentialdatacentermobile_rotating기본값:residentialprotocolstring필수자격 증명의 프로토콜.
httpsocks5countrystring필수두 글자 국가 코드, 또는 전 세계는 ANY.
statestring선택 사항미국 주, 공백 없는 전체 이름, 예: california.
citystring선택 사항공백 없는 도시 이름, 예: losangeles. asn이 있으면 무시됩니다.
asninteger선택 사항ISP 네트워크 번호, 예: Comcast는 7922.
sessionModestring필수rotating은 요청마다 새 IP, sticky는 stickyDurationMinutes 동안 같은 IP.
rotatingstickystickyDurationMinutesinteger선택 사항sticky IP 유지 시간, 1–1440분. sessionMode가 sticky일 때 필수.
countinteger선택 사항생성할 자격 증명 수, 1–20.
기본값:
1labelstring선택 사항직접 붙이는 이름, 최대 80자. count가 1보다 크면 각각 #n이 붙습니다.
gatewayIdstring선택 사항진입 지역: fr, us, sg. 반환할 화이트라벨 호스트를 정합니다.
frussgpoolstring선택 사항주거용 풀: 1(기본값), 2, 3 또는 mix. Pools 참조.
123mix기본값:1mixPoolsstring선택 사항pool이 mix일 때: 사용할 풀, 12, 13, 23 또는 123(기본값 123).
121323123기본값:123strictboolean선택 사항true: 지정한 주, 도시 또는 ISP만; false: 빈 IP가 없으면 국가 전체로 대체. 기본값은 Pool 1에서 true, Mix에서 false이며 strict Mix는 Pool 1에서 실행됩니다.
curl -X POST "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/proxies" \
-H "Authorization: Bearer sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"country": "us",
"protocol": "http",
"sessionMode": "rotating",
"gatewayId": "us"
}'{
"data": [
{
"id": "clx…",
"host": "gw.your-brand.com",
"port": 9000,
"username": "acme-country-us",
"password": "…",
"protocol": "http",
"country": "us",
"state": null,
"city": null,
"sessionMode": "rotating",
"stickyDurationMinutes": null,
"label": "customer-acme",
"product": "residential",
"pool": "1",
"mixPools": null,
"poolNote": null
}
]
}하위 계정의 프록시 자격 증명 목록, 비밀번호 포함
GET/subaccounts/{id}/proxies
범위: reseller:read
경로 파라미터
idstring필수하위 계정 id.
curl "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/proxies" \
-H "Authorization: Bearer sk_live_xxx"{
"data": [
{
"id": "clx…",
"host": "gw.your-brand.com",
"port": 9000,
"username": "acme-country-us",
"password": "…",
"protocol": "http",
"country": "us",
"state": null,
"city": null,
"sessionMode": "rotating",
"stickyDurationMinutes": null,
"label": "customer-acme",
"status": "active",
"createdAt": "2026-09-30T08:12:44.000Z",
"lastUsedAt": null,
"product": "residential",
"pool": "1",
"mixPools": null,
"poolNote": null
}
]
}기간별 서브계정 사용량을 조회합니다
GET/subaccounts/{id}/usage
범위: reseller:read
경로 파라미터
idstring필수하위 계정 id.
쿼리 파라미터
rangestring선택 사항기간. 알 수 없는 값은 24h로 처리됩니다.
1h24h7d30d90dtodaymonth12mall기본값:24hproductstring선택 사항상품: residential(기본), datacenter 또는 mobile_rotating. 각각 별도의 풀, 도매가, 서브 계정 잔액이 있으며 계정에서 활성화되면 사용할 수 있습니다.
residentialdatacentermobile_rotating기본값:residential
curl "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID/usage?range=30d" \
-H "Authorization: Bearer sk_live_xxx"{
"product": "residential",
"range": "30d",
"totalGb": 6.8,
"totalRequests": 91240,
"successRate": 98.7,
"series": [{ "period": "2026-09-01", "gb": 0.4 }],
"requestSeries": [ … ]
}서브계정을 비활성화하고 남은 대역폭을 회수합니다
DELETE/subaccounts/{id}
범위: reseller:manage
경로 파라미터
idstring필수하위 계정 id.
curl -X DELETE "https://socksnode.com/api/v1/reseller/subaccounts/SUB_ID" \
-H "Authorization: Bearer sk_live_xxx"{
"id": "sub_9f2a…",
"status": "deactivated",
"reclaimedGb": 8.4,
"reclaimed": { "residential": 8.4, "datacenter": 20, "mobile_rotating": 0 }
}타겟팅 가능한 모든 국가를 나열합니다
GET/locations
범위: reseller:read
쿼리 파라미터
productstring선택 사항상품: residential(기본), datacenter 또는 mobile_rotating. 각각 별도의 풀, 도매가, 서브 계정 잔액이 있으며 계정에서 활성화되면 사용할 수 있습니다.
residentialdatacentermobile_rotating기본값:residentialpoolstring선택 사항위치를 나열할 주거용 풀: 1(기본값), 2 또는 3. Mix는 Pool 1의 목록을 사용합니다.
123기본값:1
curl "https://socksnode.com/api/v1/reseller/locations" \
-H "Authorization: Bearer sk_live_xxx"{
"product": "residential",
"data": [
{ "code": "US", "name": "United States" },
{ "code": "GB", "name": "United Kingdom" }
]
}한 국가의 주/도시/ISP-ASN 정보를 조회합니다
GET/locations/{country}
범위: reseller:read
경로 파라미터
countrystring필수두 글자 국가 코드.
쿼리 파라미터
productstring선택 사항상품: residential(기본), datacenter 또는 mobile_rotating. 각각 별도의 풀, 도매가, 서브 계정 잔액이 있으며 계정에서 활성화되면 사용할 수 있습니다.
residentialdatacentermobile_rotating기본값:residentialpoolstring선택 사항위치를 나열할 주거용 풀: 1(기본값), 2 또는 3. Mix는 Pool 1의 목록을 사용합니다.
123기본값:1
curl "https://socksnode.com/api/v1/reseller/locations/US" \
-H "Authorization: Bearer sk_live_xxx"{
"product": "residential",
"data": {
"states": [
{
"code": "california",
"name": "California",
"cities": [{ "code": "losangeles", "name": "Los Angeles" }]
}
],
"asns": [{ "code": "7922", "name": "Comcast Cable Communications, LLC" }]
}
}