# ProviderImportCredentialsRequest

Artifact: [androidx.credentials.providerevents:providerevents](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents) [View Source](https://cs.android.com/search?q=file:androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest.kt+class:androidx.credentials.providerevents.transfer.ProviderImportCredentialsRequest) Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents#1.0.0-beta01)

*** ** * ** ***


```
public final class ProviderImportCredentialsRequest
```

<br />

*** ** * ** ***

Request received by the provider after the query phase of the import flow is complete i.e. the user was presented with a list of entries, and the user has now made a selection from the list of `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ExportEntry` presented on the selector UI.

When the provider is responding to this request, it must write the response to the `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest#uri()` provided in this request, so that the importer can read the response from the transfer medium.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest#ProviderImportCredentialsRequest(androidx.credentials.providerevents.transfer.ImportCredentialsRequest,androidx.credentials.provider.CallingAppInfo,android.net.Uri,kotlin.String)( @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ImportCredentialsRequest request, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/credentials/provider/CallingAppInfo callingAppInfo, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/android/net/Uri.html uri, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html credId )` |

| ### Public methods |
|---|---|
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/credentials/provider/CallingAppInfo` | `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest#getCallingAppInfo()()` the caller's app info |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest#getCredId()()` the secret id that is used to identify the `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ExportEntry`. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ImportCredentialsRequest` | `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest#getRequest()()` a request to import the provider's credentials |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/android/net/Uri.html` | `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ProviderImportCredentialsRequest#getUri()()` the FileProvider uri that the importer will read the response from |

## Public constructors

### ProviderImportCredentialsRequest

Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents#1.0.0-beta01)

```
public ProviderImportCredentialsRequest(
    @NonNull ImportCredentialsRequest request,
    @NonNull CallingAppInfo callingAppInfo,
    @NonNull Uri uri,
    @NonNull String credId
)
```

## Public methods

### getCallingAppInfo

Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents#1.0.0-beta01)

```
public final @NonNull CallingAppInfo getCallingAppInfo()
```

the caller's app info

### getCredId

Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents#1.0.0-beta01)

```
public final @NonNull String getCredId()
```

the secret id that is used to identify the `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ExportEntry`. This is set while registering export entries. This can be used to validate that the platform that registered `https://developer.android.com/reference/androidx/credentials/providerevents/transfer/ExportEntry` and the platform that is requesting the credentials are the same.

### getRequest

Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents#1.0.0-beta01)

```
public final @NonNull ImportCredentialsRequest getRequest()
```

a request to import the provider's credentials

### getUri

Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/credentials-providerevents#1.0.0-beta01)

```
public final @NonNull Uri getUri()
```

the FileProvider uri that the importer will read the response from