Proxy presets are named, reusable snapshots of the Advanced Proxy Setup form. Each preset stores a data object with two sub-objects — form (connection, session, protocol and output settings) and location (country/region/city/ISP targeting) — so you can save a configuration once and reapply it later. Presets are scoped to the authenticated user, and each preset name must be unique within that account.
All Proxy Presets endpoints return the standard resource envelope: { "success", "payload", "errors", "description" }. On success payload holds the preset (or an array of presets); on failure success is false, errors holds the validation or error messages, and description is a human-readable summary.
A preset id is a UUID string (e.g. 3f0c8b1e-...), not an integer. There is no "get single preset" endpoint — GET /proxy-presets/{id} is not implemented. Use List Proxy Presets and match on id client-side.
The data object
Both create and update accept a data object. It must contain a form array and a location array, and every key listed below must be present — the service validates for the presence of each key and silently drops any key that is not on the allowed list. Values are stored verbatim; they are the same values the Advanced Setup form produces.
data.form keys
data.form
Name
Type
Required
Description
connectionType
string
Required
Exit pool type, e.g. "residential" or "mobile".
sessionType
string
Required
Session behaviour, e.g. "sticky" (pinned IP) or "rotating" (new IP per request).
sessionDuration
number
Required
Sticky-session duration as shown in the UI (e.g. minutes).
sessionDurationSec
number
Required
Sticky-session duration expressed in seconds.
protocol
string
Required
Connection protocol, e.g. "http" or "socks5".
outputFormat
string
Required
Credential output template, e.g. "host:port:user:pass".
template
string
Required
Selected output template identifier.
customTemplate
string
Required
Custom template string (empty string when a built-in template is used).
count
number
Required
Number of proxy lines to generate.
host
string
Required
Gateway host the generated proxies point at.
port
number
Required
Gateway port.
aiFilter
string
Required
AI quality/speed filter: "filter-high", "filter-medium", "filter-high-speed-fast", "filter-medium-speed-fast", or "none" to opt out.
data.location keys
data.location
Name
Type
Required
Description
country
string
Required
ISO country code (lowercased) or "any".
region
string
Required
State/region slug, or "any".
city
string
Required
City slug, or "any".
isp
string
Required
ISP slug, or "any".
zipcode
string
Required
ZIP/postal code, or empty string.
List Proxy Presets
GET/v1/proxy-presetsRequires Auth
List Proxy Presets
List Proxy Presets
Retrieve all proxy presets belonging to the authenticated user, ordered by creation date (newest first).
req, _ := http.NewRequest("GET", "https://api.proxyhat.com/v1/proxy-presets", nil)
req.Header.Set("Authorization", "Bearer __API_KEY__")
req.Header.Set("Accept", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil {
log.Fatal(err)
}
defer resp.Body.Close()
var result struct {
Payload []map[string]interface{} `json:"payload"`
}
json.NewDecoder(resp.Body).Decode(&result)
for _, p := range result.Payload {
fmt.Println(p["id"], p["name"])
}
Create Proxy Preset
POST/v1/proxy-presetsRequires Auth
Create Proxy Preset
Create Proxy Preset
Create a new preset for the authenticated user. Returns 201 with the created preset. The name must be unique within your account — a duplicate name returns 422 with errors.name.
Example request:namedata.form.connectionTypedata.location.country
Request Body
Name
Type
Required
Description
name
string
Required
Preset name. Max 100 characters, unique per user.
data
object
Required
Preset payload. Must contain form and location objects.
data.form
object
Required
Connection/session/output settings. See data.form keys above.
Update a preset by its UUID, taken from the URL path. Both name and data are optional, but if you send data it must include both data.form and data.location. Returns the updated preset.
Example request:name
Path Parameters
Name
Type
Required
Description
id
string (UUID)
Required
The UUID of the preset to update.
Request Body
Name
Type
Required
Description
name
string
Optional
New preset name. Max 100 characters, unique per user.
data
object
Optional
New preset payload. When present, data.form and data.location are both required.
data.form
object
Optional
Required when data is supplied. See data.form keys above.
data.location
object
Optional
Required when data is supplied. See data.location keys above.