RequestRocketRequestRocketDocs
ConnectProxies

Proxies API

Create a proxy, then call it on the regional host.

The Core API creates and reads the proxy record. Callers of the target use the regional proxy URL or the async URL, with the inbound credential. They do not use the user token.

Endpoints

MethodPathWhat it does
GET/api/clients/:clientId/proxiesList proxies
POST/api/clients/:clientId/proxiesCreate a proxy
GET/api/clients/:clientId/proxies/:proxyIdRead a proxy
PUT/api/clients/:clientId/proxies/:proxyIdUpdate a proxy
DELETE/api/clients/:clientId/proxies/:proxyIdDelete a proxy

Create a proxy

POST /api/clients/:clientId/proxies creates the proxy. Set one region, the inbound credential id in proxyProxyCredentialId, the target id, and the target credential id.

Request

curl -X POST "https://api.requestrocket.com/api/clients/:clientId/proxies" \
  -H "Authorization: u-your-token" \
  -H "Content-Type: application/json" \
  -d '{
  "proxyName": "HTTPBin",
  "proxyRegion": "us-east-2",
  "proxyProxyCredentialId": "2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92",
  "proxyTargetId": "7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44",
  "proxyTargetCredentialId": "9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31",
  "proxyActive": true
}'
import axios from "axios";

const response = await axios.request({
  method: "POST",
  url: "https://api.requestrocket.com/api/clients/:clientId/proxies",
  headers: {
    "Authorization": "u-your-token",
    "Content-Type": "application/json",
  },
  data: {
  "proxyName": "HTTPBin",
  "proxyRegion": "us-east-2",
  "proxyProxyCredentialId": "2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92",
  "proxyTargetId": "7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44",
  "proxyTargetCredentialId": "9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31",
  "proxyActive": true
}
});

console.log(response.status, response.data);
import requests

response = requests.request(
    "POST",
    "https://api.requestrocket.com/api/clients/:clientId/proxies",
    headers={
        "Authorization": "u-your-token",
        "Content-Type": "application/json",
    },
    data="{\n  \"proxyName\": \"HTTPBin\",\n  \"proxyRegion\": \"us-east-2\",\n  \"proxyProxyCredentialId\": \"2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92\",\n  \"proxyTargetId\": \"7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44\",\n  \"proxyTargetCredentialId\": \"9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31\",\n  \"proxyActive\": true\n}"
)
print(response.status_code, response.json())
package main

import (
    "fmt"
    "io"
    "net/http"
    "strings"
)

func main() {
    payload := strings.NewReader(`{
  "proxyName": "HTTPBin",
  "proxyRegion": "us-east-2",
  "proxyProxyCredentialId": "2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92",
  "proxyTargetId": "7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44",
  "proxyTargetCredentialId": "9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31",
  "proxyActive": true
}`)
    req, _ := http.NewRequest("POST", "https://api.requestrocket.com/api/clients/:clientId/proxies", payload)
    req.Header.Set("Authorization", "u-your-token")
    req.Header.Set("Content-Type", "application/json")
    resp, _ := http.DefaultClient.Do(req)
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(resp.StatusCode, string(body))
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class Example {
    public static void main(String[] args) throws Exception {
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create("https://api.requestrocket.com/api/clients/:clientId/proxies"))
            .method("POST", HttpRequest.BodyPublishers.ofString("{\n  \"proxyName\": \"HTTPBin\",\n  \"proxyRegion\": \"us-east-2\",\n  \"proxyProxyCredentialId\": \"2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92\",\n  \"proxyTargetId\": \"7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44\",\n  \"proxyTargetCredentialId\": \"9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31\",\n  \"proxyActive\": true\n}"))
            .header("Authorization", "u-your-token")
            .header("Content-Type", "application/json")
            .build();
        HttpResponse<String> response = HttpClient.newHttpClient()
            .send(request, HttpResponse.BodyHandlers.ofString());
        System.out.println(response.statusCode());
        System.out.println(response.body());
    }
}

Responses

