Forum Discussion

Former Member's avatar
Former Member
2 years ago

failed to DecodeSACCredentials: unexpected end of JSON input

A few days ago, my op commands started returning the following error:

failed to DecodeSACCredentials: unexpected end of JSON input

The only op command that currently works without issue is op signin

I've seen this issue come up in previous discussions, but it seems that the the solution was to upgrade to v2.19.0


1Password Version: 2.19.0
Extension Version: Not Provided
OS Version: macOS 13.5
Browser: Not Provided

3 Replies

  • Former Member's avatar
    Former Member

    Ah, didn't realize you were responding too @Michael_1P -- glad we arrived at the same conclusion! 😀

  • Former Member's avatar
    Former Member

    Hi @codycrossley, I think you are https://developer.1password.com/docs/service-accounts/get-started/#use-a-service-account-with-1password-cli, yes? Could you make sure that the token is valid/correct?

    Could you also share the full command that you are running at the moment?

    Best,
    Arun

  • Hi,

    Do you happen to have the OP_SERVICE_ACCOUNT_TOKEN environment variable set? This error indicates that the CLI is attempting to decode the service account JWT but is failing because it is incomplete or malformed. You could try updating the OP_SERVICE_ACCOUNT_TOKEN to a valid token, or just unsetting the environment variable and using op signin again.

    Let me know if that works.

    Thanks,
    Mike