Skip to content

useEgressQuota

function useEgressQuota(props): UseQueryResult<DataSetStats, Error>;

Defined in: synapse-react/src/warm-storage/use-egress-quota.ts:36

Get the egress quota for a data set from FilBeam.

ParameterTypeDescription
propsUseEgressQuotaPropsThe props to use.

UseQueryResult<DataSetStats, Error>

The egress quota for the data set.

const { data: egressQuota, isLoading } = useEgressQuota({ dataSetId: 123n })
if (egressQuota) {
console.log(`CDN Egress: ${egressQuota.cdnEgressQuota}`)
console.log(`Cache Miss Egress: ${egressQuota.cacheMissEgressQuota}`)
}