# Batch modify profiles proxy

Endpoint: POST /api/env/setProxy/batch
Version: 1.0.0

## Request fields (application/json):

  - `envIds` (array)
    Choose one with serial IDs, must fill one

  - `proxy` (object, required)
    Used to change the bound proxy for environments. If proxyId is provided, bind to the proxy represented by that ID; otherwise, bind to a newly added proxy. If proxy information remains unchanged, no rebinding occurs (any change in proxyIp, proxyPort, proxyType, or proxyProvider is considered a new proxy, and rebinding succeeds)

  - `proxy.city` (string, required)
    City

  - `proxy.state` (string, required)
    State/Province

  - `proxy.country` (string, required)
    Country code (e.g. `us`). See [Country Time Zone Table](/api-reference/appendix/country-time-zone) for supported codes. Required when proxyProvider is 16/17/18

  - `proxy.encryptionType` (integer, required)
    Encryption method. Cannot be empty when proxyProvider is 11. 1: aes-128-gcm, 2: aes-192-gcm, 3: aes-256-gcm, 4: aes-128-cfb, 5: aes-192-cfb, 6: aes-256-cfb, 7: aes-128-ctr, 8: aes-192-ctr, 9: aes-256-ctr, 10: rc4-md5, 11: chacha20-ietf, 12: xchacha20, 13: chacha20-ietf-poly1305, 14: xchacha20-ietf-poly1305

  - `proxy.proxyId` (integer, required)
    Proxy ID

  - `proxy.proxyIp` (string, required)
    Proxy IP. Can be empty when proxyProvider is 16/17/18; required for others

  - `proxy.proxyPort` (integer, required)
    Proxy port (only numbers 1-65535 allowed). Can be empty when proxyProvider is 16/17/18; required for others

  - `proxy.proxyType` (integer, required)
    Proxy type, 0: http, 1: https. Cannot be empty when proxyProvider is 7/8

  - `proxy.proxyProvider` (string, required)
    Proxy provider 0: http, 1: https, 2: socks5, 3: ssh, 4: Oxylabs, 5: Proxys.io, 7: Luminati, 8: Lumauto, 9: Oxylabsauto, 10: Trojan, 11: Shadowsocks, 13: ABCPROXY, 14: LunaProxy, 15: IPHTML, 16: PiaProxy, 17: 922S5, 18: 360Proxy

  - `proxy.proxyName` (string, required)
    Proxy name (maximum 600 characters)

  - `proxy.password` (string, required)
    Password (maximum 100 characters)

  - `proxy.refreshUrl` (string, required)
    Refresh URL

  - `proxy.ipMonitor` (boolean, required)
    Enable IP change monitoring? true: On, false: Off

  - `proxy.ipChangeAction` (integer, required)
    IP change monitoring 0: Block access, 1: Warn

  - `proxy.username` (string, required)
    Username (maximum 200 characters)

  - `uniqueIds` (array)
    Choose one with environment ID, must fill one

## Response 200 fields (application/json):

  - `code` (integer)

  - `msg` (null)

  - `data` (boolean)

  - `requestId` (string, required)

