Provider Initialisation
This function does not trigger any UI elements
Description
The base component for the Metafi SDK which takes in your API Key, unique user ID, and other options as props.
Details
Signature
Arguments
apiKey
String
Your API Key. This can be displayed publicly
secretKey
String
Your Secret Key. Keep this securely and do not expose.
supportedChains
Array
An array of chains supported by your application. Please refer to the section on Chains for more information on what chains we support.
customTokens
Array
An array of custom tokens that you want supported in your users wallet. Please refer to the section on registering a custom token for more information.
options
Object
A list of options to customise the look and feel of how the Metafi wallet looks. Here you can pass in a custom logo, as well as theme styling options. More information can be found in the UI customisation section.
metafiSSO
Object
Specify options related to metafiSSO. Sample object:
metafiSSO.pwdRecoveryMeta?
Object
Optional. If you would like to self custody the cs share of your customers, Pass in URLs to store and retrieve the share when the user attempts to recover their wallet. If you do not pass in this field, Metafi will custody the cs shares for you.
Please note that if your service is down, users will not be able to recover their wallet on new devices.
(POST) storeSecretUrl
Request body:
metafiUserId (String)
share (String)
Response: 204 No Content
(GET) retrieveSecretUrl
Request body:
metafiUserId (String)
Response: 200 Ok
body:
share (String)
Return Value
N/A
Example
Last updated