---
title: "User Profiles"
canonical_url: "https://apidocs.sportradar.com/resources/virtual-stadium/docs/sdk/centralHub/profiles"
markdown_url: "https://apidocs.sportradar.com/resources/virtual-stadium/docs/sdk/centralHub/profiles.md"
last_updated: "2026-04-16T10:19:11Z"
---

# User Profiles

Load and manage Central Hub user profiles, shared bets, and profile privacy settings.

## Profile Management

`CentralHubProfileProvider` gives you access to profile details, avatar URLs, shared bets, and privacy updates.

### Profile Information

The provider can supply:

- **User data** — username, avatar, bio, and verification state.
- **Statistics** — followers, following, inspirations, and reach.
- **Shared bets** — a user's published bet history.
- **Privacy settings** — whether the user's profile is public or private.

**Android**

```kotlin
class ProfileViewModel : ViewModel(), KoinComponent {

    private val profileProvider: CentralHubProfileProvider = get()

    val profileState = profileProvider.profileState

    fun loadProfile(userId: String) {
        profileProvider.getUserData(userId)
    }

    fun getAvatarUrl(userId: String): String {
        return profileProvider.getUserAvatarUrl(userId)
    }

    fun setPrivate() {
        profileProvider.setProfileToPrivate(
            onSuccess = { /* Profile now private */ },
            onFailure = { error -> /* Handle error */ },
        )
    }

    fun setPublic() {
        profileProvider.setProfileToPublic(
            onSuccess = { /* Profile now public */ },
            onFailure = { error -> /* Handle error */ },
        )
    }

    override fun onCleared() {
        super.onCleared()
        profileProvider.destroy()
    }
}
```

```kotlin
@Composable
fun ProfileScreen(
    userId: String,
    viewModel: ProfileViewModel = viewModel(),
) {
    val state by viewModel.profileState.collectAsStateWithLifecycle()

    LaunchedEffect(userId) {
        viewModel.loadProfile(userId)
    }

    Column {
        AsyncImage(
            model = viewModel.getAvatarUrl(state.user.id),
            contentDescription = "User avatar",
        )

        Text(state.user.username)

        Row {
            Text("Followers: ${state.followersCount}")
            Text("Following: ${state.followingCount}")
            Text("Inspirations: ${state.inspirations}")
            Text("Reach: ${state.reach}")
        }
    }
}
```

**iOS**

```swift
class ProfileViewModel: ObservableObject {

    private let profileProvider =
        KoinHelper().getCentralHubProfileProvider()

    @Published var profileState: CentralHubProfileState?

    init() {
        subscribeToProfile()
    }

    private func subscribeToProfile() {
        profileProvider.profileState.subscribe { [weak self] state in
            self?.profileState = state
        }
    }

    func loadProfile(userId: String) {
        profileProvider.getUserData(userId: userId)
    }

    func getAvatarUrl(userId: String) -> String {
        return profileProvider.getUserAvatarUrl(userId: userId)
    }

    func setPrivate() {
        profileProvider.setProfileToPrivate(
            onSuccess: { /* Profile now private */ },
            onFailure: { error in /* Handle error */ }
        )
    }

    func setPublic() {
        profileProvider.setProfileToPublic(
            onSuccess: { /* Profile now public */ },
            onFailure: { error in /* Handle error */ }
        )
    }

    deinit {
        profileProvider.destroy()
    }
}
```

## Data Models

### CentralHubProfileState

```kotlin
data class CentralHubProfileState(
    val user: User,
    val isMyProfile: Boolean,
    val isPrivate: Boolean,
    val isFollowed: Boolean,
    val followersCount: Int,
    val followingCount: Int,
    val inspirations: Int,
    val reach: Int,
    val sharedBets: List<BetShare>,
    val loadingStatus: LoadingStatus,
    val followActionLoadingStatus: LoadingStatus,
)
```

## Related Topics

- [Social Features](https://apidocs.sportradar.com/resources/virtual-stadium/docs/sdk/centralHub/social.md) - Load followers and following relationships.
- [Bet Sharing](https://apidocs.sportradar.com/resources/virtual-stadium/docs/sdk/centralHub/betSharing.md) - Show a user's shared bet history.
