Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes estimated earnings and ad notifications are not updating for users #6758

Merged
merged 10 commits into from
Oct 5, 2020

Conversation

tmancey
Copy link
Collaborator

@tmancey tmancey commented Oct 2, 2020

Resolves brave/brave-browser#11952

Submitter Checklist:

Test Plan:

  • Confirm catalog is downloaded upon browser launch
  • Confirm catalog is downloaded every ~2 hours
  • Confirm catalog download is not started if currently retrying a previously failed download
  • Confirm unblinded payment tokens are redeemed ~24 hours
  • Confirm unblinded payment tokens redemption is not started if currently retrying a previously failed download
  • Confirm unblinded tokens are refilled if we have less than 10 unblinded tokens when triggering an event to server an ad notification (use Charles Proxy to rewrite the response status code to 404 NOT FOUND for POST /v1/confirmation/token/{payment_id} endpoint)
  • Confirm failed confirmations are retried after attempting to download the catalog
  • Confirm failed confirmations are retried when an unblinded token redemption fails
  • Confirm unblinded tokens are refilled to 50 if we are below the threshold after attempting to download the catalog
  • Confirm unblinded tokens are refilled to 50 if we are below the threshold after redeeming an unblinded token
  • Confirm ad rewards are reconciled upon browser launch
  • Confirm ad rewards are reconciled after restoring a wallet
  • Confirm ad rewards are reconciled after redeeming unblinded payment tokens
  • Confirm ad rewards are reconciled after claiming an ad promotion
  • Confirm unblinded payment tokens redemption is not started if currently retrying a previously failed download

Reviewer Checklist:

  • New files have MPL-2.0 license header.
  • Request a security/privacy review as needed.
  • Adequate test coverage exists to prevent regressions
  • Verify test plan is specified in PR before merging to source

After-merge Checklist:

  • The associated issue milestone is set to the smallest version that the
    changes has landed on.
  • All relevant documentation has been updated.

@tmancey tmancey self-assigned this Oct 2, 2020
@tmancey tmancey force-pushed the issues/11952 branch 4 times, most recently from 00d25c9 to a6fcb01 Compare October 2, 2020 14:03
@tmancey tmancey marked this pull request as ready for review October 2, 2020 15:10
@tmancey tmancey requested a review from kylehickinson as a code owner October 2, 2020 15:10
@tmancey tmancey requested a review from yachtcaptain23 October 2, 2020 15:11
Copy link
Contributor

@emerick emerick left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just had one comment

Copy link
Collaborator

@kylehickinson kylehickinson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

iOS lgtm 🙂 Just needs a small change on brave-ios to rename the updateAdRewards method to reconcileAdRewards

Copy link
Contributor

@moritzhaller moritzhaller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

Copy link
Contributor

@NejcZdovc NejcZdovc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rewards code looks good

@tmancey tmancey force-pushed the issues/11952 branch 2 times, most recently from 1757aaa to 9057d56 Compare October 5, 2020 10:16
@tmancey tmancey force-pushed the issues/11952 branch 2 times, most recently from 4b5ab90 to ac60287 Compare October 5, 2020 11:28
@tmancey tmancey merged commit deea636 into master Oct 5, 2020
@tmancey tmancey deleted the issues/11952 branch October 5, 2020 15:31
@tmancey tmancey added this to the 1.17.x - Nightly milestone Oct 5, 2020
tmancey added a commit that referenced this pull request Oct 5, 2020
Fixes estimated earnings and Ad notifications are not updating for users
tmancey added a commit that referenced this pull request Oct 5, 2020
Fixes estimated earnings and ad notifications are not updating for users
@LaurenWags
Copy link
Member

LaurenWags commented Oct 8, 2020

Using the below build:

