# CodeChallenge

# CodeChallenge

Artifact:[androidx.wear:wear-phone-interactions](https://developer.android.com/jetpack/androidx/releases/wear)  
[View Source](https://cs.android.com/search?q=file:androidx/wear/phone/interactions/authentication/CodeChallenge.kt+class:androidx.wear.phone.interactions.authentication.CodeChallenge)  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/wear#1.0.0)

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/wear/phone/interactions/authentication/CodeChallenge "View this page in Java")

<br />

```
@RequiresApi(value = 26)
class CodeChallenge
```

<br />

*** ** * ** ***

Authorization code challenge.

Related specifications:[Proof Key for Code Exchange by OAuth Public Clients (RFC 7636)](https://tools.ietf.org/html/rfc7636)

## Summary

|                                                                                                                                                                 ### Public constructors                                                                                                                                                                  |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [CodeChallenge](https://developer.android.com/reference/kotlin/androidx/wear/phone/interactions/authentication/CodeChallenge#CodeChallenge(androidx.wear.phone.interactions.authentication.CodeVerifier))`(codeVerifier: `[CodeVerifier](https://developer.android.com/reference/kotlin/androidx/wear/phone/interactions/authentication/CodeVerifier)`)` |

|                                        ### Public functions                                         |
|-----------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `open operator `[Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | [equals](https://developer.android.com/reference/kotlin/androidx/wear/phone/interactions/authentication/CodeChallenge#equals(kotlin.Any))`(other: `[Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html)`?)` |
| `open `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)                  | [hashCode](https://developer.android.com/reference/kotlin/androidx/wear/phone/interactions/authentication/CodeChallenge#hashCode())`()`                                                                                            |

|                               ### Public properties                               |
|-----------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------|
| [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html) | [value](https://developer.android.com/reference/kotlin/androidx/wear/phone/interactions/authentication/CodeChallenge#value()) The challenge value. |

## Public constructors

### CodeChallenge

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/wear#1.0.0)  

```
CodeChallenge(codeVerifier: CodeVerifier)
```  

## Public functions

### equals

```
open operator fun equals(other: Any?): Boolean
```  

### hashCode

```
open fun hashCode(): Int
```  

## Public properties

### value

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/wear#1.0.0)  

```
val value: String
```

The challenge value.