# NETWORK::_NETWORK_GET_GAMERTAG_FROM_FRIEND

- **Hash:** `0x5659D87BE674AB17`
- **Namespace:** NETWORK
- **Runtime name (Lua/JS):** `NetworkGetGamertagFromFriend`
- **Side:** client (game native)
- **Name status:** community guess (may change)
- **Documentation:** named only
- **Since game build:** 1207
- **URL:** https://natives.borderlinerp.com/natives/NETWORK/_NETWORK_GET_GAMERTAG_FROM_FRIEND

## Signature

```c
const char* _NETWORK_GET_GAMERTAG_FROM_FRIEND(Any* gamerHandle);
```

## Parameters

- `gamerHandle` (`Any*`)

## Returns

`const char*`

## Usage

### Lua

```lua
local retval, gamerHandle = NetworkGetGamertagFromFriend(gamerHandle)

-- always available, by hash
local retval, gamerHandle = Citizen.InvokeNative(0x5659D87BE674AB17, Citizen.PointerValueIntInitialized(gamerHandle), Citizen.ResultAsString())
```

### JavaScript

```js
const [retval, gamerHandle] = NetworkGetGamertagFromFriend(gamerHandle);

// by hash
const [retval, gamerHandle] = Citizen.invokeNative('0x5659D87BE674AB17', Citizen.pointerValueIntInitialized(gamerHandle), Citizen.returnResultAnyway(), Citizen.resultAsString());
```

### C#

```csharp
var gamerHandle = new OutputArgument();
string retval = Function.Call<string>((Hash)0x5659D87BE674AB17, gamerHandle);
// gamerHandle.GetResult<int>()
```

- The last argument is an in/out pointer: pass its initial value, and the updated value is returned after the result.
- `Any*` arguments are often structs. Build them with a DataView buffer and pass it with `:Buffer()` — see the examples and notes below.
- The name is a community guess and may change. If the named call is missing in your client build, use `InvokeNative` with the hash — it always works.

*Sources: alloc8or RDR3 NativeDB.*
