For the complete documentation index, see llms.txt. This page is also available as Markdown.

User Information

This section covers the view functions for querying user account information.

users

Gets detailed information about a user's account.

function users(address account) external view returns (int256 balance, int256 incomeRate, int256 outgoingRate, uint256 updated)

Parameters

  • account (address): The user's address

Returns

  • balance (int256): The user's current balance

  • incomeRate (int256): The rate at which tokens are flowing into the account

  • outgoingRate (int256): The rate at which tokens are flowing out of the account

  • updated (uint256): The timestamp of the last update

Description

Returns comprehensive information about a user's account including their balance and streaming rates.

Example

// Get user information
const userInfo = await papayaContract.users("0xuser...");
console.log("Balance:", userInfo.balance.toString());
console.log("Income Rate:", userInfo.incomeRate.toString());
console.log("Outgoing Rate:", userInfo.outgoingRate.toString());
console.log("Last Updated:", userInfo.updated.toString());

balanceOf

Gets the balance of a specific account.

Parameters

  • account (address): The account address

Returns

  • balance (uint256): The account balance

Description

Returns the current balance of the specified account.

Example

bySigAccountNonces

Gets the account nonce for BySig operations.

Parameters

  • account (address): The account address

Returns

  • nonce (uint256): The current account nonce

Description

Returns the current nonce for BySig operations for a specific account.

Example

bySigSelectorNonces

Gets the selector nonce for BySig operations.

Parameters

  • account (address): The account address

  • selector (bytes4): The function selector

Returns

  • nonce (uint256): The current selector nonce

Description

Returns the current nonce for a specific function selector in BySig operations.

Example

bySigUniqueNonces

Checks if a unique nonce has been used.

Parameters

  • account (address): The account address

  • nonce (uint256): The unique nonce to check

Returns

  • used (bool): Whether the nonce has been used

Description

Returns whether a specific unique nonce has been used for BySig operations.

Example

bySigUniqueNoncesSlot

Gets the storage slot for a unique nonce.

Parameters

  • account (address): The account address

  • nonce (uint256): The unique nonce

Returns

  • slot (uint256): The storage slot for the nonce

Description

Returns the storage slot used for tracking a specific unique nonce.

Example

name

Gets the name of the token.

Returns

  • name (string): The token name

Description

Returns the name of the Papaya token.

Example

symbol

Gets the symbol of the token.

Returns

  • symbol (string): The token symbol

Description

Returns the symbol of the Papaya token.

Example

decimals

Gets the number of decimals for the token.

Returns

  • decimals (uint8): The number of decimals

Description

Returns the number of decimals used by the token.

Example

totalSupply

Gets the total supply of tokens.

Returns

  • totalSupply (uint256): The total token supply

Description

Returns the total supply of Papaya tokens.

Example

Last updated