private HashMap<String, Object> createJsonMap(Object object) throws IOException {
    // JacksonFactory expects to receive a Map, not a JSON-annotated POJO, so we have to convert the
    // NewMediaItemUpload to a Map before making the HttpContent.
    TypeReference<HashMap<String, Object>> typeRef =
        new TypeReference<HashMap<String, Object>>() {
        };
    return objectMapper.readValue(objectMapper.writeValueAsString(object), typeRef);
  }
GoogleMusicHttpApi makes HTTP requests to read and write to the public Google Music's "Music
Library" APIs, following its documentation at
https://developers.google.com/youtube/mediaconnect.

<p>Note that this is the lowest level of Google Music interaction - that is, you probably don't
want to use this class and are better off using something like a bit higher level like the Google
Music DTP Exporter and Importer instead.
extensions/data-transfer/portability-data-transfer-google/src/main/java/org/datatransferproject/datatransfer/google/music/GoogleMusicHttpApi.java