docs.rs failed to build oil-api-0.0.1
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build:
oil-api-0.6.6
oil-api
API for interacting with the OIL protocol on Solana. OIL is a crypto mining protocol that allows users to deploy SOL to claim space on a board, mine OIL tokens, and stake for yield.
Features
- Instruction builders for all OIL protocol instructions
- State types and account deserialization for all program accounts
- PDA derivation utilities for deriving program-derived addresses
- SDK functions for common operations like deploying, claiming, and staking
- Type-safe instruction and state handling using
steelandbytemuck
Usage
Add to your Cargo.toml:
[]
= "0.0.1"
Example
use *;
use Pubkey;
// Derive a Driller PDA
let = driller_pda;
// Build a Deploy instruction
let deploy_ix = deploy;
// Build a ClaimOIL instruction
let claim_oil_ix = claim_oil;
// Build a Deposit instruction for staking
let deposit_ix = deposit;
Modules
Core Modules
consts- Program constants including addresses, time constants, and token decimalserror- Custom program error typesevent- Program event typesinstruction- Instruction types and builderssdk- High-level SDK functions for common operationsstate- Account state types and PDA derivation functions
State Accounts
Auction- Auction stateAutomation- Automation configurationBid- Auction bid accountBoard- Current round stateConfig- Global program configurationDriller- User drilling statePool- Mining pool stateAuctionPool- Auction pool stateReferral- Referral trackingRig- Rig configurationRound- Round-specific stateStake- Staking accountTreasury- Treasury accountWell- Well state
Instructions
Mining Instructions
deploy- Deploy SOL to claim space on the boardclaim_oil- Claim OIL drilling rewardsclaim_sol- Claim SOL drilling rewardscheckpoint- Checkpoint rewards from a prior roundautomate- Configure automationreload_sol- Reload SOL drilling rewards into automationreset- Reset the board for a new round
Auction Instructions
set_bid- Set a bid in the auctionjoin_auction_pool- Join an auction poolclaim_auction_oil- Claim OIL from auctionclaim_auction_sol- Claim SOL from auctionsync_auction_state- Sync auction state
Staking Instructions
deposit- Deposit OIL into a stake accountwithdraw- Withdraw OIL from a stake accountclaim_yield- Claim staking yield
Referral Instructions
create_referral- Create a referral accountclaim_referral- Claim referral rewards
Program ID
The OIL program ID is: rigUjJ7KTKNPXNjhwJwnzcJozMHFTtRUUoxX4wE2AqC
Documentation
Full API documentation is available at:
- docs.rs: https://docs.rs/oil-api
- Repository: https://github.com/regolith-labs/ore
Dependencies
This crate depends on:
entropy-rng-api- For entropy-based randomnessoil-mint-api- For OIL token minting operationssolana-program- Solana program SDKsteel- Solana instruction building frameworkspl-token- SPL token programspl-token-2022- SPL token 2022 program
License
Licensed under Apache-2.0
Related
- OIL Program - The on-chain Solana program
- OIL Protocol - Protocol website