{
  "proxies": [
    {
      "userId": "0f8e6c1a-2b7d-4c3e-9a55-1d2e3f4a5b6c",
      "clientId": "b3a1c7d2-5e44-4f0a-9c1e-7d2f8a6b1c90",
      "parentId": "b3a1c7d2-5e44-4f0a-9c1e-7d2f8a6b1c90",
      "proxyName": "HTTPBin",
      "proxyRegion": "us-east-2",
      "proxyProxyCredentialId": "2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92",
      "proxyTargetId": "7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44",
      "proxyTargetCredentialId": "9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31",
      "proxyActive": true,
      "proxyCreatedAt": "2026-11-02T07:30:00.000Z",
      "proxyUpdatedAt": "2026-11-02T07:30:00.000Z",
      "proxyDefaultRuleEffect": null,
      "proxyMaxRetries": null,
      "proxyMaxBackoff": null,
      "proxyNotes": null
    }
  ],
  "message": "Success"
}
{
  "message": "Input failed data validation",
  "errors": [
    "/proxyProxyCredentialId: must have required property 'proxyProxyCredentialId'"
  ]
}
{
  "message": "Unauthorized"
}
{
  "Message": "User is not authorized to access this resource with an explicit deny in an identity-based policy"
}
{
  "message": "method / endpoint not supported"
}

Request body

ParameterTypeRequiredDescription
proxyNamestring✓Display name, 3–256 characters.
proxyRegionstring✓Region that stores the proxy, such as us-east-2. It cannot be changed later.
proxyProxyCredentialIdstring✓Inbound credential id, or consumer_pool when callers sign in through the consumer pool.
proxyTargetIdstring✓Target this proxy calls.
proxyTargetCredentialIdstring✓Target credential sent on the upstream call.
proxyActiveboolean—When false, the proxy does not serve traffic. Defaults to true.
proxyAliasstring—Lowercase letters and dashes. Stored in lowercase.
proxyDefaultRuleEffectstring—"allow" or "deny". Applied when no rule matches.
proxyMaxRetriesnumber—How many times the async URL retries a transient failure. The gateway caps this at 10.
proxyMaxBackoffnumber—Retry wait ceiling in milliseconds. The gateway caps this at 30000. This call accepts a value up to 60000.
proxyAdditionalHeadersobject—Map of header name to string value, added on every call.
proxyAdditionalQueryParamsobject—Map of query parameter name to string value, added on every call.
proxyAdditionalDataobject—Map of body field name to string value, merged into every call.
proxyNotesstring—Free-text note stored on the proxy.

Returns a proxies array with message set to "Success". The attributes match Read a proxy. sKey on the create response is the new proxy id.

Read a proxy

GET /api/clients/:clientId/proxies/:proxyId returns the proxy record and a referenceStatus of ok, missing_credential, or missing_target.

Request

curl -X GET "https://api.requestrocket.com/api/clients/:clientId/proxies/:proxyId" \
  -H "Authorization: u-your-token"
import axios from "axios";

const response = await axios.request({
  method: "GET",
  url: "https://api.requestrocket.com/api/clients/:clientId/proxies/:proxyId",
  headers: {
    "Authorization": "u-your-token",
  }
});

console.log(response.status, response.data);
import requests

response = requests.request(
    "GET",
    "https://api.requestrocket.com/api/clients/:clientId/proxies/:proxyId",
    headers={
        "Authorization": "u-your-token",
    }
)
print(response.status_code, response.json())
package main

import (
    "fmt"
    "io"
    "net/http"
    "strings"
)

func main() {
    var payload io.Reader
    req, _ := http.NewRequest("GET", "https://api.requestrocket.com/api/clients/:clientId/proxies/:proxyId", payload)
    req.Header.Set("Authorization", "u-your-token")
    resp, _ := http.DefaultClient.Do(req)
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(resp.StatusCode, string(body))
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class Example {
    public static void main(String[] args) throws Exception {
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create("https://api.requestrocket.com/api/clients/:clientId/proxies/:proxyId"))
            .method("GET", HttpRequest.BodyPublishers.noBody())
            .header("Authorization", "u-your-token")
            .build();
        HttpResponse<String> response = HttpClient.newHttpClient()
            .send(request, HttpResponse.BodyHandlers.ofString());
        System.out.println(response.statusCode());
        System.out.println(response.body());
    }
}

