> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://useroot.docs.buildwithfern.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://useroot.docs.buildwithfern.com/_mcp/server.

# Get payee by ID

GET https://api.useroot.com/api/payees/{payee_id}

Retrieves a specific payee by their unique identifier.

**Path Parameters**

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `payee_id` | UUID | Yes | Unique identifier of the payee to retrieve |


**Success Responses**

| Status Code | Description |
|-------------|-------------|
| 200 | OK - The payee was successfully retrieved |

**Error Responses**

| Status Code | Error Code | Description |
|-------------|------------|-------------|
| 401 | AUTHENTICATION_ERROR | Authentication credentials are invalid or missing |
| 403 | AUTHORIZATION_ERROR | You do not have permission to perform this action |
| 404 | PAYEE_NOT_FOUND | The specified payee was not found |

Reference: https://useroot.docs.buildwithfern.com/api-reference/payees-api/get-payee-by-id

## Authentication

- `x-api-key` header (required) — RootPay API key sent in the x-api-key header. Keys are environment-scoped: live_* for production, test_* for sandbox.

## Request

### Path parameters

- `payee_id` (string, required)

## Response

### 200

Payee retrieved successfully

- `data` (object, required)
  - `created_at` (datetime, required)
  - `updated_at` (datetime, required)
  - `id` (string, required)
  - `name` (string, required)
  - `email` (string, required)
  - `country_code` (enum, optional)
    - Allowed values: `US`, `GB`, `IN`
  - `country_sub_division` (string, optional, nullable) — State, province, or country subdivision
  - `city` (string, optional, nullable) — City or town name
  - `address_line` (string, optional, nullable) — Street address, building number, postal code, etc.
  - `postal_code` (string, optional, nullable) — Zip or postal code
  - `client_metadata` (map from string to string, optional)
- `warning` (string, optional, nullable)

## Examples

**Response**

```json
{
  "data": {
    "created_at": "2024-03-20T12:00:00Z",
    "updated_at": "2024-03-20T12:00:00Z",
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "name": "John Doe",
    "email": "john.doe@example.com",
    "country_code": "US",
    "country_sub_division": "NY",
    "city": "New York",
    "address_line": "123 Main Street, Apt 4B",
    "postal_code": "10001"
  }
}
```

**SDK Code**

```python United States payee
import requests

url = "https://api.useroot.com/api/payees/payee_id"

headers = {"x-api-key": "<apiKey>"}

response = requests.get(url, headers=headers)

print(response.json())
```

```javascript United States payee
const url = 'https://api.useroot.com/api/payees/payee_id';
const options = {method: 'GET', headers: {'x-api-key': '<apiKey>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go United States payee
package main

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

func main() {

	url := "https://api.useroot.com/api/payees/payee_id"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("x-api-key", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby United States payee
require 'uri'
require 'net/http'

url = URI("https://api.useroot.com/api/payees/payee_id")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<apiKey>'

response = http.request(request)
puts response.read_body
```

```java United States payee
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.useroot.com/api/payees/payee_id")
  .header("x-api-key", "<apiKey>")
  .asString();
```

```php United States payee
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.useroot.com/api/payees/payee_id', [
  'headers' => [
    'x-api-key' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp United States payee
using RestSharp;

var client = new RestClient("https://api.useroot.com/api/payees/payee_id");
var request = new RestRequest(Method.GET);
request.AddHeader("x-api-key", "<apiKey>");
IRestResponse response = client.Execute(request);
```

```swift United States payee
import Foundation

let headers = ["x-api-key": "<apiKey>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.useroot.com/api/payees/payee_id")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```