Brave	1.17.22 Chromium: 86.0.4240.75 (Official Build) nightly (x86_64)
Revision	c69c33933bfc72a159aceb4aeca939eb0087416c-refs/branch-heads/4240@{#1149}
OS	macOS Version 10.14.6 (Build 18G3020)

Verified the following scenarios on Nightly:

Confirm unblinded tokens are refilled if we have less than 10 unblinded tokens when triggering an event to server an ad notification
Confirm failed confirmations are retried after attempting to download the catalog
Confirm failed confirmations are retried when an unblinded token redemption fails
Confirm unblinded tokens are refilled to 50 if we are below the threshold after attempting to download the catalog
Confirm unblinded tokens are refilled to 50 if we are below the threshold after redeeming an unblinded token

See below for details

Confirm unblinded tokens are refilled if we have less than 10 unblinded tokens when triggering an event to server an ad notification
[9028:775:1008/121300.124661:VERBOSE2:ads_impl.cc(1177)] You do not have enough unblinded tokens
[9028:775:1008/121300.124729:VERBOSE1:ads_impl.cc(878)] Ad notification not shown: Not allowed based on history
  • Verified tokens were refilled once rewrite was turned off:
[9074:775:1008/121715.534207:VERBOSE1:ads_impl.cc(1506)] Retry refilling unblinded tokens
[9074:775:1008/121715.534374:VERBOSE1:refill_unblinded_tokens.cc(154)] GetSignedTokens
[9074:775:1008/121715.534456:VERBOSE2:refill_unblinded_tokens.cc(155)] GET /v1/confirmation/token/{payment_id}?nonce={nonce}
[9074:775:1008/121715.534531:VERBOSE5:refill_unblinded_tokens.cc(159)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/6c1c2f52-5c4f-4009-a349-87fd5a56df36?nonce=5c22a351-c7e2-43a1-9b88-480fd2a7503c
  Method: BraveAdsUrlRequestMethod::GET
[9074:775:1008/121715.656387:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/token/6c1c2f52-5c4f-4009-a349-87fd5a56df36?nonce=5c22a351-c7e2-43a1-9b88-480fd2a7503c
[9074:775:1008/121715.656724:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/token/6c1c2f52-5c4f-4009-a349-87fd5a56df36?nonce=5c22a351-c7e2-43a1-9b88-480fd2a7503c
[9074:775:1008/121715.657101:VERBOSE1:refill_unblinded_tokens.cc(169)] OnGetSignedTokens
[9074:775:1008/121715.657181:VERBOSE6:refill_unblinded_tokens.cc(171)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/6c1c2f52-5c4f-4009-a349-87fd5a56df36?nonce=5c22a351-c7e2-43a1-9b88-480fd2a7503c
  Response Status Code: 200
  Response: {"batchProof":"Gnb4lnQBsMNlmvZFhSaRkgTILldPNqK/UMx8586xcgVkzM+HH8xW2QoiTIcNbP8uPZI5dVwFGEO3SdNKqHm6CA==","signedTokens":["5vQgBLbM+Yh8cqaV09ipvSlwk/F5I9Wuyua6ua5b/EU=","lCojl2Q2XhJcTFf0KXHuqlbxC2DnnteucI+0CizcCxE=","NhenyeBYOxoJr3chNcC3jscJfFxquuAvc6eGLtR1fzM=","8J036weGNbKpI3LGpb5kFh5uQDBZa+XQipx9TKpE+BM=","nlXotvSuga9cwd209gRFAy+wOyvES98XQxaqb0iLMm4=","SG7R4B/XCRQYB2QYANY4g+yCO0lBPpTC1sAKM5Cb9xQ=","aF193Qgmijm8ME8b4aZBi3SPlfz+FeyQmccd/elq6WI=","fG5qIsk8ccY4CNu4BZ3abRU4XysRiVwYR8hnuqaCDz0=","CrkH+Rtox4W2j9O/Zn8FcfEjXGsGLo6QHPXMJYH+8X8=","3Lwol+wCIT+fLlt6XQE6gzUYFJl3/qHtGOCa3X8PxDg=","SGlNPSLLms9bWquoxAGfo+R6Plqm8nFJN84+7zwMaWU=","3Il+5UP0+C/VOrGr/L/3BVACpSkfW4nD8F/TSkHlBTk=","0lbIac1UhtZiRDba4rr5Z2/LtBBop1hORG4xRb+reH8=","Estdzdue1jbOS9fxUz43beikxuSourZ50hn+Ed0Jl24=","srOadBzoitLQ33+Dc9DuPr/WRfSgakg04dECMbPcl3U=","fiVubcBBH8wuoStjIv2NJfBPdkv/7mF+VF9z1p5bm1w=","spzatjHQJp+O14AexL9GLzvpehayiGpXxuAWuKBTB3Q=","dulJiDP57TqqR+jo55UBlGkcd2gXIWnSgm3Bu1Mz/lU=","gkVRXxb8a/P1cJEpSdxOgDLf3mAWqLxhASkezmmcnSM=","klgXW7Ts/xbXI25SpyQ7DPdg5uCGY8wGZ8fGidCUwgw=","bplb+5k6LlKG7ByFJ03K0VKv45BQ3M3n9388lhBczn8=","uKkEPM+EIpNMtUMtUDye7/v5K+spnKAkr1f6lWEcBQ0=","hCKkM3pdt9BO/3GhRuOA+Q3hJr59dwUmkM3vRC6S4xM=","WhQ+uWjZbuy2tAXeQ7Ga9ndX4RO+TvXE3zsMrFp0oTg=","rtY7F5WZ+OFyBD7DlhB4Xu9rzE6bnlpwPPp+z0b10Es=","mPHub+b7brvgwhLqIEJ4sy4hQvAO+1G7kBNz2MxV4zY=","VnXQlkFpwNQU7OhKTagrPVS9zRhtyyQy7T02glMfsQE=","hk/+zlrPQjBLcpuEmudJLi+cx4od1S5vGr40Whde3mU=","Ktp+JFhXbe6k0ATY+3hcXr/QyVzga8t77hwun7MYc1s=","SgEAConoubaZAj58S4Gum/oEJkTz35CKDdyLQ+hzBk4=","uDSEoTymfCpmNXV++xjyolgedTb+/hKP4JIepsjEwWw=","eLDSffYNd8pPFG8eFl7hQsJ/ylFi2qBc0uaY6ax0KAs=","djuitPri9EVr3rR3LnBPr4Iaxwd8hJtvVRo4kbbhU2A=","QDnHohEW6Y35te+/yTsCUWXFHYBxdZzdiYZ7ZlpIFnU=","ABQm/gdv7x3+rd5HSNBUuvrA6miY4Csq1o6CTBQBeAU=","whx4EyQ5iXd3VqMjK6o3BRb695jaVzJMLhISJMtKSUg=","WA0R4+r4TI6/Kf/YQa3iIGQ0bAMjJTR7+8w1NJsx2FA=","kjzXVExrSMdlj4u7OprCuxJgoXOgyuTkbyDSwUvN3gA=","yLwozEfHFtxtnAz0x7GewGubQzYKWwaCP0U+UGz5AQ0=","5Fsf2UN9ApDDdgEK0ibz3QyeRVFimfbkrq5Vg0SACEU=","xpsHBkf6tpDE3nUmHpl6fcCv1ssH7Dtv4chBr5zszwA="],"publicKey":"crDVI1R6xHQZ4D9cQu4muVM5MaaM1QcOT4It8Y/CYlw="}
[9074:775:1008/121715.668031:VERBOSE1:refill_unblinded_tokens.cc(266)] Added 41 unblinded tokens, you now have 50 unblinded tokens
[9074:775:1008/121715.668867:VERBOSE1:ads_impl.cc(1498)] Successfully refilled unblinded tokens
  • Verified that after unblinded tokens are refilled, ads are shown
Confirm failed confirmations are retried after attempting to download the catalog

Viewed an ad, enabled Charles re-write rule to make confirmation fail, then dismissed the ad to create a failed confirmation:

[9224:775:1008/132543.209700:VERBOSE1:redeem_unblinded_token.cc(143)] FetchPaymentToken
[9224:775:1008/132543.209734:VERBOSE2:redeem_unblinded_token.cc(144)] GET /v1/confirmation/{confirmation_id}/paymentToken
[9224:775:1008/132543.209767:VERBOSE5:redeem_unblinded_token.cc(148)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/a5fb0a40-e886-425b-b3f2-6769e59e4067/paymentToken
  Method: BraveAdsUrlRequestMethod::GET
[9224:775:1008/132543.353462:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/a5fb0a40-e886-425b-b3f2-6769e59e4067/paymentToken
[9224:775:1008/132543.353776:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/a5fb0a40-e886-425b-b3f2-6769e59e4067/paymentToken
[9224:775:1008/132543.354090:VERBOSE1:redeem_unblinded_token.cc(159)] OnFetchPaymentToken
[9224:775:1008/132543.354176:VERBOSE6:redeem_unblinded_token.cc(161)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/a5fb0a40-e886-425b-b3f2-6769e59e4067/paymentToken
  Response Status Code: 404
  Response: {"id":"a5fb0a40-e886-425b-b3f2-6769e59e4067","createdAt":"2020-10-08T17:25:43.087Z","type":"dismiss","modifiedAt":"2020-10-08T17:25:43.122Z","creativeInstanceId":"0ae3c486-13f2-4ec7-9376-5578d7b0dcd8","paymentToken":{"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=","batchProof":"lZ61CRNMVB18YsHvzqjXj3P+dWOpcm/jsTCS44BDRwT7yKEsnmPSNshV3lqil4tg8J5/IhW3iGZGoupy0PqxDw==","signedTokens":["oNH6/+Uxk2AWs8Dk4ilSytYu28Mff4m3hDVZ6MqIEwI="]}}
[9224:775:1008/132543.354267:VERBOSE1:redeem_unblinded_token.cc(165)] Confirmation not found
[9224:775:1008/132543.354321:VERBOSE1:ads_impl.cc(1480)] Failed to redeem unblinded token with confirmation id a5fb0a40-e886-425b-b3f2-6769e59e4067, creative instance id 0ae3c486-13f2-4ec7-9376-5578d7b0dcd8 and dismiss
[9224:775:1008/132543.355946:VERBOSE1:confirmations.cc(168)] Added confirmation id ef5020ec-163f-453d-98c7-23e97e841ef4, creative instance id 0ae3c486-13f2-4ec7-9376-5578d7b0dcd8 and dismiss to the confirmations queue
[9224:775:1008/132543.356003:VERBOSE1:refill_unblinded_tokens.cc(64)] No need to refill unblinded tokens as we already have 47 unblinded tokens which is above the minimum threshold of 20

Closed browser, disabled rewrite rule, relaunched browser. Confirmed after catalog was downloaded, the failed confirmations for retry were scheduled:

[9275:775:1008/132743.046466:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v4/catalog
[9275:775:1008/132743.046763:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v4/catalog
[9275:775:1008/132743.047624:VERBOSE1:get_catalog.cc(83)] Successfully downloaded catalog
[9275:775:1008/132743.047677:VERBOSE1:get_catalog.cc(112)] Parsing catalog
[9275:775:1008/132743.050587:VERBOSE1:get_catalog.cc(130)] Generating bundle
[9275:775:1008/132743.050648:VERBOSE1:bundle.cc(208)] creative set id 7be431a0-c6e4-4ca6-bcac-672e77294b7d has no entries
[9275:775:1008/132743.050687:VERBOSE1:bundle.cc(208)] creative set id 486d1bbe-e460-474e-ac26-d554cb1a21d4 has no entries
[9275:775:1008/132743.051384:VERBOSE1:bundle.cc(208)] creative set id 175bc3ca-50f0-4749-bfc8-c7ff7482de0f has no entries
[9275:775:1008/132743.051449:VERBOSE1:bundle.cc(208)] creative set id 2b67d6ee-e6d1-4d4e-a1b9-6be11a60c11d has no entries
[9275:775:1008/132743.055064:VERBOSE1:get_catalog.cc(138)] Successfully generated bundle
[9275:775:1008/132743.055148:VERBOSE1:confirmations.cc(50)] SetCatalogIssuers:
[9275:775:1008/132743.055184:VERBOSE1:confirmations.cc(51)]   Public key: crDVI1R6xHQZ4D9cQu4muVM5MaaM1QcOT4It8Y/CYlw=
[9275:775:1008/132743.055220:VERBOSE1:confirmations.cc(52)]   Issuers:
[9275:775:1008/132743.055251:VERBOSE1:confirmations.cc(55)]     Name: 0.01BAT
[9275:775:1008/132743.055282:VERBOSE1:confirmations.cc(56)]     Public key: JiwFR2EU/Adf1lgox+xqOVPuc6a/rxdy/LguFG5eaXg=
[9275:775:1008/132743.055316:VERBOSE1:confirmations.cc(55)]     Name: 0.025BAT
[9275:775:1008/132743.055346:VERBOSE1:confirmations.cc(56)]     Public key: CrQLMWmUuYog6Q93nScS8Lo1HHSex8WM2Qxij7qhjkQ=
[9275:775:1008/132743.055377:VERBOSE1:confirmations.cc(55)]     Name: 0.15BAT
[9275:775:1008/132743.055409:VERBOSE1:confirmations.cc(56)]     Public key: iJcG3AkH1sgl+5YCZuo+4Q/7aeBOnYyntkIUXeMbDCs=
[9275:775:1008/132743.055439:VERBOSE1:confirmations.cc(55)]     Name: 0.20BAT
[9275:775:1008/132743.055490:VERBOSE1:confirmations.cc(56)]     Public key: VihGXGoiQ5Fjxe4SrskIVMcmERa1LoAgvhFxxfLmNEI=
[9275:775:1008/132743.055553:VERBOSE1:confirmations.cc(55)]     Name: 0.3BAT
[9275:775:1008/132743.055591:VERBOSE1:confirmations.cc(56)]     Public key: 6DBiZUS47m8eb5ohI2MiRaERLzS4DQgMp4nxPLKAenA=
[9275:775:1008/132743.055624:VERBOSE1:confirmations.cc(55)]     Name: 0.25BAT
[9275:775:1008/132743.055656:VERBOSE1:confirmations.cc(56)]     Public key: YOIEGq4joK7rtkWdcNdNNGT5xlU/KIrri4AX19qwZW4=
[9275:775:1008/132743.055687:VERBOSE1:confirmations.cc(55)]     Name: 0BAT
[9275:775:1008/132743.055738:VERBOSE1:confirmations.cc(56)]     Public key: lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=
[9275:775:1008/132743.055770:VERBOSE1:confirmations.cc(55)]     Name: 0.05BAT
[9275:775:1008/132743.055800:VERBOSE1:confirmations.cc(56)]     Public key: bPE1QE65mkIgytffeu7STOfly+x10BXCGuk5pVlOHQU=
[9275:775:1008/132743.055830:VERBOSE1:confirmations.cc(55)]     Name: 0.10BAT
[9275:775:1008/132743.055860:VERBOSE1:confirmations.cc(56)]     Public key: aDD4SJmIj2xwdA6D00K1dopTg90oOFpwd2iiK8bqqlQ=
[9275:775:1008/132743.055955:VERBOSE1:refill_unblinded_tokens.cc(64)] No need to refill unblinded tokens as we already have 47 unblinded tokens which is above the minimum threshold of 20
[9275:775:1008/132743.055994:VERBOSE1:confirmations.cc(138)] Retry failed confirmations in 0 hours, 2 minutes, 3 seconds at 1:29 PM

Confirmed at expected time (0 hours, 2 minutes, 3 seconds at 1:29 PM) from logs, the failed confirmation was retried successfully:

[9275:775:1008/132946.055875:VERBOSE1:confirmations.cc(223)] Removed confirmation id ef5020ec-163f-453d-98c7-23e97e841ef4, creative instance id 0ae3c486-13f2-4ec7-9376-5578d7b0dcd8 and dismiss from the confirmations queue
[9275:775:1008/132946.056606:VERBOSE1:redeem_unblinded_token.cc(88)] Redeem token
[9275:775:1008/132946.056663:VERBOSE1:redeem_unblinded_token.cc(103)] CreateConfirmation
[9275:775:1008/132946.056702:VERBOSE2:redeem_unblinded_token.cc(104)] POST /v1/confirmation/{confirmation_id}/{credential}
[9275:775:1008/132946.056738:VERBOSE5:redeem_unblinded_token.cc(108)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwibmlhNWdPK2FTUG5pNEI3MDdjNFp2bk5ScjdtNzdtQUlJd0YwbE1Nbll3cz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCIwYWUzYzQ4Ni0xM2YyLTRlYzctOTM3Ni01NTc4ZDdiMGRjZDhcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6Ik1mTzdQRE41aldKQW1Vak1uUXJDWkdNTUZKT2lEM2oxMVdZY0dubmcyeVJTc1VwUDU3b25HMHZIaHhaYkU0ekVpTG1WbitJL3R5ck54VkhmZWhUaEVBPT0iLCJ0IjoiWW1iQ0NSMWZHMUV0bFJaRUF2SGhHZHQxR3VGVGFseDNTWTlmR3kwTVp6NGc0VnhVZXNZcCtMN1F0R2swMmp1b0RXZ0xpSWtlY3Z4WDNDWE9MblRzR2c9PSJ9
  Content: {"blindedPaymentToken":"nia5gO+aSPni4B707c4ZvnNRr7m77mAIIwF0lMMnYws=","buildChannel":"nightly","creativeInstanceId":"0ae3c486-13f2-4ec7-9376-5578d7b0dcd8","payload":{},"platform":"macos","type":"dismiss"}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9275:775:1008/132946.057205:VERBOSE1:confirmations.cc(138)] Retry failed confirmations in 0 hours, 8 minutes, 39 seconds at 1:38 PM
[9275:775:1008/132946.464296:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwibmlhNWdPK2FTUG5pNEI3MDdjNFp2bk5ScjdtNzdtQUlJd0YwbE1Nbll3cz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCIwYWUzYzQ4Ni0xM2YyLTRlYzctOTM3Ni01NTc4ZDdiMGRjZDhcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6Ik1mTzdQRE41aldKQW1Vak1uUXJDWkdNTUZKT2lEM2oxMVdZY0dubmcyeVJTc1VwUDU3b25HMHZIaHhaYkU0ekVpTG1WbitJL3R5ck54VkhmZWhUaEVBPT0iLCJ0IjoiWW1iQ0NSMWZHMUV0bFJaRUF2SGhHZHQxR3VGVGFseDNTWTlmR3kwTVp6NGc0VnhVZXNZcCtMN1F0R2swMmp1b0RXZ0xpSWtlY3Z4WDNDWE9MblRzR2c9PSJ9
[9275:775:1008/132946.464472:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwibmlhNWdPK2FTUG5pNEI3MDdjNFp2bk5ScjdtNzdtQUlJd0YwbE1Nbll3cz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCIwYWUzYzQ4Ni0xM2YyLTRlYzctOTM3Ni01NTc4ZDdiMGRjZDhcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6Ik1mTzdQRE41aldKQW1Vak1uUXJDWkdNTUZKT2lEM2oxMVdZY0dubmcyeVJTc1VwUDU3b25HMHZIaHhaYkU0ekVpTG1WbitJL3R5ck54VkhmZWhUaEVBPT0iLCJ0IjoiWW1iQ0NSMWZHMUV0bFJaRUF2SGhHZHQxR3VGVGFseDNTWTlmR3kwTVp6NGc0VnhVZXNZcCtMN1F0R2swMmp1b0RXZ0xpSWtlY3Z4WDNDWE9MblRzR2c9PSJ9
[9275:775:1008/132946.464720:VERBOSE1:redeem_unblinded_token.cc(121)] OnCreateConfirmation
[9275:775:1008/132946.464770:VERBOSE6:redeem_unblinded_token.cc(123)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwibmlhNWdPK2FTUG5pNEI3MDdjNFp2bk5ScjdtNzdtQUlJd0YwbE1Nbll3cz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCIwYWUzYzQ4Ni0xM2YyLTRlYzctOTM3Ni01NTc4ZDdiMGRjZDhcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6Ik1mTzdQRE41aldKQW1Vak1uUXJDWkdNTUZKT2lEM2oxMVdZY0dubmcyeVJTc1VwUDU3b25HMHZIaHhaYkU0ekVpTG1WbitJL3R5ck54VkhmZWhUaEVBPT0iLCJ0IjoiWW1iQ0NSMWZHMUV0bFJaRUF2SGhHZHQxR3VGVGFseDNTWTlmR3kwTVp6NGc0VnhVZXNZcCtMN1F0R2swMmp1b0RXZ0xpSWtlY3Z4WDNDWE9MblRzR2c9PSJ9
  Response Status Code: 201
  Response: {"id":"ef5020ec-163f-453d-98c7-23e97e841ef4","payload":{},"createdAt":"2020-10-08T17:29:46.341Z","type":"dismiss","modifiedAt":"2020-10-08T17:29:46.341Z","creativeInstanceId":"0ae3c486-13f2-4ec7-9376-5578d7b0dcd8"}
[9275:775:1008/132946.464819:VERBOSE1:redeem_unblinded_token.cc(143)] FetchPaymentToken
[9275:775:1008/132946.464844:VERBOSE2:redeem_unblinded_token.cc(144)] GET /v1/confirmation/{confirmation_id}/paymentToken
[9275:775:1008/132946.464869:VERBOSE5:redeem_unblinded_token.cc(148)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/paymentToken
  Method: BraveAdsUrlRequestMethod::GET
[9275:775:1008/132946.824201:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/paymentToken
[9275:775:1008/132946.824395:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/paymentToken
[9275:775:1008/132946.824647:VERBOSE1:redeem_unblinded_token.cc(159)] OnFetchPaymentToken
[9275:775:1008/132946.824699:VERBOSE6:redeem_unblinded_token.cc(161)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/ef5020ec-163f-453d-98c7-23e97e841ef4/paymentToken
  Response Status Code: 200
  Response: {"id":"ef5020ec-163f-453d-98c7-23e97e841ef4","createdAt":"2020-10-08T17:29:46.341Z","type":"dismiss","modifiedAt":"2020-10-08T17:29:46.371Z","creativeInstanceId":"0ae3c486-13f2-4ec7-9376-5578d7b0dcd8","paymentToken":{"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=","batchProof":"CDmu6Lp/j9vt98G4addcv3Ad3ruN+Zar47DPzik6EASMMeSgOoJ2q5SbzzbcmXZ89sa7K5L/eQfYurdm+WjBDg==","signedTokens":["5s1fDJydIfaqK6zRMe+xlR1imf0QNR/lTQPfNgxJNFU="]}}
[9275:775:1008/132946.825842:VERBOSE1:redeem_unblinded_token.cc(335)] Added 1 unblinded payment token with an estimated redemption value of 0 BAT, you now have 2 unblinded payment tokens
[9275:775:1008/132946.826321:VERBOSE1:ads_impl.cc(1472)] Successfully redeemed unblinded token with confirmation id ef5020ec-163f-453d-98c7-23e97e841ef4, creative instance id 0ae3c486-13f2-4ec7-9376-5578d7b0dcd8 and dismiss
Confirm failed confirmations are retried when an unblinded token redemption fails

Viewed an ad, enabled Charles re-write rule to make confirmation fail, then dismissed the ad to create a failed confirmation:

[9124:775:1008/123147.978644:VERBOSE1:redeem_unblinded_token.cc(121)] OnCreateConfirmation
[9124:775:1008/123147.978706:VERBOSE6:redeem_unblinded_token.cc(123)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/eabdad53-df0a-49ed-93a6-2e29037a05ed/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiMGprdzNQeUtYZllzOU9mb3ExUXR1MXNSNmllc2ZHbW9ON0NxWVdHM1p6cz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6IkVVWGo3M3FyNEZpWlBDZ1FWRFNpcFFHTnpYVmRhc2tWaWV5ejJvV3dGTVZCTXVDeW5mMENVZzF0aG9PcmFUd3AzTW0vQTROQjFidXBHa1BXOE1aWWxnPT0iLCJ0IjoiMXNKbmV6UHllYXFIY1dOWkZpMHlJTTYwaFBKUmRRTmtQOERxai9lVzRoRzdtc0pWM2hidjlseDZ3bG9KMjhtckhBWi9MaXEwenNyQ1l6MFo1N254VXc9PSJ9
  Response Status Code: 201
  Response: {"id":"eabdad53-df0a-49ed-93a6-2e29037a05ed","payload":{},"createdAt":"2020-10-08T16:31:47.849Z","type":"dismiss","modifiedAt":"2020-10-08T16:31:47.849Z","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e"}
[9124:775:1008/123147.978768:VERBOSE1:redeem_unblinded_token.cc(143)] FetchPaymentToken
[9124:775:1008/123147.978800:VERBOSE2:redeem_unblinded_token.cc(144)] GET /v1/confirmation/{confirmation_id}/paymentToken
[9124:775:1008/123147.978832:VERBOSE5:redeem_unblinded_token.cc(148)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/eabdad53-df0a-49ed-93a6-2e29037a05ed/paymentToken
  Method: BraveAdsUrlRequestMethod::GET
[9124:775:1008/123148.128580:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/eabdad53-df0a-49ed-93a6-2e29037a05ed/paymentToken
[9124:775:1008/123148.128913:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/eabdad53-df0a-49ed-93a6-2e29037a05ed/paymentToken
[9124:775:1008/123148.129160:VERBOSE1:redeem_unblinded_token.cc(159)] OnFetchPaymentToken
[9124:775:1008/123148.129232:VERBOSE6:redeem_unblinded_token.cc(161)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/eabdad53-df0a-49ed-93a6-2e29037a05ed/paymentToken
  Response Status Code: 404
  Response: {"id":"eabdad53-df0a-49ed-93a6-2e29037a05ed","createdAt":"2020-10-08T16:31:47.849Z","type":"dismiss","modifiedAt":"2020-10-08T16:31:47.884Z","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e","paymentToken":{"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=","batchProof":"4OdDxyux6ekjD8q5Z5dXeUC96Hmm15TiifeO+Qwg/Q8a8HYdR9+xDLc1hlVgweFwPMoT4TisPVdecqAdJtcODw==","signedTokens":["NNuGp0YUM/Iw1/MZktL3VXIz84ML2vXApC4v9htExAI="]}}
[9124:775:1008/123148.129296:VERBOSE1:redeem_unblinded_token.cc(165)] Confirmation not found
[9124:775:1008/123148.129332:VERBOSE1:ads_impl.cc(1480)] Failed to redeem unblinded token with confirmation id eabdad53-df0a-49ed-93a6-2e29037a05ed, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss
[9124:775:1008/123148.130724:VERBOSE1:confirmations.cc(168)] Added confirmation id fc9ff690-0f21-4260-843c-02f40b0a4dd2, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss to the confirmations queue
[9124:775:1008/123148.130777:VERBOSE1:refill_unblinded_tokens.cc(64)] No need to refill unblinded tokens as we already have 47 unblinded tokens which is above the minimum threshold of 20
[9124:775:1008/123247.206784:VERBOSE1:confirmations.cc(223)] Removed confirmation id fc9ff690-0f21-4260-843c-02f40b0a4dd2, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss from the confirmations queue
[9124:775:1008/123247.207452:VERBOSE1:redeem_unblinded_token.cc(88)] Redeem token
[9124:775:1008/123247.207551:VERBOSE1:redeem_unblinded_token.cc(103)] CreateConfirmation
[9124:775:1008/123247.207599:VERBOSE2:redeem_unblinded_token.cc(104)] POST /v1/confirmation/{confirmation_id}/{credential}
[9124:775:1008/123247.207643:VERBOSE5:redeem_unblinded_token.cc(108)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiYUZiZ2NENzRJb0hLZHRWd2grZldlaFN1T3hmUEpJS0w1SjBiV0x3bDluRT1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImFQanZsbnpjR3o3U0dBL0swVXBxZXExR3dsOFlJcVRrMFNrSE0wODVWaWhRTGFDVXo4T3V4TVBZMnpaTnZMUlUzdExIbjk5UHJKcW1QdVdhWXQvV2VRPT0iLCJ0IjoidmpGdHBSOHdPcU5HQVFaVnowdzlwdVZEZ2xMdzYyWFNMMGRWQXlHeWNONXZqMWZoN1VBa25KNmZzWmQ5cTgzMFFVd1gxVzJVSXcrOUU0V3dXRWFYbFE9PSJ9
  Content: {"blindedPaymentToken":"aFbgcD74IoHKdtVwh+fWehSuOxfPJIKL5J0bWLwl9nE=","buildChannel":"nightly","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e","payload":{},"platform":"macos","type":"dismiss"}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9124:775:1008/123247.208198:VERBOSE1:confirmations.cc(138)] Retry failed confirmations in 0 hours, 2 minutes, 55 seconds at 12:35 PM
[9124:775:1008/123247.411936:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiYUZiZ2NENzRJb0hLZHRWd2grZldlaFN1T3hmUEpJS0w1SjBiV0x3bDluRT1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImFQanZsbnpjR3o3U0dBL0swVXBxZXExR3dsOFlJcVRrMFNrSE0wODVWaWhRTGFDVXo4T3V4TVBZMnpaTnZMUlUzdExIbjk5UHJKcW1QdVdhWXQvV2VRPT0iLCJ0IjoidmpGdHBSOHdPcU5HQVFaVnowdzlwdVZEZ2xMdzYyWFNMMGRWQXlHeWNONXZqMWZoN1VBa25KNmZzWmQ5cTgzMFFVd1gxVzJVSXcrOUU0V3dXRWFYbFE9PSJ9
[9124:775:1008/123247.412221:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiYUZiZ2NENzRJb0hLZHRWd2grZldlaFN1T3hmUEpJS0w1SjBiV0x3bDluRT1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImFQanZsbnpjR3o3U0dBL0swVXBxZXExR3dsOFlJcVRrMFNrSE0wODVWaWhRTGFDVXo4T3V4TVBZMnpaTnZMUlUzdExIbjk5UHJKcW1QdVdhWXQvV2VRPT0iLCJ0IjoidmpGdHBSOHdPcU5HQVFaVnowdzlwdVZEZ2xMdzYyWFNMMGRWQXlHeWNONXZqMWZoN1VBa25KNmZzWmQ5cTgzMFFVd1gxVzJVSXcrOUU0V3dXRWFYbFE9PSJ9
[9124:775:1008/123247.412517:VERBOSE1:redeem_unblinded_token.cc(121)] OnCreateConfirmation
[9124:775:1008/123247.412584:VERBOSE6:redeem_unblinded_token.cc(123)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiYUZiZ2NENzRJb0hLZHRWd2grZldlaFN1T3hmUEpJS0w1SjBiV0x3bDluRT1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImFQanZsbnpjR3o3U0dBL0swVXBxZXExR3dsOFlJcVRrMFNrSE0wODVWaWhRTGFDVXo4T3V4TVBZMnpaTnZMUlUzdExIbjk5UHJKcW1QdVdhWXQvV2VRPT0iLCJ0IjoidmpGdHBSOHdPcU5HQVFaVnowdzlwdVZEZ2xMdzYyWFNMMGRWQXlHeWNONXZqMWZoN1VBa25KNmZzWmQ5cTgzMFFVd1gxVzJVSXcrOUU0V3dXRWFYbFE9PSJ9
  Response Status Code: 201
  Response: {"id":"fc9ff690-0f21-4260-843c-02f40b0a4dd2","payload":{},"createdAt":"2020-10-08T16:32:47.293Z","type":"dismiss","modifiedAt":"2020-10-08T16:32:47.293Z","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e"}
[9124:775:1008/123247.412649:VERBOSE1:redeem_unblinded_token.cc(143)] FetchPaymentToken
[9124:775:1008/123247.412684:VERBOSE2:redeem_unblinded_token.cc(144)] GET /v1/confirmation/{confirmation_id}/paymentToken
[9124:775:1008/123247.412718:VERBOSE5:redeem_unblinded_token.cc(148)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/paymentToken
  Method: BraveAdsUrlRequestMethod::GET
[9124:775:1008/123247.556490:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/paymentToken
[9124:775:1008/123247.556882:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/paymentToken
[9124:775:1008/123247.557173:VERBOSE1:redeem_unblinded_token.cc(159)] OnFetchPaymentToken
[9124:775:1008/123247.557239:VERBOSE6:redeem_unblinded_token.cc(161)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/fc9ff690-0f21-4260-843c-02f40b0a4dd2/paymentToken
  Response Status Code: 404
  Response: {"id":"fc9ff690-0f21-4260-843c-02f40b0a4dd2","createdAt":"2020-10-08T16:32:47.293Z","type":"dismiss","modifiedAt":"2020-10-08T16:32:47.330Z","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e","paymentToken":{"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=","batchProof":"m2p/CyXRBCRq3kjymwYYBiDgARVgfWvPSUy5wYbLowSwC4hKUJpqmnBq+OS1Ip7ZzCU7gi0nGm7S8q6DjYT6Bg==","signedTokens":["XN3bSUmDLQpysUCGEAlpYbPD8ghWVd0iMgwlRDajQm8="]}}
[9124:775:1008/123247.557302:VERBOSE1:redeem_unblinded_token.cc(165)] Confirmation not found
[9124:775:1008/123247.557336:VERBOSE1:ads_impl.cc(1480)] Failed to redeem unblinded token with confirmation id fc9ff690-0f21-4260-843c-02f40b0a4dd2, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss
[9124:775:1008/123247.558432:VERBOSE1:confirmations.cc(168)] Added confirmation id e111d18a-8d1d-486a-bd2f-c14305380a0d, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss to the confirmations queue
[9124:775:1008/123247.558487:VERBOSE1:refill_unblinded_tokens.cc(64)] No need to refill unblinded tokens as we already have 46 unblinded tokens which is above the minimum threshold of 20

Disabled Charles rewrite rule and waited until the time mentioned in the logs (Retry failed confirmations in 0 hours, 2 minutes, 55 seconds at 12:35 PM), confirmed previously failed confirmation was retried and successful:

[9124:775:1008/123542.212306:VERBOSE1:confirmations.cc(223)] Removed confirmation id e111d18a-8d1d-486a-bd2f-c14305380a0d, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss from the confirmations queue
[9124:775:1008/123542.213153:VERBOSE1:redeem_unblinded_token.cc(88)] Redeem token
[9124:775:1008/123542.213233:VERBOSE1:redeem_unblinded_token.cc(103)] CreateConfirmation
[9124:775:1008/123542.213280:VERBOSE2:redeem_unblinded_token.cc(104)] POST /v1/confirmation/{confirmation_id}/{credential}
[9124:775:1008/123542.213326:VERBOSE5:redeem_unblinded_token.cc(108)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwidmxGaVd0YUFpOGZxVmVEaHhiRElMeHcyV2FIKzdoVE5ZcHhLV0NzR25ROD1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImNLSDdRU2JNdEE1ZDhaRitBU2JmdklYa0xuTjJwcXhzVjRNd1o3TzduMmtWUk5ESVVKdnFuY2xLZlpPMXlwZUdaalVyR01yaHB5OTVCNk5nTHdMb3JBPT0iLCJ0IjoiMDI1Y3BkNElXMkhBeHBQYXVjL2o3SkplWkt2LzEzYzhpNnljbzVrUS94RkJvM1hDVnlXdFdFN2p1TWg4eTNkZEE0anVmMjZtRDBnZnl0YlBIVnJCalE9PSJ9
  Content: {"blindedPaymentToken":"vlFiWtaAi8fqVeDhxbDILxw2WaH+7hTNYpxKWCsGnQ8=","buildChannel":"nightly","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e","payload":{},"platform":"macos","type":"dismiss"}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9124:775:1008/123542.213927:VERBOSE1:confirmations.cc(138)] Retry failed confirmations in 0 hours, 2 minutes, 15 seconds at 12:37 PM
[9124:775:1008/123542.623032:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwidmxGaVd0YUFpOGZxVmVEaHhiRElMeHcyV2FIKzdoVE5ZcHhLV0NzR25ROD1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImNLSDdRU2JNdEE1ZDhaRitBU2JmdklYa0xuTjJwcXhzVjRNd1o3TzduMmtWUk5ESVVKdnFuY2xLZlpPMXlwZUdaalVyR01yaHB5OTVCNk5nTHdMb3JBPT0iLCJ0IjoiMDI1Y3BkNElXMkhBeHBQYXVjL2o3SkplWkt2LzEzYzhpNnljbzVrUS94RkJvM1hDVnlXdFdFN2p1TWg4eTNkZEE0anVmMjZtRDBnZnl0YlBIVnJCalE9PSJ9
[9124:775:1008/123542.623292:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwidmxGaVd0YUFpOGZxVmVEaHhiRElMeHcyV2FIKzdoVE5ZcHhLV0NzR25ROD1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImNLSDdRU2JNdEE1ZDhaRitBU2JmdklYa0xuTjJwcXhzVjRNd1o3TzduMmtWUk5ESVVKdnFuY2xLZlpPMXlwZUdaalVyR01yaHB5OTVCNk5nTHdMb3JBPT0iLCJ0IjoiMDI1Y3BkNElXMkhBeHBQYXVjL2o3SkplWkt2LzEzYzhpNnljbzVrUS94RkJvM1hDVnlXdFdFN2p1TWg4eTNkZEE0anVmMjZtRDBnZnl0YlBIVnJCalE9PSJ9
[9124:775:1008/123542.623532:VERBOSE1:redeem_unblinded_token.cc(121)] OnCreateConfirmation
[9124:775:1008/123542.623601:VERBOSE6:redeem_unblinded_token.cc(123)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwidmxGaVd0YUFpOGZxVmVEaHhiRElMeHcyV2FIKzdoVE5ZcHhLV0NzR25ROD1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCJiYzY1MjNlZS1hNzkwLTQ4N2EtYmIwZS03ZmRhNTJiOGFmN2VcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwiZGlzbWlzc1wifSIsInNpZ25hdHVyZSI6ImNLSDdRU2JNdEE1ZDhaRitBU2JmdklYa0xuTjJwcXhzVjRNd1o3TzduMmtWUk5ESVVKdnFuY2xLZlpPMXlwZUdaalVyR01yaHB5OTVCNk5nTHdMb3JBPT0iLCJ0IjoiMDI1Y3BkNElXMkhBeHBQYXVjL2o3SkplWkt2LzEzYzhpNnljbzVrUS94RkJvM1hDVnlXdFdFN2p1TWg4eTNkZEE0anVmMjZtRDBnZnl0YlBIVnJCalE9PSJ9
  Response Status Code: 201
  Response: {"id":"e111d18a-8d1d-486a-bd2f-c14305380a0d","payload":{},"createdAt":"2020-10-08T16:35:42.502Z","type":"dismiss","modifiedAt":"2020-10-08T16:35:42.502Z","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e"}
[9124:775:1008/123542.623668:VERBOSE1:redeem_unblinded_token.cc(143)] FetchPaymentToken
[9124:775:1008/123542.623703:VERBOSE2:redeem_unblinded_token.cc(144)] GET /v1/confirmation/{confirmation_id}/paymentToken
[9124:775:1008/123542.623737:VERBOSE5:redeem_unblinded_token.cc(148)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/paymentToken
  Method: BraveAdsUrlRequestMethod::GET
[9124:775:1008/123542.769415:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/paymentToken
[9124:775:1008/123542.769974:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/paymentToken
[9124:775:1008/123542.770297:VERBOSE1:redeem_unblinded_token.cc(159)] OnFetchPaymentToken
[9124:775:1008/123542.770363:VERBOSE6:redeem_unblinded_token.cc(161)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/e111d18a-8d1d-486a-bd2f-c14305380a0d/paymentToken
  Response Status Code: 200
  Response: {"id":"e111d18a-8d1d-486a-bd2f-c14305380a0d","createdAt":"2020-10-08T16:35:42.502Z","type":"dismiss","modifiedAt":"2020-10-08T16:35:42.533Z","creativeInstanceId":"bc6523ee-a790-487a-bb0e-7fda52b8af7e","paymentToken":{"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=","batchProof":"/jGDbcXKvint06qrQKcxVMvlGTF4PcP4tN3xA35xgAKh0QbLNiKi5hJLeZfPJbIIMVCkPs71hYz31b5I86rHBw==","signedTokens":["2BVl07a19rTvQGPQRivwM5MUNQMV6QkrfxYdEeOUEAM="]}}
[9124:775:1008/123542.771657:VERBOSE1:redeem_unblinded_token.cc(335)] Added 1 unblinded payment token with an estimated redemption value of 0 BAT, you now have 2 unblinded payment tokens
[9124:775:1008/123542.772229:VERBOSE1:ads_impl.cc(1472)] Successfully redeemed unblinded token with confirmation id e111d18a-8d1d-486a-bd2f-c14305380a0d, creative instance id bc6523ee-a790-487a-bb0e-7fda52b8af7e and dismiss
Confirm unblinded tokens are refilled to 50 if we are below the threshold after attempting to download the catalog

Enable Rewards, wait until everything is complete (catalog download, tokens fetched, etc). View an ad, dismiss ad. Enable Charles rewrite rule outlined in https://github.com/brave/internal/issues/731. Use +1/-1 on Ad history to use tokens so that you have less than 20 left:

[9322:775:1008/134747.344749:VERBOSE1:confirmations.cc(123)] Confirm ad:
  creativeInstanceId: 3d3ea762-492f-4c81-9b13-020454acc66c
  creativeSetId: 32439113-32d2-4b50-9497-405b7eedd1d5
  campaignId: 
  confirmationType: upvote
[9322:775:1008/134747.344821:VERBOSE1:redeem_unblinded_token.cc(63)] Redeem token
[9322:775:1008/134747.345586:VERBOSE1:redeem_unblinded_token.cc(103)] CreateConfirmation
[9322:775:1008/134747.345659:VERBOSE2:redeem_unblinded_token.cc(104)] POST /v1/confirmation/{confirmation_id}/{credential}
[9322:775:1008/134747.345703:VERBOSE5:redeem_unblinded_token.cc(108)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/156d1fdb-9386-47a3-8313-61b96d433986/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwiWHFjOEZnWDFlNnZQb2crbUtwd0NBWFdtOTUySGNnQlZVTmdRbkwwUURnST1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCIzZDNlYTc2Mi00OTJmLTRjODEtOWIxMy0wMjA0NTRhY2M2NmNcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwidXB2b3RlXCJ9Iiwic2lnbmF0dXJlIjoiOEF4a2I3ek1TZTV5VUh6bUZXTGtIWUE5NDlaR0pwZjJwSzlKL1daY3ErTEt5VFhZQVl3akdUcGZsQWpYeU1VRGV4Q3V3Z3lUa0lRcjlGZDFWUnFqWHc9PSIsInQiOiIzL2hZM3Z5RTNkTGRMS1pJaG5ERzJISHAwQ2hCbUVONEphcXBHemdRMzVUZitJcDRwUzM4a3k2SFRjVGxjd2F2Q04zYWVmcm1saTJpd2JjSTg4eCswUT09In0=
  Content: {"blindedPaymentToken":"Xqc8FgX1e6vPog+mKpwCAXWm952HcgBVUNgQnL0QDgI=","buildChannel":"nightly","creativeInstanceId":"3d3ea762-492f-4c81-9b13-020454acc66c","payload":{},"platform":"macos","type":"upvote"}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9322:775:1008/134747.346047:VERBOSE1:refill_unblinded_tokens.cc(91)] Refill unblinded tokens
[9322:775:1008/134747.346099:VERBOSE1:refill_unblinded_tokens.cc(101)] RequestSignedTokens
[9322:775:1008/134747.346139:VERBOSE2:refill_unblinded_tokens.cc(102)] POST /v1/confirmation/token/{payment_id}
[9322:775:1008/134747.350248:VERBOSE1:refill_unblinded_tokens.cc(340)] Generated and blinded 31 tokens
[9322:775:1008/134747.352137:VERBOSE5:refill_unblinded_tokens.cc(110)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
  Content: {"blindedTokens":["ciXNY6jbtv9MxZqDSAPCL7iXKmsxEEaWe5fHrMq6Q1M=","FDh5bC8HaYj4gUYM6vt0LxZgYpCiOtfdiwAVOs1e9kc=","Shyhgpg14aTGHwMc0Z6J7DZIATIa5XKHYj4HAuLhZR0=","hJz/CBqZa+hEKQCvg6Br7cZLPz2winGGs9zfiZW0MXY=","zltVrKRVOjV1at4jMDTWKGVrd2nPe/yi+nC7cypOymM=","6M8j5M+TgpQTS2lXVL0OigIGbp5wGMgdSpbldMVCu2s=","MHm4Sz1p5c8aaMYRAqY2l9j1Nm44U8b3/UyiPTZLGBk=","NjpFvzu4OUMOooYb8yDwarJ9uiSYUyknw7d+90hHzhM=","GKWnhhew485TAewu7wiYesjhkTAsDxgO4iJjTTTWiSY=","4iQM+J+RPFpT2dXQrijsQvFe2qMIk8g1AmIJ3I4FUV0=","sHsS06Bv2RGyuZJjr1dZsDhnMW6nFBOejfgTyNhj3GA=","Jj5xZoSck7jVDHCkNGXAaTzU33s38eSgmv5J+d8OfTk=","MALiA7nF5IEKmmYaL9oec6pmatnoZDg2aoufpcsqkjU=","2jaloOM0MA1Yr/E7SFDooANndm8U2gXu/sQwknr21Hs=","ntIUrKV0PfG7p2Ll9kjgn7+jzY23NA1A4shi1LQuyWA=","eEv72bRBYDlLkdv02PaTWJZN8S5+Vt441Uw2v7Tj4lQ=","xje0MOaXhlhxUSWP33kS318GCAcbtvNCxzCvCB2jxSU=","DsIjlrQ+v/vPZ1KXIGc00JADS26xVB1B8pFFlzWsY18=","4tUDPVkFYVpqZSNByUctzBgGsqOXOK6j9nFoVbxwCgQ=","3MnGM6qZeR4qBy4UEuFSF9CK4De01y+V20lA3y9dsw8=","RrcqQfcQAHGPLUuTAMmM0RU2fM1D7q4q16E7oULGxl4=","6LfOoDE8bYA57mZ2R09OtyrwMFGZMJrsfkC+c4lXghI=","pK5xvILNkD0+r0yEujzc+FN2DJQs3FgzWKvgoBW9uww=","WGO720KXuyTDL2KEz4qhDupUU1MfGBpXY55kQpow7lc=","qDZ0rwKldoM7DembDy4x2JH0tYDgFz0tIPW8dUVLd2s=","jGMMSAkVOMITiLdBDkRnulysIYco6Dvc/aeZws2XdCU=","ZoyX1Iuni0DhGLElUjBmTuq3oJeaunN0QfjtDHSCVxA=","Qs3seA65fHW9vkSRa3azRBZV5OaQMufvCYNhvb1WI1M=","WBonRw/vETWqoBQcTYiYwxWlGrV9whUE1lEsosBXqFY=","rizmj4RN+jzxCG0jaSxtpuNNaf4/dG+5AHO9ZXud6i4=","Uqs89Vf5dduiCuxC4adPpexiQvcNxQ80gTpsTHm4FR0="]}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9322:775:1008/134747.516355:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
[9322:775:1008/134747.516691:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
[9322:775:1008/134747.516977:VERBOSE1:refill_unblinded_tokens.cc(120)] OnRequestSignedTokens
[9322:775:1008/134747.517060:VERBOSE6:refill_unblinded_tokens.cc(122)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
  Response Status Code: 404
  Response: {"nonce":"ef9adecc-ba83-4b33-8f29-3047695b0c08"}
[9322:775:1008/134747.517156:VERBOSE1:refill_unblinded_tokens.cc(126)] Failed to request signed tokens
[9322:775:1008/134747.517205:VERBOSE1:ads_impl.cc(1502)] Failed to refill unblinded tokens
[9322:775:1008/134747.517533:VERBOSE1:refill_unblinded_tokens.cc(305)] Retry refilling unblinded tokens in 0 hours, 0 minutes, 6 seconds at 1:47 PM

Close browser. Disable Charles rewrite rule. Relaunch browser. Confirm after catalog is downloaded that tokens are refilled successfully:

[9359:775:1008/134908.369957:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v4/catalog
[9359:775:1008/134908.370056:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/payment/ef593424-eb45-4135-93f0-cbe005a71d1a
[9359:775:1008/134908.370410:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v4/catalog
[9359:775:1008/134908.370957:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/payment/ef593424-eb45-4135-93f0-cbe005a71d1a
[9359:775:1008/134908.371352:VERBOSE1:get_catalog.cc(83)] Successfully downloaded catalog
[9359:775:1008/134908.371401:VERBOSE1:get_catalog.cc(112)] Parsing catalog
[9359:775:1008/134908.374234:VERBOSE1:get_catalog.cc(130)] Generating bundle
[9359:775:1008/134908.374294:VERBOSE1:bundle.cc(208)] creative set id 7be431a0-c6e4-4ca6-bcac-672e77294b7d has no entries
[9359:775:1008/134908.374332:VERBOSE1:bundle.cc(208)] creative set id 486d1bbe-e460-474e-ac26-d554cb1a21d4 has no entries
[9359:775:1008/134908.375045:VERBOSE1:bundle.cc(208)] creative set id 175bc3ca-50f0-4749-bfc8-c7ff7482de0f has no entries
[9359:775:1008/134908.375102:VERBOSE1:bundle.cc(208)] creative set id 2b67d6ee-e6d1-4d4e-a1b9-6be11a60c11d has no entries
[9359:775:1008/134908.378441:VERBOSE1:get_catalog.cc(138)] Successfully generated bundle
[9359:775:1008/134908.378523:VERBOSE1:confirmations.cc(50)] SetCatalogIssuers:
[9359:775:1008/134908.378557:VERBOSE1:confirmations.cc(51)]   Public key: crDVI1R6xHQZ4D9cQu4muVM5MaaM1QcOT4It8Y/CYlw=
[9359:775:1008/134908.378588:VERBOSE1:confirmations.cc(52)]   Issuers:
[9359:775:1008/134908.378617:VERBOSE1:confirmations.cc(55)]     Name: 0.01BAT
[9359:775:1008/134908.378660:VERBOSE1:confirmations.cc(56)]     Public key: JiwFR2EU/Adf1lgox+xqOVPuc6a/rxdy/LguFG5eaXg=
[9359:775:1008/134908.378704:VERBOSE1:confirmations.cc(55)]     Name: 0.025BAT
[9359:775:1008/134908.378735:VERBOSE1:confirmations.cc(56)]     Public key: CrQLMWmUuYog6Q93nScS8Lo1HHSex8WM2Qxij7qhjkQ=
[9359:775:1008/134908.378765:VERBOSE1:confirmations.cc(55)]     Name: 0.15BAT
[9359:775:1008/134908.378795:VERBOSE1:confirmations.cc(56)]     Public key: iJcG3AkH1sgl+5YCZuo+4Q/7aeBOnYyntkIUXeMbDCs=
[9359:775:1008/134908.378828:VERBOSE1:confirmations.cc(55)]     Name: 0.20BAT
[9359:775:1008/134908.378858:VERBOSE1:confirmations.cc(56)]     Public key: VihGXGoiQ5Fjxe4SrskIVMcmERa1LoAgvhFxxfLmNEI=
[9359:775:1008/134908.378888:VERBOSE1:confirmations.cc(55)]     Name: 0.3BAT
[9359:775:1008/134908.378928:VERBOSE1:confirmations.cc(56)]     Public key: 6DBiZUS47m8eb5ohI2MiRaERLzS4DQgMp4nxPLKAenA=
[9359:775:1008/134908.378967:VERBOSE1:confirmations.cc(55)]     Name: 0.25BAT
[9359:775:1008/134908.378997:VERBOSE1:confirmations.cc(56)]     Public key: YOIEGq4joK7rtkWdcNdNNGT5xlU/KIrri4AX19qwZW4=
[9359:775:1008/134908.379028:VERBOSE1:confirmations.cc(55)]     Name: 0BAT
[9359:775:1008/134908.379056:VERBOSE1:confirmations.cc(56)]     Public key: lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=
[9359:775:1008/134908.379091:VERBOSE1:confirmations.cc(55)]     Name: 0.05BAT
[9359:775:1008/134908.379124:VERBOSE1:confirmations.cc(56)]     Public key: bPE1QE65mkIgytffeu7STOfly+x10BXCGuk5pVlOHQU=
[9359:775:1008/134908.379154:VERBOSE1:confirmations.cc(55)]     Name: 0.10BAT
[9359:775:1008/134908.379183:VERBOSE1:confirmations.cc(56)]     Public key: aDD4SJmIj2xwdA6D00K1dopTg90oOFpwd2iiK8bqqlQ=
[9359:775:1008/134908.379279:VERBOSE1:refill_unblinded_tokens.cc(91)] Refill unblinded tokens
[9359:775:1008/134908.379315:VERBOSE1:refill_unblinded_tokens.cc(101)] RequestSignedTokens
[9359:775:1008/134908.379348:VERBOSE2:refill_unblinded_tokens.cc(102)] POST /v1/confirmation/token/{payment_id}
[9359:775:1008/134908.382270:VERBOSE1:refill_unblinded_tokens.cc(340)] Generated and blinded 31 tokens
[9359:775:1008/134908.384092:VERBOSE5:refill_unblinded_tokens.cc(110)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
  Content: {"blindedTokens":["FJx8eOaQXFwUizdsrO3A491MQ9k9fKa7SaQ/g13fUhU=","zACjYAWIsQcCtYsctnP0vgvESTrEHsaP9U/MkOJ8rhA=","Iot4XOVmLHTn+gTsbdfk+NFduYjT13OziUyW20mrjRk=","LsLlS/9/CAkprIyEWMe8g8LQu/8zSYhRKjruzKTg4k0=","arrq1lPfThqUWrCJwUSlaq54I0iYobWuAA9onHRHqn4=","xio15LFRf82qfaC2Co+vUnhVbyiecudCDCbf4iHlHCM=","aNreA5IXOvkFIP2Qa2pnJDOgIUyEVc9LUut72vUeeUY=","CGw9PZKAkvV4//9ksBCy9pYoYylBuhmpdoQt3tQH3j4=","uC8oG3IrIztRKqqKL46NdhOBXzYijePWzJJHb+N5n3M=","JA7gJMACL3MVeDleOqSd3StRgWPYyl/6Hud3rxFgAU0=","qrkcauwifd3cdnsqeBBfj7V8fJFajbRxB84sbv4iIBM=","RKjN3o2BfuQEe9pBzra6bfYKmg826UfelnpPIeN0HCs=","cJDBVqV7VXQa9RYcdrgiqhrdBtDcizmRhyfcGCsqOkc=","HpTRasdczjk9eIiiRzP96xXzAMnH0IOJD6fwO59Cj18=","nrezcqsX1eVOBp9W+r+NdaEy/PUaR7xq0NXec1sf/14=","1ODZ6nfdBTkLN9BKIhD19lstjf4ZtBPNOsZK5ojwcwQ=","EkBdZZ2QEjlSvrpb0VkBNtnpEe9VhXuN7nQORzsk+lQ=","GuV9vx3W8pqxnNMStrL9y5XJUC4C6FituCouGYLtXno=","ZgXLMsH2hOhJIY+mHLcJqb7TNU/OLYr7mrjy7Q1AsRc=","0n6gWaqVvnWQHf2qyE5MpU6TXHWcxW4T6jrdeAlhwyw=","uLxXH/4EU9zbi+dKxUpKY64l46g3enhTLVxE+f2LzDA=","gqX9/mH6x0kTDuukg7J/b3nrNgThoi8h4MaYeTtLSgM=","LJaKeAn2ajZJirdMVnyepvEcenIHrtCFbFwPjlpWQSU=","sGVDKorUXmLV8pJkDU6NZxMnwvDsFlJFoewrFW0HTCs=","Fu+3g2b3czjxg/2m+wBMEqdcNkqkiFNneXrGq13i93I=","oo7TXxiVIF1QTjggjFBIgStI8IxJyjBGqWNMJYk4hRY=","QpLupOIrBF2akeoocCh55Q/DOM6prKqkswydwxDjs3k=","JlN9RO0oATXmxqivlnCZ5hlEBTcKn99/5T4yICDc+yk=","DHG0izhZNcjwTD0uqFiWisPd5XjPCSj3PPyFsFLL4iE=","VMlWXSBCmICA4xJs8cC35Pq7AzNw+tJhJFPGzMPKoTY=","5KLDJmKQA9X+uNaEfoZN0cVDQXijLJ54vR8nY9yETn4="]}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9359:775:1008/134908.384421:VERBOSE1:confirmations.cc(138)] Retry failed confirmations in 0 hours, 15 minutes, 0 seconds at 2:04 PM
[9359:775:1008/134908.384592:VERBOSE1:get_catalog.cc(186)] Download catalog in 0 hours, 7 minutes, 12 seconds at 1:56 PM
[9359:775:1008/134908.384833:VERBOSE1:ad_rewards.cc(180)] OnGetPayments
[9359:775:1008/134908.384903:VERBOSE6:ad_rewards.cc(182)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/payment/ef593424-eb45-4135-93f0-cbe005a71d1a
  Response Status Code: 200
  Response: [{"balance":"0","month":"2020-10","transactionCount":"0"}]
[9359:775:1008/134908.385197:VERBOSE1:ad_rewards.cc(201)] GetAdGrants
[9359:775:1008/134908.385252:VERBOSE2:ad_rewards.cc(202)] GET /v1/promotions/ads/grants/summary?paymentId={payment_id}
[9359:775:1008/134908.385289:VERBOSE5:ad_rewards.cc(206)] URL Request:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=ef593424-eb45-4135-93f0-cbe005a71d1a
  Method: BraveAdsUrlRequestMethod::GET
[9359:775:1008/134908.386516:VERBOSE3:bundle.cc(257)] Successfully saved creative ad notifications state
[9359:775:1008/134908.386812:VERBOSE3:bundle.cc(267)] Successfully purged expired ad conversions
[9359:775:1008/134908.388418:VERBOSE3:bundle.cc(277)] Successfully saved ad conversions state
[9359:775:1008/134908.396328:VERBOSE3:get_catalog.cc(160)] Successfully saved catalog
[9359:775:1008/134908.985029:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
[9359:775:1008/134908.985933:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/promotions/ads/grants/summary?paymentId=ef593424-eb45-4135-93f0-cbe005a71d1a
[9359:775:1008/134908.986043:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
[9359:775:1008/134908.986268:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/promotions/ads/grants/summary?paymentId=ef593424-eb45-4135-93f0-cbe005a71d1a
[9359:775:1008/134908.986347:VERBOSE1:refill_unblinded_tokens.cc(120)] OnRequestSignedTokens
[9359:775:1008/134908.986389:VERBOSE6:refill_unblinded_tokens.cc(122)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a
  Response Status Code: 201
  Response: {"nonce":"99b88e6a-eff0-492f-9f0e-665652f7121f"}
[9359:775:1008/134908.986469:VERBOSE1:refill_unblinded_tokens.cc(154)] GetSignedTokens
[9359:775:1008/134908.986509:VERBOSE2:refill_unblinded_tokens.cc(155)] GET /v1/confirmation/token/{payment_id}?nonce={nonce}
[9359:775:1008/134908.986540:VERBOSE5:refill_unblinded_tokens.cc(159)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a?nonce=99b88e6a-eff0-492f-9f0e-665652f7121f
  Method: BraveAdsUrlRequestMethod::GET
[9359:775:1008/134908.986714:VERBOSE1:ad_rewards.cc(215)] OnGetAdGrants
[9359:775:1008/134908.986750:VERBOSE6:ad_rewards.cc(217)] URL Response:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=ef593424-eb45-4135-93f0-cbe005a71d1a
  Response Status Code: 204
  Response: 
[9359:775:1008/134908.986796:VERBOSE1:ad_rewards.cc(252)] Successfully reconciled ad rewards
[9359:775:1008/134909.089838:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a?nonce=99b88e6a-eff0-492f-9f0e-665652f7121f
[9359:775:1008/134909.090166:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a?nonce=99b88e6a-eff0-492f-9f0e-665652f7121f
[9359:775:1008/134909.090508:VERBOSE1:refill_unblinded_tokens.cc(169)] OnGetSignedTokens
[9359:775:1008/134909.090586:VERBOSE6:refill_unblinded_tokens.cc(171)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/ef593424-eb45-4135-93f0-cbe005a71d1a?nonce=99b88e6a-eff0-492f-9f0e-665652f7121f
  Response Status Code: 200
  Response: {"batchProof":"0omxTTXrUHT4DCnDV5vhD+nJO7Fkrhbi3TWx5l/KJwEoPuKlwkon6Ha55Orwmv0YUklD64YHUeUeTzNHyiBQCg==","signedTokens":["HEjXVAA3HP2aiEdCGaPYYlENOa1tAKaUzppbZrGcvWE=","+IrXv6TATmfQPEhUq0b9b9KACgoa6jhA0P+XP0ZAF04=","3BVJCAeygF67hQqS3e6HbISZfOyc+62HSb2TTNgcI0A=","gvv2YWipw+6sCkTUsWw8DG0udzinbs4aJoF8as6ffhE=","IGeTBJlc+UKvDlW8sCe82FlK6xNpL6prOUxt+9MTkGQ=","/AIzmcbRtgN35MXk8Ot64POipLAhqvBK352HE4KVN1w=","wmmfO+8bBmNNTe4sZTWhgcqkfTkwSlqq3dzkInAxej0=","pGmNICi8WgPYMvREUUNj9CHnsVX3fC8f1fu6nScYzhk=","MnMTvZ+j0BfFhE0mGiaF/wdJRueII3M2kpkLAnUJyw0=","QFM7PeLiOnIPRxxKew7LM0nqKNuKN45sESKBMA173SI=","OL8JfaicFTacNoHvPAeUKiaA8RoC/0Lvg7t1HfPmiXA=","KrxH21D6m2/bksWFiY/Mx+7M/cW6bJIq8ds4CW12OnA=","jsPXo60eCIDfvi79VwAWcei8xInkCM1mGdz38u8/OgM=","uM/uKSKqGZgd4SlKqTDiQikpECMzBpIrQq6y1iRlESQ=","fFlIb02O4u4VSvNy5KK486QKrB0+X7aVc6mUNMrndGQ=","zMyK+DKAjwYoGrJTsGAl5cse03X2KFQ4YhcJaingFTc=","2LoGgrmmTTQ2Saniq2YUrL50D4QtzYX+x6AR96KRxTI=","Xq0KzfpImW2AODqsdsrUHmGrep51y42px831ZAU2oBg=","vhtcX0Lu1xm7ZxcJW9kdLtMrg2Z6wrY3gLOwc9iFHmM=","fvVp5FZNFRgjjPQQ4EDkx3cFmwzpEJRzaUls0EY0akA=","Phqm5lBCtuHpAQ5iizWdDPhQrCaNTshwtFILFn8qz08=","9APSH/6uFiXZUjVeAAQL8bxW/FPdquPs4kEuhLqOx3w=","zmLLiLpBVR9Qn2vJM+gORPhtS0geipD27BUDSNE2MQ4=","avs9Fl/7EqsJJm1BYfAjnJ8QA6CS+js5S/hcJp3zySk=","3Fpltj1I7ccbA1O3rtPvBgVrR/cvJJG912U1bnWFSTk=","cGXTo8nTN3PdHYSOfEkGoRbpH6tT89ALDNJ/mDHkzDw=","4BwIER40EhM9Fk6nQcYexR2b7m2UKrL9en768DZt+WI=","qIDytqMK2h89pSos2lLG+8QONBDDXHYVb1w4dd6NS2o=","qMjGXlj5jkJGWWIOZZdU58S+A90sqP/wsEML9XpkeUQ=","YJ7dWV1BEBNvegnJU813OJgiADVvrMYo0Q9Wyk/PnE4=","+Hj6kM2wsDTyEx9q6mnxjGrVAl0WSspNtxPfvfK6dhM="],"publicKey":"crDVI1R6xHQZ4D9cQu4muVM5MaaM1QcOT4It8Y/CYlw="}
[9359:775:1008/134909.099654:VERBOSE1:refill_unblinded_tokens.cc(266)] Added 31 unblinded tokens, you now have 50 unblinded tokens
[9359:775:1008/134909.100465:VERBOSE1:ads_impl.cc(1498)] Successfully refilled unblinded tokens
Confirm unblinded tokens are refilled to 50 if we are below the threshold after redeeming an unblinded token

Enable Rewards, wait until everything is complete (catalog download, tokens fetched, etc). View an ad, dismiss ad. Use +1/-1 on Ad history to use tokens just until you have 20 left:

[9392:775:1008/135711.696734:VERBOSE1:refill_unblinded_tokens.cc(64)] No need to refill unblinded tokens as we already have 20 unblinded tokens which is above the minimum threshold of 20

Use the other (+1 or -1) button to get to 19 and confirm that tokens are refilled successfully:

[9392:775:1008/135739.648999:VERBOSE1:confirmations.cc(123)] Confirm ad:
  creativeInstanceId: 4bafa8e2-e5f6-434a-9cfe-cf1cf8e80d32
  creativeSetId: 32439113-32d2-4b50-9497-405b7eedd1d5
  campaignId: 
  confirmationType: upvote
[9392:775:1008/135739.649085:VERBOSE1:redeem_unblinded_token.cc(63)] Redeem token
[9392:775:1008/135739.649905:VERBOSE1:redeem_unblinded_token.cc(103)] CreateConfirmation
[9392:775:1008/135739.649994:VERBOSE2:redeem_unblinded_token.cc(104)] POST /v1/confirmation/{confirmation_id}/{credential}
[9392:775:1008/135739.650047:VERBOSE5:redeem_unblinded_token.cc(108)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwia0I3YTZiQk0xcGY1QjVNbWd5dnFERk9nRFNuWlZkVW96bG5EenEwWDQyaz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCI0YmFmYThlMi1lNWY2LTQzNGEtOWNmZS1jZjFjZjhlODBkMzJcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwidXB2b3RlXCJ9Iiwic2lnbmF0dXJlIjoid3BXcVdmbzBjNnpGSVhWLzZOcWFFVWxibmJTYktrVGg5U0lLMUJQTC94Y2xhMHBud1hqdnpwMmd3YWQ1TG9rSmM0KzVRakN6eTVKTmlBRm12VStvQkE9PSIsInQiOiIrRC9idW5yL1hFbk51SVI4UWVneERJbnlUZkZPYXd1ZkdmWjNWQ0lBQUhLVFYzeUxWMWNSN29hVjRUa0FUNjNucTV1VkJKRFExSWViZlBqeWliTXlKUT09In0=
  Content: {"blindedPaymentToken":"kB7a6bBM1pf5B5MmgyvqDFOgDSnZVdUozlnDzq0X42k=","buildChannel":"nightly","creativeInstanceId":"4bafa8e2-e5f6-434a-9cfe-cf1cf8e80d32","payload":{},"platform":"macos","type":"upvote"}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9392:775:1008/135739.650476:VERBOSE1:refill_unblinded_tokens.cc(91)] Refill unblinded tokens
[9392:775:1008/135739.650528:VERBOSE1:refill_unblinded_tokens.cc(101)] RequestSignedTokens
[9392:775:1008/135739.650566:VERBOSE2:refill_unblinded_tokens.cc(102)] POST /v1/confirmation/token/{payment_id}
[9392:775:1008/135739.654137:VERBOSE1:refill_unblinded_tokens.cc(340)] Generated and blinded 31 tokens
[9392:775:1008/135739.655942:VERBOSE5:refill_unblinded_tokens.cc(110)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02
  Content: {"blindedTokens":["vBslVazEgG2PUbMfakfDCJAjzgfUMF7lfG9cVJZeC0A=","9vBlFa8Iv0qf8Zf/+hK4J2acgctoQZfloMeRWUglDyc=","ShzEN4INI2LQXRwlfQMnQ+B4DgZ1y0sKP33I8sZxPQI=","Yg78oH9HUqpwHo8HWnp22N42Ncst2sSta/6MWeEVrm0=","HNULzupEVkhPLRC0lsMhLjoxvDg4/q0a+6Iv2LkVwDQ=","WhGY6hxtfAIcdZZ45WsnViSjKDCGHYUR1kWjCwp6UGQ=","2L6y3U0FzsyKyZn0ZGLrqYONExerWSMBWu+CG3nVmXs=","yHEZTixpS2/UWJ3oIqSuUytixIFFS02tHp3BH7z7Dk0=","rFMxBlF7aM8i6cWgb2QjoV2L9qPuG2G2MIGQcvi8xQ0=","cJFeD4MTMtjGBLlBZwWoYVog4OwpTB4jOMcJXHU0Pks=","5uyQzzwrK1BR2sXIdzAktSY8FMFqa2e48C9KTvvYcXY=","giKPKgnpRVwsIXgTyGmo0jbMmerBu/xThvF4P5X+dDM=","oNvVW9Cd9bouczCE9L4bs8Unkm+ukx5yux0k9VMNRBc=","ouo9gFZqkuISe1Qa4yv/Kj/TJ6iYZkBamOcB8PfkGRg=","RN4JDAxPJKbPQo7SYBEDYkpEpI+GAAJX0/cFBXbqDSA=","nINagtKMPYeIhHCqS8oLvphC3Bic4sg9+s8Eu44L6WY=","GiB0yq6zrzGmBbNIH4hlBAN2Pq8JiKeNUsZPIBTZZVw=","AuZF36eirCVH6Dayry0aOo03k4ndXKROVO8ktVZGK3s=","+s2p9QAZLnHXq8HDWN/2YnTSkloS0n+KoQtMLh7SGxU=","vChQf4M9uNsOdcKh08HfJaTH03XmXE8fXETcdyWpAHk=","Jp14oIxRWBsxjO0g5U96fUygcdUttm87B31xf0WV6xU=","XuOOSYrWs3zsOfXGBzespTEO79LyViYQV83/axRfqTg=","av7SCts/yUpaCznxgI4cCT/qL/gh3mjC75zOOkU6FBk=","QJEXVRcAad1lraqNDDNkMMeuHImbfMq/C/skyRqYyQQ=","cC/mENfLt6ubuhxTiHUblt5ejAcQ25xYVbhyblgugHs=","LveWJryF1jyY7tKXEwxyRFVy51vr0XZS9KlfSuaF6nQ=","sH32N9F1pzTnSaYQesSevmBLSCUjoFdzqwieN3qAoH8=","jvBm2722wWZO1Y20QgyE6FOmXVJZ+kY8Xf6IRlSpKmw=","zpCZxH8YrsZ4h9/Tfuo8+v8/mvmyXD/bdvP5/qlNu2w=","AguUww1BqPaBihpNpNIFCSeCn8PKl9y7SF64OXm4WFY=","fBnKfdWsBwabqFxR/n3MrmGXobKK7Z2trupV1zxB2wQ="]}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::POST
[9392:775:1008/135740.169567:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02
[9392:775:1008/135740.169688:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwia0I3YTZiQk0xcGY1QjVNbWd5dnFERk9nRFNuWlZkVW96bG5EenEwWDQyaz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCI0YmFmYThlMi1lNWY2LTQzNGEtOWNmZS1jZjFjZjhlODBkMzJcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwidXB2b3RlXCJ9Iiwic2lnbmF0dXJlIjoid3BXcVdmbzBjNnpGSVhWLzZOcWFFVWxibmJTYktrVGg5U0lLMUJQTC94Y2xhMHBud1hqdnpwMmd3YWQ1TG9rSmM0KzVRakN6eTVKTmlBRm12VStvQkE9PSIsInQiOiIrRC9idW5yL1hFbk51SVI4UWVneERJbnlUZkZPYXd1ZkdmWjNWQ0lBQUhLVFYzeUxWMWNSN29hVjRUa0FUNjNucTV1VkJKRFExSWViZlBqeWliTXlKUT09In0=
[9392:775:1008/135740.169991:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02
[9392:775:1008/135740.170286:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwia0I3YTZiQk0xcGY1QjVNbWd5dnFERk9nRFNuWlZkVW96bG5EenEwWDQyaz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCI0YmFmYThlMi1lNWY2LTQzNGEtOWNmZS1jZjFjZjhlODBkMzJcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwidXB2b3RlXCJ9Iiwic2lnbmF0dXJlIjoid3BXcVdmbzBjNnpGSVhWLzZOcWFFVWxibmJTYktrVGg5U0lLMUJQTC94Y2xhMHBud1hqdnpwMmd3YWQ1TG9rSmM0KzVRakN6eTVKTmlBRm12VStvQkE9PSIsInQiOiIrRC9idW5yL1hFbk51SVI4UWVneERJbnlUZkZPYXd1ZkdmWjNWQ0lBQUhLVFYzeUxWMWNSN29hVjRUa0FUNjNucTV1VkJKRFExSWViZlBqeWliTXlKUT09In0=
[9392:775:1008/135740.170377:VERBOSE1:refill_unblinded_tokens.cc(120)] OnRequestSignedTokens
[9392:775:1008/135740.170427:VERBOSE6:refill_unblinded_tokens.cc(122)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02
  Response Status Code: 201
  Response: {"nonce":"0c1f9189-5f1c-42e5-bba5-ae0d08f4fedc"}
[9392:775:1008/135740.170484:VERBOSE1:refill_unblinded_tokens.cc(154)] GetSignedTokens
[9392:775:1008/135740.170521:VERBOSE2:refill_unblinded_tokens.cc(155)] GET /v1/confirmation/token/{payment_id}?nonce={nonce}
[9392:775:1008/135740.170557:VERBOSE5:refill_unblinded_tokens.cc(159)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02?nonce=0c1f9189-5f1c-42e5-bba5-ae0d08f4fedc
  Method: BraveAdsUrlRequestMethod::GET
[9392:775:1008/135740.170765:VERBOSE1:redeem_unblinded_token.cc(121)] OnCreateConfirmation
[9392:775:1008/135740.170806:VERBOSE6:redeem_unblinded_token.cc(123)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/eyJwYXlsb2FkIjoie1wiYmxpbmRlZFBheW1lbnRUb2tlblwiOlwia0I3YTZiQk0xcGY1QjVNbWd5dnFERk9nRFNuWlZkVW96bG5EenEwWDQyaz1cIixcImJ1aWxkQ2hhbm5lbFwiOlwibmlnaHRseVwiLFwiY3JlYXRpdmVJbnN0YW5jZUlkXCI6XCI0YmFmYThlMi1lNWY2LTQzNGEtOWNmZS1jZjFjZjhlODBkMzJcIixcInBheWxvYWRcIjp7fSxcInBsYXRmb3JtXCI6XCJtYWNvc1wiLFwidHlwZVwiOlwidXB2b3RlXCJ9Iiwic2lnbmF0dXJlIjoid3BXcVdmbzBjNnpGSVhWLzZOcWFFVWxibmJTYktrVGg5U0lLMUJQTC94Y2xhMHBud1hqdnpwMmd3YWQ1TG9rSmM0KzVRakN6eTVKTmlBRm12VStvQkE9PSIsInQiOiIrRC9idW5yL1hFbk51SVI4UWVneERJbnlUZkZPYXd1ZkdmWjNWQ0lBQUhLVFYzeUxWMWNSN29hVjRUa0FUNjNucTV1VkJKRFExSWViZlBqeWliTXlKUT09In0=
  Response Status Code: 201
  Response: {"id":"58e5e9e3-d37b-4454-b0d9-fe5a86887cf9","payload":{},"createdAt":"2020-10-08T17:57:39.956Z","type":"upvote","modifiedAt":"2020-10-08T17:57:39.956Z","creativeInstanceId":"4bafa8e2-e5f6-434a-9cfe-cf1cf8e80d32"}
[9392:775:1008/135740.170888:VERBOSE1:redeem_unblinded_token.cc(143)] FetchPaymentToken
[9392:775:1008/135740.170927:VERBOSE2:redeem_unblinded_token.cc(144)] GET /v1/confirmation/{confirmation_id}/paymentToken
[9392:775:1008/135740.170962:VERBOSE5:redeem_unblinded_token.cc(148)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/paymentToken
  Method: BraveAdsUrlRequestMethod::GET
[9392:775:1008/135740.316101:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/paymentToken
[9392:775:1008/135740.316466:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/paymentToken
[9392:775:1008/135740.316818:VERBOSE1:redeem_unblinded_token.cc(159)] OnFetchPaymentToken
[9392:775:1008/135740.316977:VERBOSE6:redeem_unblinded_token.cc(161)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/58e5e9e3-d37b-4454-b0d9-fe5a86887cf9/paymentToken
  Response Status Code: 200
  Response: {"id":"58e5e9e3-d37b-4454-b0d9-fe5a86887cf9","createdAt":"2020-10-08T17:57:39.956Z","type":"upvote","modifiedAt":"2020-10-08T17:57:39.989Z","creativeInstanceId":"4bafa8e2-e5f6-434a-9cfe-cf1cf8e80d32","paymentToken":{"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8=","batchProof":"69JsosUlJsgBZfYKXp9teDKMwkChBcpgkP48hy6i8Q8w0htx5u+RQ1dLywm0dqzfET0rYMAje6HK3NdOR6VrDQ==","signedTokens":["wKs72ONDzE/EXApy7FXOBiCi81AdHSq2n2R587+iOxY="]}}
[9392:775:1008/135740.317196:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02?nonce=0c1f9189-5f1c-42e5-bba5-ae0d08f4fedc
[9392:775:1008/135740.317487:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02?nonce=0c1f9189-5f1c-42e5-bba5-ae0d08f4fedc
[9392:775:1008/135740.318811:VERBOSE1:redeem_unblinded_token.cc(335)] Added 1 unblinded payment token with an estimated redemption value of 0 BAT, you now have 31 unblinded payment tokens
[9392:775:1008/135740.319470:VERBOSE1:ads_impl.cc(1472)] Successfully redeemed unblinded token with confirmation id 58e5e9e3-d37b-4454-b0d9-fe5a86887cf9, creative instance id 4bafa8e2-e5f6-434a-9cfe-cf1cf8e80d32 and upvote
[9392:775:1008/135740.319523:VERBOSE1:refill_unblinded_tokens.cc(169)] OnGetSignedTokens
[9392:775:1008/135740.319559:VERBOSE6:refill_unblinded_tokens.cc(171)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/token/bd288283-38b4-48d2-a175-4c4cfa561f02?nonce=0c1f9189-5f1c-42e5-bba5-ae0d08f4fedc
  Response Status Code: 200
  Response: {"batchProof":"1Gl/5hSwKSdtMrXnE+lUmt0DabHA7nv/TKHzF4kN+Q9UBObPECEZ2oer890Vo9CcI4D+x3ARCnAwFDdyUZp+BA==","signedTokens":["ihwrQe8XG42hdug+Xt/2R/Xaty5G6+jvJO/fadDO7AQ=","hs4ZycjPtNmddb1skJVWMlzIVfQxfPx6X/5kVsbYWV4=","mIYH+VnYGFfDyswpD1MfIwm4iOh/FkvG1XR546M+oRU=","dOKpTANCM3klSxuJEpbr8q0H0ajSLuODSXv18jfdqDY=","EtstIzmjJjCjp2GM2p6kO0f5EOdqEp3CTMwWWD81ylc=","shEd4aTCiBqA1c22XqO7PlZ6ncBc621kHtnQLbIU9lE=","OIu81+DR1i3POfbcXHZz5nqMgCe0uwedTqoBWGXH2gU=","TJuP2XI6bQRrU1d6BpkyfCkijMdZ2O+bZxq2A3ynvUo=","hB81YqfwnKGKTBA7HuSUdmPCBLpz5MABryJXUfT4ji4=","ZOZt2fO3wETz+twiuVrKTeULeIQtItTiEfrIbImanWc=","KqB/iSo8BM4t8Io3O3bbLf796ceQ1i6d9C7tlclU924=","8L3hF40QpOEWc2VX5MfHu4eLMuw9RINQQY5G+A59RXk=","qocTjDvxLVgf5RVQtiCY2Ii9h4zZPRHMQmC2+95nOFw=","KBFn2ALf7rYNBwSA4IoGkpynseohIZ+iutCFyz/AUWY=","xkyr2QnR/3O7p+zTuCfAPk15WfXcpgWBpoEXFjwd+AY=","foxxMsxb+/kgpNjVLFwZ4zVyX0W6r4jkCd4M6/K11TQ=","LjbQDhSSycbThfHi9plhImdQdCrVgrfbuAQBL1jXa0Y=","kuCASWVySNWYBwXOJiux4KoykB/KWZqgTZ7TeflUbjA=","+FLCEHpelgLC96S7XkL764oE+Qugj2ehHhnXA7pSMH4=","hGVZueVhPEOmtsGJn4lNd6+La3e8dBEvxTtCtTiMX3c=","egvuC2onAFd1iQDs6n8gQqqRSdQFKFM1yoipg9Vp1HM=","wud24gKawgt71x2789vXKClTQ87sqE2hfHyxzbJhIEQ=","uvp6UTdfu2hhO3SXT+0SEkUCwPxfeilC1vRsRGe4czk=","Srd77z9DW1xOvzWSCRvp8FEk372HOVFYPpotoh1IHD4=","NHCbwFnKr42rOOpVUDha9T+2/6PIMHDAzZplb791CnY=","/nE9ksrJ5+q9VxjlT4iDjY4SrNhxa6LPckoGE80nxSM=","qiJ/We+8zsJR9CbUX9PURCIwBRrZ8OYub1v1T2HiOGo=","nmLu+c1OvNSpYgk2TabDrvxBZavEM98GQROnMnx1VCU=","YGc9mCWP84PhF7PMN0ELu9peHOBa8Y91QGZWmzj/szw=","NLtwYrfHDXIQqa/DcQPMUi7D+P/gsF+ZantW94d3kmw=","qqZVqDCK9+v1RXuNJQ7J2CiyyMnYvYnNFTzad3r5Mwk="],"publicKey":"crDVI1R6xHQZ4D9cQu4muVM5MaaM1QcOT4It8Y/CYlw="}
[9392:775:1008/135740.328213:VERBOSE1:refill_unblinded_tokens.cc(266)] Added 31 unblinded tokens, you now have 50 unblinded tokens
[9392:775:1008/135740.328961:VERBOSE1:ads_impl.cc(1498)] Successfully refilled unblinded tokens

Verification passed on


Brave | 1.17.22 Chromium: 86.0.4240.75 (Official Build) nightly (64-bit)
-- | --
Revision | c69c33933bfc72a159aceb4aeca939eb0087416c-refs/branch-heads/4240@{#1149}
OS | Windows 10 OS Version 1903 (Build 18362.1082)

  • Verified the following scenarios on Nightly:
Confirm ad rewards are reconciled upon browser launch
Confirm ad rewards are reconciled after restoring a wallet
Confirm ad rewards are reconciled after redeeming unblinded payment tokens
Confirm ad rewards are reconciled after claiming an ad promotion
Confirm ad rewards are reconciled upon browser launch
  1. Launch brave with clean profile staging env
  2. Enable rewards
  3. Viewed logs and verified reconciled ad rewards
[18088:2832:1008/234828.496:VERBOSE1:ad_rewards.cc(215)] OnGetAdGrants
[18088:2832:1008/234828.496:VERBOSE6:ad_rewards.cc(217)] URL Response:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=1652bd12-81ea-4095-93b8-06278b9b6a5e
  Response Status Code: 204
  Response: 
[18088:2832:1008/234828.496:VERBOSE1:ad_rewards.cc(252)] Successfully reconciled ad rewards

Confirm ad rewards are reconciled after restoring a wallet
  1. Launch brave with clean profile staging env
  2. Enable rewards and Restore a wallet
  3. View an Ad
  4. Ensured Ads notification count and Estimated pending rewards is shown correctly in Ads panel
  5. Viewed logs and verified reconciled ad rewards
[4064:18088:1008/225635.814:VERBOSE1:ad_rewards.cc(215)] OnGetAdGrants
[4064:18088:1008/225635.814:VERBOSE6:ad_rewards.cc(217)] URL Response:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=656054a8-b7f4-4672-96a8-d71b2ec24e29
  Response Status Code: 204
  Response: 
[4064:18088:1008/225635.814:VERBOSE1:ad_rewards.cc(252)] Successfully reconciled ad rewards

Confirm ad rewards are reconciled after redeeming unblinded payment tokens
  1. Launch brave with clean profile staging env
  2. View an Ad
  3. Ensured Ads notification count and Estimated pending rewards is shown correctly in Ads panel
  4. Close the browser
  5. Fastforward the system clock to 24 hours
  6. Relaunch the browser
  7. Viewed logs and verified tokens are redeemed successfully for viewed Ad
[24436:24440:1009/213129.946:VERBOSE1:redeem_unblinded_payment_tokens.cc(105)] OnRedeemUnblindedPaymentTokens
[24436:24440:1009/213129.946:VERBOSE6:redeem_unblinded_payment_tokens.cc(107)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/payment/68a21b3f-73a9-47fc-ba2b-7b1dce33706a
  Response Status Code: 200
  Response: {"status":"ok"}
[24436:24440:1009/213129.947:VERBOSE1:ads_impl.cc(1484)] Successfully redeemed unblinded payment tokens
[24436:24440:1009/213129.947:VERBOSE1:ad_rewards.cc(158)] Reconcile ad rewards
[24436:24440:1009/213129.947:VERBOSE1:ad_rewards.cc(166)] GetPayments
[24436:24440:1009/213129.947:VERBOSE2:ad_rewards.cc(167)] GET /v1/confirmation/payment/{payment_id}
[24436:24440:1009/213129.949:VERBOSE5:ad_rewards.cc(171)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/payment/68a21b3f-73a9-47fc-ba2b-7b1dce33706a
  Method: BraveAdsUrlRequestMethod::GET
[24436:24440:1009/213130.333:VERBOSE6:ads_service_impl.cc(1101)] URL request started for /v1/confirmation/payment/68a21b3f-73a9-47fc-ba2b-7b1dce33706a
[24436:24440:1009/213130.333:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/confirmation/payment/68a21b3f-73a9-47fc-ba2b-7b1dce33706a
[24436:24440:1009/213130.334:VERBOSE1:ad_rewards.cc(180)] OnGetPayments
[24436:24440:1009/213130.334:VERBOSE6:ad_rewards.cc(182)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/payment/68a21b3f-73a9-47fc-ba2b-7b1dce33706a
  Response Status Code: 200
  Response: [{"month":"2020-10","transactionCount":"1","balance":"0.05"}]
[24436:24440:1009/213130.615:VERBOSE1:ad_rewards.cc(215)] OnGetAdGrants
[24436:24440:1009/213130.615:VERBOSE6:ad_rewards.cc(217)] URL Response:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=68a21b3f-73a9-47fc-ba2b-7b1dce33706a
  Response Status Code: 204
  Response: 
[24436:24440:1009/213130.615:VERBOSE1:ad_rewards.cc(252)] Successfully reconciled ad rewards

Confirm ad rewards are reconciled after claiming an ad promotion
  1. Launch brave with clean profile staging env
  2. Enable rewards
  3. Viewed logs and verified reconciled ad rewards
  4. Restore an Ad grants and Claim Ad grants
  5. Viewed logs and verified reconciled ad rewards
[2692:14060:1008/233355.278:VERBOSE6:ad_rewards.cc(217)] URL Response:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=9c30c754-4d1d-4b83-a3e5-5baea5479cc5
  Response Status Code: 204
  Response: 
[2692:14060:1008/233355.278:VERBOSE1:ad_rewards.cc(252)] Successfully reconciled ad rewards
[2692:14060:1008/233405.882:VERBOSE6:ads_service_impl.cc(1116)] URL request complete for /v1/promotions/ads/grants/summary?paymentId=9c30c754-4d1d-4b83-a3e5-5baea5479cc5
[2692:14060:1008/233405.883:VERBOSE1:ad_rewards.cc(215)] OnGetAdGrants
[2692:14060:1008/233405.883:VERBOSE6:ad_rewards.cc(217)] URL Response:
  URL: https://grant.rewards.bravesoftware.com/v1/promotions/ads/grants/summary?paymentId=9c30c754-4d1d-4b83-a3e5-5baea5479cc5
  Response Status Code: 200
  Response: {"amount":"20","earnings":"20","lastClaim":"2020-07-28T18:17:06.793378Z","type":"ads"}

[2692:14060:1008/233405.883:VERBOSE1:ad_rewards.cc(252)] Successfully reconciled ad rewards


Verification passed on

Brave 1.16.55 Chromium: 86.0.4240.72 (Official Build) dev (64-bit)
Revision 581582174c512f44f44fd1aea340471f54b2365f-refs/branch-heads/4240@{#1134}
OS Ubuntu 18.04 LTS
Verified catalog is downloaded upon browser launch
[3196:3196:1008/182508.730327:VERBOSE1:get_catalog.cc(58)] Download catalog
[3196:3196:1008/182508.730393:VERBOSE2:get_catalog.cc(59)] GET /v3/catalog
[3196:3196:1008/182508.730481:VERBOSE5:get_catalog.cc(65)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v4/catalog
  Method: BraveAdsUrlRequestMethod::GET
[3196:3196:1008/182508.769707:VERBOSE1:get_catalog.cc(83)] Successfully downloaded catalog

Verified Confirm catalog is downloaded every ~2 hours

Verified catalog is scheduled to be downloaded

[4196:4196:1008/182714.003026:VERBOSE1:get_catalog.cc(186)] Download catalog in 2 hours, 30 minutes, 9 seconds at 8:57 PM

Verified catalog is downloaded at that hour:

[4196:4196:1008/205714.474971:VERBOSE1:get_catalog.cc(58)] Download catalog
[4196:4196:1008/205714.475043:VERBOSE2:get_catalog.cc(59)] GET /v3/catalog
[4196:4196:1008/205714.475111:VERBOSE5:get_catalog.cc(65)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v4/catalog
  Method: BraveAdsUrlRequestMethod::GET
[4196:4196:1008/205714.716023:VERBOSE1:get_catalog.cc(83)] Successfully downloaded catalog
Verified catalog download is not started if currently retrying a previously failed download
[6089:6089:1008/185614.429797:VERBOSE1:get_catalog.cc(58)] Download catalog
[6089:6089:1008/185614.432422:VERBOSE2:get_catalog.cc(59)] GET /v3/catalog
[6089:6089:1008/185614.432621:VERBOSE5:get_catalog.cc(65)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v4/catalog
  Method: BraveAdsUrlRequestMethod::GET
[6089:6089:1008/185621.007913:VERBOSE1:get_catalog.cc(92)] Failed to download catalog
[6089:6089:1008/185621.009858:VERBOSE1:get_catalog.cc(168)] Retry downloading catalog in 0 hours, 0 minutes, 0 seconds at 6:56 PM
[6089:6089:1008/185621.018625:VERBOSE1:get_catalog.cc(172)] Retry downloading catalog
[6089:6089:1008/185621.019062:VERBOSE1:get_catalog.cc(58)] Download catalog
[6089:6089:1008/185621.019406:VERBOSE2:get_catalog.cc(59)] GET /v3/catalog
[6089:6089:1008/185621.019780:VERBOSE5:get_catalog.cc(65)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v4/catalog
  Method: BraveAdsUrlRequestMethod::GET
[6089:6089:1008/185621.087267:VERBOSE1:get_catalog.cc(92)] Failed to download catalog
[6089:6089:1008/185621.087349:VERBOSE1:get_catalog.cc(168)] Retry downloading catalog in 0 hours, 3 minutes, 24 seconds at 6:59 PM
[6089:6089:1008/185945.097281:VERBOSE1:get_catalog.cc(172)] Retry downloading catalog
[6089:6089:1008/185945.097359:VERBOSE1:get_catalog.cc(58)] Download catalog
[6089:6089:1008/185945.097423:VERBOSE2:get_catalog.cc(59)] GET /v3/catalog
[6089:6089:1008/185945.097445:VERBOSE5:get_catalog.cc(65)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v4/catalog
  Method: BraveAdsUrlRequestMethod::GET
[6089:6089:1008/185945.341032:VERBOSE1:get_catalog.cc(92)] Failed to download catalog
[6089:6089:1008/185945.341161:VERBOSE1:get_catalog.cc(168)] Retry downloading catalog in 0 hours, 0 minutes, 26 seconds at 7:00 PM
[6089:6089:1008/190011.341042:VERBOSE1:get_catalog.cc(172)] Retry downloading catalog
[6089:6089:1008/190011.341134:VERBOSE1:get_catalog.cc(58)] Download catalog
[6089:6089:1008/190011.341867:VERBOSE2:get_catalog.cc(59)] GET /v3/catalog
[6089:6089:1008/190011.341935:VERBOSE5:get_catalog.cc(65)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v4/catalog
  Method: BraveAdsUrlRequestMethod::GET
[6089:6089:1008/190011.399305:VERBOSE1:get_catalog.cc(92)] Failed to download catalog
[6089:6089:1008/190011.399433:VERBOSE1:get_catalog.cc(168)] Retry downloading catalog in 0 hours, 10 minutes, 14 seconds at 7:10 PM
Verified Confirm unblinded payment tokens are redeemed ~24 hours
[7840:7840:1008/192544.121707:VERBOSE1:redeem_unblinded_payment_tokens.cc(71)] Redeem unblinded payment tokens on Saturday, October 10, 2020 at 1:03:59 PM
Verified unblinded payment tokens redemption is not started if currently retrying a previously failed download

Verified Redeem unblinded payment tokens on is not shown during retrying

[3327:3327:1012/141241.916486:VERBOSE1:redeem_unblinded_payment_tokens.cc(77)] RedeemUnblindedPaymentTokens
[3327:3327:1012/141241.916537:VERBOSE2:redeem_unblinded_payment_tokens.cc(85)] PUT /v1/confirmation/payment/{payment_id}
[3327:3327:1012/141241.916577:VERBOSE5:redeem_unblinded_payment_tokens.cc(92)] URL Request:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/payment/1fcbb84b-0abe-4243-9598-f5e391f04541
  Content: {"payload":"{\"paymentId\":\"1fcbb84b-0abe-4243-9598-f5e391f04541\"}","paymentCredentials":[{"credential":{"signature":"7bQNdaq5loEqHjaO0KN6uHAAeeGVu8I7397YmGiL47HRF+GPhnOObw51eIQK4OdYfPoPyCq1IQeL/VPo8XKBqw==","t":"lLYOC5Llaco1yCFreNEbqVL2/7sJ/iZKzvEqJRobpx/MqKvQW7bnjcaKhYMd7YlHt7hqV0XRgAThkqW62hymJA=="},"publicKey":"bPE1QE65mkIgytffeu7STOfly+x10BXCGuk5pVlOHQU="},{"credential":{"signature":"oYKO4bWdF6WwEYTO2n+hyAfFMmhwtoxWsnYh5lh5p46Wia2Cz5El34nkNTHciwUH13R9T91f0eYrdada0D1fRw==","t":"GAdSbo8FMLH7XGk1V+pS3h3aMOHtXSa3jH8kKW87hlXDlIeHXQp78VsiMxtnPPDmkiNl54b+zyjjsRzCA/PIRQ=="},"publicKey":"lLO5tErGoTK0askrALab6pKGAnBHqELSyw/evqZRwH8="}]}
  Content Type: application/json
  Method: BraveAdsUrlRequestMethod::PUT
[3327:3327:1012/141242.705389:VERBOSE1:redeem_unblinded_payment_tokens.cc(101)] OnRedeemUnblindedPaymentTokens
[3327:3327:1012/141242.705472:VERBOSE6:redeem_unblinded_payment_tokens.cc(103)] URL Response:
  URL: https://ads-serve.bravesoftware.com/v1/confirmation/payment/1fcbb84b-0abe-4243-9598-f5e391f04541
  Response Status Code: 404
  Response: {"status":"ok"}
[3327:3327:1012/141242.705544:VERBOSE1:redeem_unblinded_payment_tokens.cc(107)] Failed to redeem unblinded payment tokens
[3327:3327:1012/141242.705652:VERBOSE1:ads_impl.cc(1487)] Failed to redeem unblinded payment tokens
[3327:3327:1012/141242.705707:VERBOSE1:redeem_unblinded_payment_tokens.cc(128)] Retry redeeming unblinded payment tokens in 0 hours, 3 minutes, 6 seconds at 2:15 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Estimated earnings and Ad notifications are not updating for users
7 participants