What is the list of possible return values for hub.sync.status?


hub.sync.status returns the member “status”

Could we get the list of possible values in order to generate actions on our side?

Hey @Francois, great question! We are working to get these types of things documented, but I can share the status strings here in the meantime. While I can’t guarantee that the full text values won’t change, here are the status strings that you can programmatically check for:

  • {sync-get-remote-changes}
  • {sync-get-local-changes}
  • {sync-remote-error}
  • {sync-local-error}
  • {sync-error}
  • {sync-disconnecting}
  • {sync-begin}
  • {sync-end}

In the list we’ve been stashing away, we’ve also seen:
is there perhaps a firmware difference or API call difference?

Yes, I didn’t share any of the specific error strings, but {registration-failure}
and {extended-network-failure} are still valid, yes.

I am getting additional responses, what is the meaning of the following?

  1. card.wireless → {‘status’: ‘{cell-registration-wait}’, […]
    is that normal, what creates that, how long should it take before something else happens?

  2. hub.sync.status → {‘status’: “TLS domain (a.notefile.net) matches hub’s certificate (*.notefile.net) through wildcard”, ‘sync’: True, ‘requested’: 42}

  3. hub.sync.status {‘status’: ‘waiting for wireless service 33 sec [----] {cell-registration-wait}’, ‘sync’: True, ‘requested’: 157}

  4. hub.sync.status → {‘alert’: True, ‘time’: 1611066637, ‘completed’: 20}
    what is the meaning of “alert”:true?

Thank you!

Hey Francois,

Yes, {cell-registration-wait} is normal, and you’ll see it happen as the Notecard is looking for a tower to connect to. Depending on the radio access technology and coverage in your area, this could be quick, or may take a bit.

Hey Brandon,

Thank you! How about the other items in my list (2,3,4) – since our devices live on the edge of cellular (sometimes over the edge…) it would be great to understand what’s going on with those other messages.

#3 is a variation on number 1 and can happen if the Notecard needs to renegotiate a connection.

#2 indicates that the Notecard has successfully authenticated to the Notehub.

For alert:true good question and I see we don’t have that documented yet. I belive I know what it means, but I need to verify with the team. I’ll update once I get confirmation.

Hi @Francois alert:true indicates that there was a sync error. If the four messages you shared occurred in that order, it may indicate that the sync failed because the device lost its cell connection after connecting to Notehub, but before completing the sync.

did you have a status in your final response as well? That should indicate the reason.