Which `--port` to use in `daml ledger upload-dar` with a canton ledger?

Specifically, daml ledger upload-dar takes the --port flag, and a canton ledger has at least 4 ports:

  • admin-api.port of the participant
  • ledger-api.port of the participant
  • public-api.port of the domain
  • admin-api.port of the domain

So which one would I upload dar files to?

You need the ledger API port. so ledger-api.port.

Thank you so much!

Same question for the --ledger_port flag of daml script. I assume that’s also ledger-api.port, right?

Thanks again,
mesch.

Yes, in general any generic ledger tooling (all daml ledger commands, daml script, triggers, json api, …) always talks to the ledger API port. Only once you get to the Canton console or other canton specific stuff do you have to worry about the other ports.

Thanks!