Responses

{
  "proxies": [
    {
      "proxyName": "HTTPBin",
      "proxyRegion": "us-east-2",
      "proxyProxyCredentialId": "2a6f4b81-9c05-4e37-b1d8-6f0a3c5e7d92",
      "proxyTargetId": "7c2e9a14-6b31-4d8f-a0c5-3e1f7b9d2a44",
      "proxyTargetCredentialId": "9e1d3a76-5b48-4c02-8a7f-1d4c6b8e0f31",
      "proxyActive": true,
      "referenceStatus": "ok"
    }
  ],
  "message": "Success"
}
{
  "message": "Error getting proxies"
}
{
  "message": "Unauthorized"
}
{
  "Message": "User is not authorized to access this resource with an explicit deny in an identity-based policy"
}
{
  "message": "method / endpoint not supported"
}

Response attributes

AttributeTypeDescription
proxiesarrayOne proxy object.
proxies[].sKeystringProxy id. Pass this as proxyId on other endpoints.
proxies[].pKey / parentIdstringOrganisation id.
proxies[].proxyNamestringDisplay name.
proxies[].proxyRegionstringDeployment region.
proxies[].proxyProxyCredentialIdstringInbound credential id, or consumer_pool.
proxies[].proxyTargetIdstringTarget id.
proxies[].proxyTargetCredentialIdstringTarget credential id.
proxies[].proxyActivebooleanWhether the proxy serves traffic.
proxies[].proxyCreatedAtstringISO 8601 creation time.
proxies[].proxyUpdatedAtstringISO 8601 last update time.
proxies[].proxyDefaultRuleEffectstring or null"allow" or "deny".
proxies[].proxyMaxRetriesnumber or nullAsync retry count.
proxies[].proxyMaxBackoffnumber or nullRetry wait ceiling in milliseconds.
proxies[].proxyAliasstring or nullURL alias.
proxies[].proxyNotesstring or nullFree-text note.
proxies[].proxyAdditionalHeadersobject or nullMap of header name to value.
proxies[].proxyAdditionalQueryParamsobject or nullMap of query parameter name to value.
proxies[].proxyAdditionalDataobject or nullMap of body field name to value.
proxies[].referenceStatusstringok, missing_credential, or missing_target. Only on GET.
messagestring"Success".

List proxies

GET /api/clients/:clientId/proxies returns every proxy for the organisation in one response. Each item matches Read a proxy, including referenceStatus.

Update a proxy

PUT /api/clients/:clientId/proxies/:proxyId changes the fields you send. The region stays as it was created.

Request body

All fields are optional. Omit a field to leave it unchanged.

ParameterTypeRequiredDescription
proxyNamestring—Display name, 3–256 characters.
proxyProxyCredentialIdstring—Inbound credential id, or consumer_pool.
proxyTargetIdstring—Target this proxy calls.
proxyTargetCredentialIdstring—Target credential sent on the upstream call.
proxyActiveboolean—When false, the proxy does not serve traffic.
proxyAliasstring—Lowercase letters and dashes. An empty string clears it.
proxyDefaultRuleEffectstring—"allow" or "deny".
proxyMaxRetriesnumber—Async retry count. Maximum 10.
proxyMaxBackoffnumber—Retry wait ceiling in milliseconds. Maximum 30 on this call.
proxyAdditionalHeadersobject—Map of header name to string value. null clears the stored map.
proxyAdditionalQueryParamsobject—Map of query parameter name to string value. null clears the stored map.
proxyAdditionalDataobject—Map of body field name to string value. null clears the stored map.
proxyNotesstring—Free-text note.

Returns a proxies array with message set to "Proxy updated successfully". The attributes match Read a proxy except referenceStatus is absent.

Call the proxy

https://{region}.requestrocket.com/api/{proxyId}/{target-path}

Authenticate with the inbound credential, not the user token. GET https://us-east-2.requestrocket.com/api/{proxyId}/get with the HTTPBin proxy returns the target response when the call is granted.

Async API

https://{region}.requestrocket.com/async/{proxyId}/{target-path}

The async URL queues the same call and retries transient failures. The response gives you a request id you can read from Request logs.

Next

On this page