Skip to content
CCPEDIAby Unity Nodes
App Development

`Missing applicationId in access token` error

3 posts333 views6 likesLast activity Jul 2021

  1. gyorgybalazsiOP 1

    I get this error when using an access token with the following payload:

    {
            "https://daml.com/ledger-api": {
              "ledgerId": "cc38051f-364d-4e13-be6a-4cc536ef69f1",
              "participantId": null,
              "applicationId": null,
              "admin": false,
              "actAs": ["ledger-party-beszerzes"],
              "readAs": ["ledger-party-beszerzes"]
            },
            "exp": 1893455999
            }
    

    Also tried omitting the null fields, or set an arbitrary applicationId.

    Also, I don’t know where my React app is using the applicationId when I specify it.

    I’m still debugging the React call mentioned in an earlier question: Could you help me debug a React `exerciseByKey` call?

  2. cocreature 3

    The JSON API requires that the applicationID is present. There is no way around this atm. You need a token with this field set. If you do not are about the value, you can use something more or less arbitrary provided it is a valid ledger string (1-255 characters, characters must be ascii alphanum or one of the following ._:-#/ ).

    The gRPC API accepts tokens without an application id but you have to specify one in the payload when submitting a command.

  3. gyorgybalazsi 2

    Thanks, now it works.