Skip to main content
This example demonstrates how to fetch all proxies associated with a specific proxy user ID. The process handles the three different access types: unrestricted access, service-restricted access, and proxy-restricted access.

Overview

The workflow varies based on the proxy user’s proxy_user_access_type:
  1. Retrieve the proxy user to check their access type
  2. If access_type: "all": Fetch all proxies in your account
  3. If access_type: "service_restricted": Search ACLs for service IDs, then fetch proxies from those services
  4. If access_type: "proxy_restricted": Search ACLs for proxy IDs, then fetch those specific proxies

How It Works

1. Check Access Type

First, retrieve the proxy user to determine their proxy_user_access_type:

2. Three Different Workflows

For access_type: "all":
  • Fetch all proxies from your account using the proxy search endpoint
  • No ACL lookup needed
For access_type: "service_restricted":
  • Search Proxy User ACLs for this proxy user
  • Extract all service_id values from the ACL entries
  • Fetch proxies for each service using the proxy search endpoint with service_id filter
For access_type: "proxy_restricted":
  • Search Proxy User ACLs for this proxy user
  • Extract all proxy_id values from the ACL entries
  • Fetch each individual proxy using the proxy retrieve endpoint

3. Pagination Handling

For unrestricted and service-restricted access, the code handles pagination to ensure all proxies are retrieved, even when there are many results.