Back to Credentials
Step-by-step guide

How to get your Bearer token with Charles Proxy

Capture the Amazon Flex token from your phone and paste it into AlwaysOnBoarding to activate the bot.

For advanced users only

This method requires installing an SSL certificate on your phone and configuring a proxy. If you make a mistake, your phone might lose internet temporarily. If you prefer something simpler, use the Auto-connect option with email/password.

Step 1

Download Charles Proxy

Charles Proxy is a professional HTTP/HTTPS inspection tool. It has a free 30-day trial then costs ~$50 USD. Install it on your computer (not on the phone).

If you want a free alternative you can use HTTP Toolkit (open source with modern UI) or mitmproxy.

Step 2

Configure Charles on your computer

Open Charles and set up the proxy and SSL proxying so it can intercept Amazon's encrypted connections.

  1. Open Charles Proxy. By default it listens on port 8888.

  2. Check the port: Menu Proxy > Proxy Settings.

    Proxy → Proxy Settings → HTTP Proxy: 8888
  3. Enable SSL Proxying and add Amazon's domains:

    Proxy → SSL Proxying Settings → Enable SSL Proxying
    Add → Host: *.amazon.com Port: 443
    Add → Host: *.amazonaws.com Port: 443
  4. Note your computer's local IP (Help > Local IP Addresses). You'll need it to configure the phone.

Step 3

Configure your phone

Your phone must be on the same Wi-Fi network as your computer. You'll set up the proxy and install Charles' SSL certificate.

iOS: Configure Wi-Fi proxy

  1. Make sure your iPhone is on the same Wi-Fi network as your PC.
  2. On the PC, in Charles, go to Help > SSL Proxying > Install Charles Root Certificate on a Mobile Device. Charles will show the IP and port.
  3. On the iPhone open Settings > Wi-Fi and tap (i) next to your network.
  4. Set manual proxy:
    Settings → Wi-Fi → tap (i) → Configure Proxy → Manual
    Server: <PC_IP> Port: 8888 (Authentication OFF)

iOS: Install and trust the certificate

  1. In iPhone Safari (not Chrome) open Charles' special URL:
    Safari → http://chls.pro/ssl
  2. A Charles popup will appear on your PC asking to approve the connection. Accept.
  3. iOS will download a profile. Go to:
    Settings → General → VPN & Device Management → Charles → Install
  4. Enable certificate trust:
    Settings → General → About → Certificate Trust Settings → Charles ON

Step 4

Capture the Bearer token

Open the Amazon Flex app on your phone and navigate around. Charles will record all HTTPS calls.

  1. Open the Amazon Flex app on your phone and log in (or navigate if already logged in).

  2. In Charles, search or filter by:

    api.amazon.com
  3. When you find an Amazon call, right-click on it, go to the Request > Headers tab and look for the line:

    Authorization: Bearer Atza|IwEBI...
  4. Copy the full Bearer value (starts with 'Atza|' and is hundreds of characters long).

  5. You can also look at other calls for the 'x-amz-access-token' header which has the same value.

Pro tip: use the Find menu

In Charles press Cmd/Ctrl+F and search for 'Atza|' or 'Bearer Atza' to quickly find your token among all calls. You can also filter by the header:

x-amz-access-token: Atza|IwEBI...

Step 5

Paste the token in AlwaysOnBoarding

You have the token. Go back to AlwaysOnBoarding and paste it into the connection wizard.

  1. Go to Credentials and click 'Add credential'.

  2. Choose 'Direct token' option.

  3. Enter your Amazon Flex email.

  4. Paste the full Bearer token (including the 'Atza|' prefix).

  5. If you also captured a refresh token (starts with 'Atzr|'), paste it in the optional field so the bot can auto-renew it.

Go paste my token

Step 6

Frequently asked questions

Additional resources