Below are a few important points on how to create a profile via API and an example of a request to create it ⬇️.
Important ☝🏻
The User-agent
parameter can only be in manual
mode(manually)
Both WebGL
info
and User-agent
can only be retrieved by querying in advance, here is information on how to do it:
User agent 🌐
The user agent itself can be obtained for the desired platform (operating system) profile by making a GET request to:
At the end of the &platform=
address, you can specify the desired platform from the following options: macOS, Windows, Linux. User agent issuance is available only if the Authorization header with the value Bearer *API key*
is specified .
WEBGLinfo 👾
The values for the required platform (operating system) of the profile can be obtained by making a GET request to
Also at the end of the &platform=
address you can specify the required platform from the following options: MacOS, Windows, Linux. User agent issuance is available only if you specify Authorization header with the value Bearer *API key*
Example of working code for creating a profile 🛠️
This code is written in Python. It sends a POST request to the API to create a browser profile with the specified settings.
import requests
import json
url = "https://dolphin-anty-api.com/browser_profiles"
payload = json.dumps({"name":"Test","tags":["Test"],"platform":"macos","browserType":"anty","mainWebsite":"","useragent":{"mode":"manual","value":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"},"webrtc":{"mode":"altered","ipAddress":null},"canvas":{"mode":"real"},"webgl":{"mode":"real"},"webglInfo":{"mode":"manual","vendor":"Google Inc. (Apple)","renderer":"ANGLE (Apple, Apple M1 Max, OpenGL 4.1)","webgl2Maximum":"{\"UNIFORM_BUFFER_OFFSET_ALIGNMENT\":256,\"MAX_TEXTURE_SIZE\":16384,\"MAX_VIEWPORT_DIMS\":[16384,16384],\"MAX_VERTEX_ATTRIBS\":16,\"MAX_VERTEX_UNIFORM_VECTORS\":1024,\"MAX_VARYING_VECTORS\":31,\"MAX_COMBINED_TEXTURE_IMAGE_UNITS\":32,\"MAX_VERTEX_TEXTURE_IMAGE_UNITS\":16,\"MAX_TEXTURE_IMAGE_UNITS\":16,\"MAX_FRAGMENT_UNIFORM_VECTORS\":1024,\"MAX_CUBE_MAP_TEXTURE_SIZE\":16384,\"MAX_RENDERBUFFER_SIZE\":16384,\"MAX_3D_TEXTURE_SIZE\":2048,\"MAX_ELEMENTS_VERTICES\":1048575,\"MAX_ELEMENTS_INDICES\":150000,\"MAX_TEXTURE_LOD_BIAS\":16,\"MAX_DRAW_BUFFERS\":8,\"MAX_FRAGMENT_UNIFORM_COMPONENTS\":4096,\"MAX_VERTEX_UNIFORM_COMPONENTS\":4096,\"MAX_ARRAY_TEXTURE_LAYERS\":2048,\"MIN_PROGRAM_TEXEL_OFFSET\":-8,\"MAX_PROGRAM_TEXEL_OFFSET\":7,\"MAX_VARYING_COMPONENTS\":124,\"MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS\":4,\"MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS\":64,\"MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS\":4,\"MAX_COLOR_ATTACHMENTS\":8,\"MAX_SAMPLES\":4,\"MAX_VERTEX_UNIFORM_BLOCKS\":16,\"MAX_FRAGMENT_UNIFORM_BLOCKS\":16,\"MAX_COMBINED_UNIFORM_BLOCKS\":32,\"MAX_UNIFORM_BUFFER_BINDINGS\":72,\"MAX_UNIFORM_BLOCK_SIZE\":65536,\"MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS\":266240,\"MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS\":266240,\"MAX_VERTEX_OUTPUT_COMPONENTS\":64,\"MAX_FRAGMENT_INPUT_COMPONENTS\":128,\"MAX_ELEMENT_INDEX\":4294967295}"},"webgpu":{"mode":"manual"},"clientRect":{"mode":"real"},"notes":{"content":null,"color":"blue","style":"text","icon":"info"},"timezone":{"mode":"auto","value":null},"locale":{"mode":"auto","value":null},"proxy":{"id":101268587},"statusId":0,"geolocation":{"mode":"auto","latitude":null,"longitude":null,"accuracy":null},"cpu":{"mode":"manual","value":8},"memory":{"mode":"manual","value":8},"screen":{"mode":"real","resolution":null},"audio":{"mode":"real"},"mediaDevices":{"mode":"real","audioInputs":null,"videoInputs":null,"audioOutputs":null},"ports":{"mode":"protect","blacklist":"3389,5900,5800,7070,6568,5938"},"doNotTrack":false,"args":[],"platformVersion":"13.4.1","uaFullVersion":"120.0.5845.96","login":"","password":"","appCodeName":"Mozilla","platformName":"MacIntel","connectionDownlink":2.05,"connectionEffectiveType":"4g","connectionRtt":150,"connectionSaveData":0,"cpuArchitecture":"","osVersion":"10.15.7","vendorSub":"","productSub":"20030107","vendor":"Google Inc.","product":"Gecko"})
headers = {
'authorization': 'Bearer ваш_токен_доступа_в_программу',
'content-type': 'application/json',
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
If the request does not pass or an error appears, then you need to request a print from the backend, take it from there.
Also - webgl2Maximum should be packed into a variable in json.dumps format and this variable should be passed to payload when creating a profile in the webgl2Maximum section.