Type alias RestResponseGetMarketMakerRewardsEpoch<RequestType>

Returns the detailed information about the requested epoch.


Type Parameters

See

Example

 // KatanaPerpsMarketMakerRewardsEpochDetailedWithWallet | KatanaPerpsMarketMakerRewardsEpochDetailedWithoutWallet
type Response = RestResponseGetEpoch;

// KatanaPerpsMarketMakerRewardsEpochDetailedWithWallet
const response = await client.getEpoch({ wallet: '0x...', nonce: '...', epochId: '...' });
// KatanaPerpsEpochDetailedWithoutWallet
const response = await client.getEpoch({ nonce: '...', epochId: '...' });
// KatanaPerpsMarketMakerRewardsEpochDetailedWithoutWallet | KatanaPerpsMarketMakerRewardsEpochDetailedWithWallet
const response = await client.getEpoch(someUntypedObj)

// When the response is returned as either, you can easily narrow the type
// by checking any of the wallet-specific properties:
if (response.walletScorePercent) {
// response satisfies KatanaPerpsMarketMakerRewardsEpochDetailedWithWallet
} else {
// response satisfies KatanaPerpsMarketMakerRewardsEpochDetailedWithoutWallet
}