curl --request POST \
--url https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "7c1e9a52-3b4d-4f6a-9e8b-2d5c0a1f6b3e",
"proxy_id": "b2f0c3d4-e5a6-4b7c-8d9e-0f1a2b3c4d5e",
"name": "checkout1",
"status": "enabled",
"placement_region": "eu",
"ruleset": {
"network_type": "wifi",
"country": "us",
"region": "california",
"city": null,
"isp": null,
"asn": null,
"zip": null,
"lookalike": false,
"rotation_trigger": "timed:300",
"error_handling": "replace"
},
"exit_ip": "198.51.100.17",
"network_type": "wifi",
"country": "us",
"region": "california",
"city": "los_angeles",
"isp": "charter_communications",
"asn": "20001",
"zip": null,
"bound_since": "2026-10-27T10:21:40Z",
"port": 1337,
"created_at": "2026-10-27T10:15:03Z",
"updated_at": "2026-10-27T10:15:04Z",
"connection_string": {
"uri": "stateful-checkout1:aB3dE5fG7h@proxy.soax.com:1337",
"username": "stateful-checkout1",
"password": "aB3dE5fG7h",
"host": "proxy.soax.com",
"port": 1337
},
"rotation_url": "https://api.platform.soax.com/v1/proxy/packages/b2f0c3d4-e5a6-4b7c-8d9e-0f1a2b3c4d5e/stateful-sessions/7c1e9a52-3b4d-4f6a-9e8b-2d5c0a1f6b3e/rotate?token=Nw3t9Ld6hYc7"
}{
"detail": "Invalid API key"
}{
"detail": "Missing required scope: proxy:packages:write"
}{
"detail": "Session not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Regenerate rotation link
Replace the session’s rotation link (rotation_url). The previous link answers 404 from this moment. Nothing else changes, and the session is not rotated. Returns 404 when rotation links are disabled.
Requires the proxy:packages:write scope.
curl --request POST \
--url https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.platform.soax.com/v1/proxy/packages/{package_id}/stateful-sessions/{session_id}/rotation-url")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "7c1e9a52-3b4d-4f6a-9e8b-2d5c0a1f6b3e",
"proxy_id": "b2f0c3d4-e5a6-4b7c-8d9e-0f1a2b3c4d5e",
"name": "checkout1",
"status": "enabled",
"placement_region": "eu",
"ruleset": {
"network_type": "wifi",
"country": "us",
"region": "california",
"city": null,
"isp": null,
"asn": null,
"zip": null,
"lookalike": false,
"rotation_trigger": "timed:300",
"error_handling": "replace"
},
"exit_ip": "198.51.100.17",
"network_type": "wifi",
"country": "us",
"region": "california",
"city": "los_angeles",
"isp": "charter_communications",
"asn": "20001",
"zip": null,
"bound_since": "2026-10-27T10:21:40Z",
"port": 1337,
"created_at": "2026-10-27T10:15:03Z",
"updated_at": "2026-10-27T10:15:04Z",
"connection_string": {
"uri": "stateful-checkout1:aB3dE5fG7h@proxy.soax.com:1337",
"username": "stateful-checkout1",
"password": "aB3dE5fG7h",
"host": "proxy.soax.com",
"port": 1337
},
"rotation_url": "https://api.platform.soax.com/v1/proxy/packages/b2f0c3d4-e5a6-4b7c-8d9e-0f1a2b3c4d5e/stateful-sessions/7c1e9a52-3b4d-4f6a-9e8b-2d5c0a1f6b3e/rotate?token=Nw3t9Ld6hYc7"
}{
"detail": "Invalid API key"
}{
"detail": "Missing required scope: proxy:packages:write"
}{
"detail": "Session not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
API key secret (starts with s_live_). Create keys in the dashboard under Settings → API keys, or via POST /v1/api-keys/. Send it as Authorization: Bearer <secret>.
Path Parameters
The package's ID. To find it, open the package in Packages and expand the header, or call List packages.
^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$Response
Successful Response
The session's rotation link: open it with a GET to rotate the session, no API key needed. It is a secret, so share it only with the tool that uses it. null when rotation links are disabled. Replace it with Regenerate rotation link.
Was this page helpful?