You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Start with adding a CLI config --price-per-byte to ServerArgs.
The price is not stored in a database or subfile-specific at the moment. There may be a case where the bytes in a subfile is more valuable than another, then we can consider a more complex management.
Add a /cost endpoint that returns the price per byte for client/third-party price matching
When receiving paid queries, parse for receipts and condition on the receipt value where $\text{price per byte} * \text{bytes range} \leq \text{receipt value}$
Add a admin/cost endpoint for adjusting price_per_byte on the fly, taking a method set_price and a param price_per_byte to replace the previous price.
Additionally consider if indexer_framework can take care of cost models
The text was updated successfully, but these errors were encountered:
To add price matching in subfile exchanges,
Start with adding a CLI config
--price-per-byte
toServerArgs
.The price is not stored in a database or subfile-specific at the moment. There may be a case where the bytes in a subfile is more valuable than another, then we can consider a more complex management.
Add a
/cost
endpoint that returns the price per byte for client/third-party price matchingWhen receiving paid queries, parse for receipts and condition on the receipt value where$\text{price per byte} * \text{bytes range} \leq \text{receipt value}$
Add a
admin/cost
endpoint for adjusting price_per_byte on the fly, taking a methodset_price
and a paramprice_per_byte
to replace the previous price.Additionally consider if indexer_framework can take care of cost models
The text was updated successfully, but these errors were encountered: