Collection info
Retrieve fundamental details regarding the stake collection.
Parameter
Attribute | Description |
---|---|
stakeCollectionId | Your collection Id given by anvil |
Usage example
import { anvil } from "@ada-anvil/sdk-server";
try {
await anvil.staking.getStakeCollectionInfo({ stakeCollectionId: YOUR_COLLECTION_ID });
} catch {
console.log("YOUR ERROR HANDLING");
}
Return informations
Attribute | Description |
---|---|
id | Identification of the stake collection |
available | Indicates whether the stake collection is currently accessible |
policies | Lists the accepted policies for staking |
stakingPeriods | Specifies the allowed staking periods |
stakingPeriods[0].label | Describes the label for the staking period |
stakingPeriods[0].seconds | Indicates the duration of the staking period in seconds. If you wish to leave tokens unlocked, you can set this value to 1. |
maxPerTransaction | Denotes the maximum number of tokens that can be accepted per transaction, typically set at 50 |
minPerTransaction | Represents the minimum number of tokens accepted per transaction, which is usually set to null |
tokens | Lists of the accepted rewards tokens |