A couple changes to SNO API

Hey everyone,

This is a heads-up that we’re making some changes to the SNO API soon.
From the endpoint for a single satellite:

  1. The uptime field is removed
  2. The online_score field is removed (see 3rd point)
  3. The audits field now uses the same structure as the audits field outputted by the satellites endpoint, which looks like this:

So, if you are using external tools which reference these fields, they may not work anymore.



Appreciate the announcement beforehand! Very thoughtful.

Apart from the move from online_score into audits the output itself does not change?


Actually, I’m glad you asked! It looks like the underlying structure of the audits field has changed, and I missed that. I’ll edit the description above.

1 Like

Does the new description answer your question?

Thanks for the heads up. Does this come with changes to the databases as well? Might need to adjust the earnings script accordingly. Perhaps you could point to the PR?

So for a single satellite this:

Will the onlineScore be added to the audit field os a single satellite too? (since there are both other audit scores)

Or only to the satellites endpoint?

Your working is a bit unclear to me in that point because there is only an “audits” field for satellites but the single satellite has “audit” field and a different structure. But the “audits” field of satellites already contains the onlineScore so probably not what you meant?

Sorry about that. Your picture of the single satellite with the crossed out sections is correct, except that the audit field is now identical to your second picture. Well, except that it won’t be an array, of course.

So in short the “audit” field will get an entry “onlineScore”/it moves into the audit field but no satelliteName obviously. That’s what I assumed, thanks.

We do plan to remove the uptime columns from the DB, yes.
This contains the API changes https://github.com/storj/storj/commit/6ba8f6c8a94eda74e7e4c170f874063a97b13391


So looking at that commit:

This actually means the “audit” field on the “satellite” endpoint is renamed into “audits” and actually includes the name of the satellite.

Now I understand it better, thanks.

@cameron Thanks a lot for announcing it in advance!

Given this, I’m guessing those of us that do depend on the API for extended tracking will need to update those scraper tools ( ie. Prometheus Storj-Exporter ).

What version is this change coming in?

I’m confused.

Frpom what I understand, will go from this:

  "audit": {
    "totalCount": 253,
    "successCount": 253,
    "alpha": 19.999955,
    "beta": 0,
    "unknownAlpha": 19.999955,
    "unknownBeta": 0,
    "score": 1,
    "unknownScore": 1
  "uptime": {
    "totalCount": 567,
    "successCount": 567,
    "alpha": 0,
    "beta": 0,
    "unknownAlpha": 0,
    "unknownBeta": 0,
    "score": 0,
    "unknownScore": 0
  "onlineScore": 1,

to this:

"audits": {
    "AuditScore": 1,
    "SuspensionScore": 1,
    "UptimeScore": 1,
    "SatelliteName": "12tRQrMTWUWwzwGh18i7Fqs67kmdhH9t6aToeiwbo5mfS2rUmo"

With audit counts and alpha/beta values no longer being accessible.

Is this correct?

What’s “AuditHistory” ?

You will find the auditHistory under api/sno/satellite/. It will print out something like {“windowStart”:“2020-12-17T12:00:00Z”,“totalCount”:19,“onlineCount”:18} for the last 30 days with an interval of 12 hours.

1 Like

Thanks for the headsup

  1. If I’m reading this correctly we’re going to loose audit total count and replaced with history that’s only last 30 days? This will make it harder to estimate vetting which takes more then 30 days usually.
  2. Looking at https://github.com/storj/storj/commit/6ba8f6c8a94eda74e7e4c170f874063a97b13391 does this also rename sno/estimated-payout api endpoint to sno/estimated-payouts?

What version is this coming please? Wasn’t in 1.20.2.

@cameron an answer to the last 2 posts would be appreciated. thx

yes, all payout will be payouts now. In one of nearest, updates were finished, they are being tested and will be added in upcoming releases.

To the first point, that is correct. I agree that successful/total number of audits is useful information. @Nikolai_Seidov what do you think about putting those fields back?

To the second point, the name of the endpoint has not changed from what I can see. https://github.com/storj/storj/blob/c44368c489c3aac740df42f5a8af62a5aa115baf/storagenode/console/consoleserver/server.go#L71

The changes are in v1.21.1 which is planned to be deployed today. I apologize for not responding sooner, felt a bit unwell last week :frowning:


No problem, thanks for the answer and get well!