API Reference / Proxies
Create many proxies
Adds many proxies to your workspace's legacy proxy inventory in one call. Each row is processed independently and the response reports per-row success or a typed error, so one bad or duplicate row does not fail the whole batch. A proxy is unique per workspace on its ip and port. A row naming a combination that already exists reports ALREADY_EXISTS instead of creating a duplicate.
/ proxies. v1. Proxies/ BulkCreateProxiesRequest body
application/jsonRequired
Request to create many legacy proxies in one call, up to 10000. Each input succeeds or fails on its own.
proxies?array<BulkCreateProxyInput>The proxies to create, at most 10000. More is rejected with invalid_argument.
Show attributes
ipstringProxy host address. Required.
password?stringPassword for proxy authentication. Write only: stored encrypted and never returned.
port?integerProxy TCP port, from 1 to 65535.
Format"int32"
schemestringProtocol used to connect to the proxy: "http", "https" or "socks5", in any case. Required.
user?stringUsername for proxy authentication. Absent for a proxy without authentication.
Response body
application/json
Success
results?array<BulkCreateProxyResult>The outcome of each input, in request order.
Show attributes
error?BulkCreateProxyErrorWhy the input failed. Set when it failed. Other inputs are unaffected.
Show attributes
code?stringThe kind of failure: a proxy with the same address and port already exists, the input is invalid, or an internal error.
Value in"BULK_"BULK_"BULK_
message?stringHuman-readable detail of the failure.
proxy?ProxyThe created proxy, without its password. Set when the input succeeded.
Show attributes
createdAt?stringWhen the proxy was created.
Format"date-time"
deletedAt?stringWhen the proxy was deleted. Absent while it is live.
Format"date-time"
enabled?booleanTrue when the proxy can be used. Set false by UpdateProxy or automatically when its failure rate is too high.
failureCount?stringNumber of failed requests reported through the proxy over its lifetime. Drives automatic disabling.
Format"int64"
id?stringOpaque 16-byte identifier of the proxy, assigned on creation. Base64-encoded in JSON.
Format"byte" base64
ip?stringProxy host address, an IPv4 or IPv6 address. Unique with port within the workspace.
password?stringPassword for proxy authentication. Write only: accepted when the proxy is created, stored encrypted and never returned.
port?integerProxy TCP port, from 1 to 65535.
Format"int32"
scheme?stringProtocol used to connect to the proxy: "http", "https" or "socks5".
successCount?stringNumber of successful requests reported through the proxy over its lifetime.
Format"int64"
updatedAt?stringWhen the proxy was last changed.
Format"date-time"
user?stringUsername for proxy authentication. Absent for a proxy without authentication.
version?stringEdit counter, incremented by every change a user makes to the proxy.
Format"int64"
workspaceId?stringOpaque 16-byte identifier of the workspace that owns the proxy, base64-encoded in JSON.
Format"byte" base64
application/json
The request was malformed, such as a missing required field or an unparseable cursor. The request cannot be carried out in the current system state.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The request lacks a valid API key in the Authorization header.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The API key is not allowed to perform this action on this workspace.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The request was rate limited. Slow down and retry later.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
An internal server error occurred.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The service is temporarily unavailable. Retry with backoff.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
curl -X POST "https://api.goldmine.to/proxies.v1.Proxies/BulkCreateProxies" \
-H "Authorization: Bearer $CSTRADER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"proxies": [
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080,
"user": "legacyproxyuser",
"password": "s3cr3t-pass"
},
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080
}
]
}'const res = await fetch("https://api.goldmine.to/proxies.v1.Proxies/BulkCreateProxies", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.CSTRADER_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"proxies": [
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080,
"user": "legacyproxyuser",
"password": "s3cr3t-pass"
},
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080
}
]
}),
});
const data = await res.json();body := strings.NewReader(`{
"proxies": [
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080,
"user": "legacyproxyuser",
"password": "s3cr3t-pass"
},
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080
}
]
}`)
req, err := http.NewRequestWithContext(ctx, http.MethodPost, "https://api.goldmine.to/proxies.v1.Proxies/BulkCreateProxies", body)
if err != nil {
return err
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("CSTRADER_API_KEY"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)import os, requests
res = requests.post(
"https://api.goldmine.to/proxies.v1.Proxies/BulkCreateProxies",
headers={"Authorization": f"Bearer {os.environ['CSTRADER_API_KEY']}"},
json={
"proxies": [
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080,
"user": "legacyproxyuser",
"password": "s3cr3t-pass"
},
{
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080
}
]
},
)
data = res.json(){
"results": [
{
"proxy": {
"scheme": "http",
"ip": "203.0.113.10",
"port": 8080,
"user": "legacyproxyuser",
"id": "bGVnYWN5cHJveHkwMDEAAA==",
"workspaceId": "AY+MHnorfD2eTxorPE1ebw==",
"enabled": true,
"version": "1",
"createdAt": "2026-06-29T10:15:00Z",
"updatedAt": "2026-06-29T10:15:00Z"
}
},
{
"error": {
"code": "BULK_CREATE_PROXY_ERROR_CODE_ALREADY_EXISTS",
"message": "proxy already exists"
}
}
]
}{
"code": "failed_precondition",
"message": "The request cannot be carried out in the current system state."
}{
"code": "unauthenticated",
"message": "The request lacks a valid API key in the Authorization header."
}{
"code": "permission_denied",
"message": "The API key is not allowed to perform this action on this workspace."
}{
"code": "resource_exhausted",
"message": "The request was rate limited. Slow down and retry later."
}{
"code": "internal",
"message": "An internal server error occurred."
}{
"code": "unavailable",
"message": "The service is temporarily unavailable. Retry with backoff."
}