Load API keys
Ensure you have Prove Sandbox credentials from the Developer Portal. To access the Prove API, use your OAuth 2.0 client ID and client secret. You can load these from environment variables or another method:
clientID := os.Getenv("PROVE_CLIENT_ID")
clientSecret := os.Getenv("PROVE_CLIENT_SECRET")
proveEnv := "uat-us" // Use UAT in US region.
client := provesdkservergo.New(
provesdkservergo.WithServer(proveEnv),
provesdkservergo.WithSecurity(components.Security{
ClientID: provesdkservergo.String(clientID),
ClientSecret: provesdkservergo.String(clientSecret),
}),
)
Replace uat-us with uat-eu if performing testing outside of North America.
Install server-side SDK
Install the server-side SDK of your choice by running a command in your terminal, or by using a dependency management tool specific to your project.
# The Go library is hosted on GitHub so you can use this command to import it
# to your Go application.
go get github.com/prove-identity/prove-sdk-server-go
# Ensure you import the SDK in your code like this:
import (
provesdkservergo "github.com/prove-identity/prove-sdk-server-go"
"github.com/prove-identity/prove-sdk-server-go/models/components"
)
Install client-side SDK
Install the client-side SDK of your choice by running a command in your terminal, or by using a dependency management tool specific to your project.
Web SDK
Android SDK
iOS SDK
# Run this command to install the package (ensure you have the latest version).
npm install @prove-identity/prove-auth@2.8.2
Prove manages a maven repository with Android binaries to enable integration with Gradle.Update the dependencies object in the build.gradle file:dependencies {
// Existing dependencies are here.
// Add the Prove Link dependencies:
implementation 'com.prove.sdk:proveauth:6.6.0'
}
You’ll also need to point to the repository by updating your settings.gradle file with the Maven repository:dependencyResolutionManagement {
// Existing repository settings are here.
repositories {
// Existing repositories are here.
// Add the Prove Link Maven repository:
maven {
url = "https://prove.jfrog.io/artifactory/libs-public-maven/"
}
}
}
The following needs added to the build.gradle file to also download dependency libraries:dependencies {
implementation fileTree('libs')
}
If you receive an error message on the application@fullBackupContent value, you can resolve it by adding this line of code to your application AndroidManifest.xml file inside the <application>...</application> node. Add it as an attribute to the opening application tag:<application
...
tools:replace="android:fullBackupContent"
...>
</application>
The Prove Auth SDK and its children SDKs merge the following permissions into the main application:<!-- Required to perform authentication -->
<uses-permission android:name="android.permission.INTERNET" />
<!-- Required to access information about networks -->
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<!-- Required for ConnectivityManager.requestNetwork -->
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
Prove manages a repository with the libraries to enable integration.Execute the following to import CocoaPod from the Prove pod repository:# Run this command to install the cocoapods-art plugin (authored by Artifactory)
gem install cocoapods-art
# Run this command to add the Prove pod repository
pod repo-art add prove.jfrog.io https://prove.jfrog.io/artifactory/api/pods/libs-public-cocoapods
# In your Podfile, paste in the Prove pod repository as a source
plugin 'cocoapods-art', :sources => [
'prove.jfrog.io'
]
# In your Podfile, paste in the SDK pods
pod 'ProveAuth', '6.6.0'
# Run this command to install the SDK pods
pod install