code: private boolean parseAttachmentsArray(String messageString) throws JSONException {
  		JSONObject root = new JSONObject(messageString);
  		if (!root.isNull(KEY_ATTACHMENTS)) {
  			JSONArray items = root.getJSONArray(KEY_ATTACHMENTS);
  			remoteAttachmentStoredFiles = new ArrayList<StoredFile>();
  			for (int i = 0; i < items.length(); i++) {
  				String json = items.getJSONObject(i).toString();
  				JSONObject attachment = new JSONObject(json);
  				String mimeType = attachment.optString("content_type");
  				StoredFile storedFile = new StoredFile();
  				storedFile.setId(getNonce());
  				storedFile.setApptentiveUri(attachment.optString("url"));
  				storedFile.setSourceUriOrPath(attachment.optString("thumbnail_url"));
  				storedFile.setLocalFilePath(attachment.optString(""));
  				storedFile.setMimeType(mimeType);
  				storedFile.setCreationTime(0);
  				remoteAttachmentStoredFiles.add(storedFile);
  			}
  			if (remoteAttachmentStoredFiles.size() > 0) {
  				setTextOnly(false);
  				return true;
  			}
  		}
  		return false;
  	}
docs: /* Parse attachment array in json. Only incoming compound message would have "attachments" key set
  @param messageString JSON string of the message
  @return true if attachment array is found in JSON