Othent
  • 👋Welcome to Othent
  • 🥪JS SDK
    • Getting Started
    • Events
    • Error Handling
    • Binary Data Types Utils
    • TypeScript Types
    • Config Constants
  • 🥪JS SDK API
    • constructor()
    • startTabSynching()
    • completeConnectionAfterRedirect()
    • connect()
    • disconnect()
    • requireAuth()
    • isAuthenticated
    • getActiveAddress()
    • getActivePublicKey()
    • getAllAddresses()
    • getWalletNames()
    • getUserDetails()
    • getSyncActiveAddress()
    • getSyncActivePublicKey()
    • getSyncAllAddresses()
    • getSyncWalletNames()
    • getSyncUserDetails()
    • sign() (transaction)
    • dispatch() (transaction)
    • encrypt()
    • decrypt()
    • signature()
    • signDataItem()
    • signMessage()
    • verifyMessage()
    • privateHash()
    • walletName
    • walletVersion
    • config
    • getArweaveConfig()
    • getPermissions()
  • Demos
    • 🍏SDK playground / demo
    • 🍏SDK playground / demo GitHub
    • 🍎File upload app example
    • 🍎File upload app example GitHub
  • 📚External libraries
    • arweave-js
    • Arweave Wallet Kit
  • Additional Links
    • 🌐Othent.io
    • 🌐Discord
    • 🌐GitHub
    • 🌐X
Powered by GitBook
On this page
  • API
  • Example usage
  1. JS SDK API

getPermissions()

ArConnect Injected API getPermissions() function

As discussed in connect()'s Permissions section, users using Othent are implicitly giving dApps that use Othent full control of their wallets.

Therefor, the getPermissions() function always returns an array with all possible permissions.

API

getPermissions(): Promise<PermissionType[]>;

Example usage

import { Othent } from "@othent/kms";

const othent = new Othent({ appInfo, throwErrors: false, ... });

const permissions = await othent.getPermissions();

console.log(`Othent has the following permissions = ${ permissions.join(", ") }`);
PreviousgetArweaveConfig()

Last updated 10 months ago

🥪