Skip to content

Commit a620b5a

Browse files
authored
refactor(common,tap-agent): use tap-receipt header (#201)
Signed-off-by: Gustavo Inacio <[email protected]>
1 parent e154fd3 commit a620b5a

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ Ready to roll!
7272
7373
# Free query auth token check failed
7474
✗ curl -X POST -H 'Content-Type: application/json' -H 'Authorization: blah' --data '{"query": "{_meta{block{number}}}"}' http://localhost:7300/subgraphs/id/0xb655ca6f49e73728a102219726ff678d61d8fb792874792e9f0d9887dc616600
75-
"Invalid Scalar-Receipt header provided"%
75+
"Invalid Tap-Receipt header provided"%
7676
7777
# Subgraph health check
7878
✗ curl http://localhost:7300/subgraphs/health/QmVhiE4nax9i86UBnBmQCYDzvjWuwHShYh7aspGPQhU5Sj

common/src/indexer_errors.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -204,9 +204,9 @@ impl IndexerErrorCode {
204204
Self::IE026 => "Failed to deploy subgraph deployment",
205205
Self::IE027 => "Failed to remove subgraph deployment",
206206
Self::IE028 => "Failed to reassign subgraph deployment",
207-
Self::IE029 => "Invalid Scalar-Receipt header provided",
208-
Self::IE030 => "No Scalar-Receipt header provided",
209-
Self::IE031 => "Invalid Scalar-Receipt value provided",
207+
Self::IE029 => "Invalid Tap-Receipt header provided",
208+
Self::IE030 => "No Tap-Receipt header provided",
209+
Self::IE031 => "Invalid Tap-Receipt value provided",
210210
Self::IE032 => "Failed to process paid query",
211211
Self::IE033 => "Failed to process free query",
212212
Self::IE034 => "Not authorized as an operator for the indexer",

common/src/indexer_service/http/tap_receipt_header.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ impl Deref for TapReceipt {
2525
}
2626

2727
lazy_static! {
28-
static ref TAP_RECEIPT: HeaderName = HeaderName::from_static("scalar-receipt");
28+
static ref TAP_RECEIPT: HeaderName = HeaderName::from_static("tap-receipt");
2929
}
3030

3131
impl Header for TapReceipt {

tap-agent/src/agent/sender_account.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ pub enum SenderAccountMessage {
4949
/// A SenderAccount manages the receipts accounting between the indexer and the sender across
5050
/// multiple allocations.
5151
///
52-
/// Manages the lifecycle of Scalar TAP for the SenderAccount, including:
52+
/// Manages the lifecycle of TAP for the SenderAccount, including:
5353
/// - Monitoring new receipts and keeping track of the cumulative unaggregated fees across
5454
/// allocations.
5555
/// - Requesting RAVs from the sender's TAP aggregator once the cumulative unaggregated fees reach a

0 commit comments

Comments
 (0)