Q:

How can I read the android sdkmanager output so I can install a package?

The android sdkmanager tool has a way to almost list the available packages, like so:
$ sdkmanager --list

  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...-10;default;x86 | 4            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 2            | ARM EABI v7a System Image
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...15;default;mips | 1            | MIPS System Image
  system-images;a...-15;default;x86 | 4            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...16;default;mips | 1            | MIPS System Image
  system-images;a...-16;default;x86 | 5            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 5            | ARM EABI v7a System Image
  system-images;a...17;default;mips | 1            | MIPS System Image
  system-images;a...-17;default;x86 | 3            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...-18;default;x86 | 3            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...

I would like to understand how I can actually read the output so I can install one of those packages from the command line.

A:

You need to use the --verbose flag to get full package names:
sdkmanager --list --verbose

The output will be looking like this:
system-images;android-25;android-wear;armeabi-v7a
    Description:        Android Wear ARM EABI v7a System Image
    Version:            3
    Dependencies:
        patcher;v4

system-images;android-25;android-wear;x86
    Description:        Android Wear Intel x86 Atom System Image
    Version:            3
    Dependencies:
        patcher;v4

system-images;android-25;google_apis;arm64-v8a
    Description:        Google APIs ARM 64 v8a System Image
    Version:            4

system-images;android-25;google_apis;armeabi-v7a
    Description:        Google APIs ARM EABI v7a System Image
    Version:            4

system-images;android-25;google_apis;x86
    Description:        Google APIs Intel x86 Atom System Image
    Version:            4

system-images;android-25;google_apis;x86_64
    Description:        Google APIs Intel x86 Atom_64 System Image
    Version:            4

