> ## Documentation Index
> Fetch the complete documentation index at: https://primer.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# PrimerCardNetwork

> Card network data class used in co-badged card selection

> [!WARNING]
>
> Primer Checkout Android SDK is currently in **beta** (v3.0.0-beta.8).
> The API is subject to change before the stable release.

Represents a card network option for co-badged card selection. Exposed through `PrimerCardFormController.State.networkSelection`.

## Definition

```kotlin theme={"dark"}
data class PrimerCardNetwork(
    val network: CardNetwork.Type,
    val displayName: String,
    val allowed: Boolean,
)
```

## Properties

| Property | Type | Description |
| - | - | - |
| `network` | `CardNetwork.Type` | The card network type |
| `displayName` | `String` | Human-readable network name (e.g., `"Visa"`, `"Mastercard"`) |
| `allowed` | `Boolean` | Whether this network is allowed for the current transaction |

## CardNetwork.Type

```kotlin theme={"dark"}
enum class CardNetwork.Type {
    OTHER, VISA, MASTERCARD, AMEX, DINERS_CLUB, DISCOVER,
    JCB, UNIONPAY, MAESTRO, ELO, MIR, HIPER, HIPERCARD,
    CARTES_BANCAIRES, DANKORT, EFTPOS,
}
```

| Value | Display Name |
| - | - |
| `VISA` | Visa |
| `MASTERCARD` | Mastercard |
| `AMEX` | American Express |
| `DINERS_CLUB` | Diners Club |
| `DISCOVER` | Discover |
| `JCB` | JCB |
| `UNIONPAY` | UnionPay |
| `MAESTRO` | Maestro |
| `ELO` | Elo |
| `MIR` | Mir |
| `HIPER` | Hiper |
| `HIPERCARD` | Hipercard |
| `CARTES_BANCAIRES` | Cartes Bancaires |
| `DANKORT` | Dankort |
| `EFTPOS` | eftpos |
| `OTHER` | Unknown |

Each enum value also has a `displayName` property.

## Co-badged card selection

When a card supports multiple networks (e.g., Visa + Cartes Bancaires), the card form exposes network selection through the controller state:

```kotlin theme={"dark"}
val cardFormController = rememberCardFormController(checkout)
val state by cardFormController.state.collectAsStateWithLifecycle()

val selection = state.networkSelection
selection.availableNetworks   // List<PrimerCardNetwork>
selection.selectedNetwork     // PrimerCardNetwork?
selection.isNetworkSelectable // Boolean

cardFormController.selectCardNetwork(network)
```

| Property | Type | Description |
| - | - | - |
| `availableNetworks` | `List<PrimerCardNetwork>` | Networks available for the entered card number |
| `selectedNetwork` | `PrimerCardNetwork?` | Currently selected network, or `null` if auto-detected |
| `isNetworkSelectable` | `Boolean` | `true` when the user must choose between multiple networks |

See [PrimerCardFormController](https://primer.io/docs/sdk/android-checkout/v3.0.0-beta/api/card-form/card-form-controller.md) for full card form API.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.