Facebook Pixel
APILinkedIn Account

Change proxy IP

Give a LinkedIn account a new proxy IP in the same country. The proxy country does not change. Takes no request body and makes no LinkedIn call. Limit: 3 changes per account in any rolling 7 days. The allowance is shared with the Change IP button in the ConnectSafely app. Once it is used up the call returns 429 with `nextAllowedAt`, the time the oldest change leaves the 7-day window. A second call within 60 seconds of a successful change also returns 429. A call that fails with 502 does not count against the limit. Calls also count toward the per-minute API limit and appear in API Logs. The account must already have a proxy location set in ConnectSafely, otherwise the call returns 400.

POST/account/{accountId}/proxy/rotations
Authentication requiredAccount

Code Examples

curl -X POST 'https://api.connectsafely.ai/linkedin/account/<accountId>/proxy/rotations' \
-H 'Authorization: Bearer <your_api_key>'

Give a LinkedIn account a new proxy IP in the same country. The proxy country does not change. Takes no request body and makes no LinkedIn call.

Limit: 3 changes per account in any rolling 7 days. The allowance is shared with the Change IP button in the ConnectSafely app. Once it is used up the call returns 429 with nextAllowedAt, the time the oldest change leaves the 7-day window. A second call within 60 seconds of a successful change also returns 429. A call that fails with 502 does not count against the limit. Calls also count toward the per-minute API limit and appear in API Logs.

The account must already have a proxy location set in ConnectSafely, otherwise the call returns 400.

Parameters

NameInRequiredTypeDescription
accountIdpathYesstringLinkedIn account id (24-character Mongo ObjectId). Must be an account you own or one shared with you through a workspace.

Request Body

No request body.

Responses

StatusDescription
200The account now uses a new proxy IP
400The account has no proxy assigned
401Unauthorized - Invalid or missing API key
403No active API seat for this account
404Account not found, deleted, or not visible to the caller
429The weekly allowance is used up, or the proxy was changed less than 60 seconds ago. nextAllowedAt, rotationsUsed and rotationsLimit are present only when the weekly allowance is used up.
500Internal server error
502A new proxy could not be assigned. The attempt is not counted. The account can be left without a proxy: if a retry returns 400, set the proxy location again in ConnectSafely.

Rate Limit Headers

All responses include rate limit information in the headers:

HeaderDescription
X-RateLimit-ActionThe action type being rate limited
X-RateLimit-LimitMaximum actions allowed per period
X-RateLimit-UsedActions used in current period
X-RateLimit-RemainingActions remaining
X-RateLimit-ResetISO 8601 timestamp when limit resets

200 Response Parameters

NameTypeDescription
successboolean
accountIdstring
countrystringProxy country code, unchanged by this call
rotationsUsedintegerChanges made on this account in the last 7 days, including this one
rotationsLimitintegerChanges allowed per account in any 7 days

200 Example

{
  "success": true,
  "accountId": "60d21b4667d0d8992e610c85",
  "country": "us",
  "rotationsUsed": 1,
  "rotationsLimit": 3
}

400 Response Parameters

NameTypeDescription
errorstring

400 Example

{
  "error": "This account has no proxy assigned. Set a proxy location first."
}

401 Response Parameters

NameTypeDescription
errorstring

401 Example

{
  "error": "Unauthorized"
}

403 Response Parameters

NameTypeDescription
errorstring

403 Example

{
  "error": "No API seat allocated for this LinkedIn account.",
  "code": "NO_API_SEAT_FOR_ACCOUNT"
}

404 Response Parameters

NameTypeDescription
errorstring

404 Example

{
  "error": "Account not found"
}

429 Response Parameters

NameTypeDescription
errorstring
nextAllowedAtstring (date-time)
rotationsUsedinteger
rotationsLimitinteger

429 Example

{
  "error": "You've used all 3 proxy changes for this week. Next one available Mon Dec 07 2026.",
  "nextAllowedAt": "2026-12-07T09:14:02.000Z",
  "rotationsUsed": 3,
  "rotationsLimit": 3
}

500 Response Parameters

NameTypeDescription
errorstring

500 Example

{
  "error": "Internal Server Error"
}

502 Response Parameters

NameTypeDescription
errorstring

502 Example

{
  "error": "Could not assign a new proxy port. Please try again in a minute."
}

On this page