> For the complete documentation index, see [llms.txt](https://docs.elliott.diy/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.elliott.diy/tor-recon/tor-relays-non-exit.md).

# Tor Relays (Non-Exit)

This endpoint returns IP addresses for all known **non-exit** Tor relays — nodes that participate in the Tor network but do not allow traffic to leave to the open internet.

**Endpoint:**\
`https://api.elliott.diy/v1/tor/relay`

***

### Response Format

* **Plaintext (default)**\
  Lists each IP on a new line:

  ```
  https://api.elliott.diy/v1/tor/relay
  ```
* **JSON**\
  Use `?format=json` to return a structured response:

  ```
  https://api.elliott.diy/v1/tor/relay?format=json
  ```

  ```json
  {
    "ips": [
      "185.220.100.253",
      "185.220.101.40"
    ]
  }
  ```

***

### Notes

* Only includes relays **not flagged as Exit** by the Tor network.
* Data is pulled from the full Tor consensus via the Tor Project.
* Useful for detecting infrastructure used within the Tor network without implicating actual exit traffic.
* Cache refreshed every 6 hours.
* Use the Tor Exit Node list if you're only interested in endpoints where traffic leaves the Tor network.
