Retrieve External Media

From KickApps Documentation

Jump to: navigation, search

“External media” is a placeholder within the KickApps media database, allowing you to create rows for content that is hosted on your own site or CMS. This feature allows you to add KickApps-powered comments and ratings to non-KickApps content. You can read more about adding external media in the Add External Media section, below.

Your request will look something like the following.

http://api.kickapps.com/rest/externalmedia/{as}

The response payload returns the data and metadata for the specified external media object (similar to the Retrieve Play Page call).

Note:The comments array will only contain the first 100 comments. You should refer to the Retrieve Comments call for accessing the full comment list.

Contents

Parameters

As shown above, your call will include the following parameter:

  • as. The site that you are searching. Each affiliate site has a unique as.

Post Parameters

  • t. String. Required. Your access permissions.
  • callback. String. Optional. The name of your JavaScript callback function.
  • clientIP. String. Optional. Use the clientIP parameter to pass the IP address of the user making the call. If the IP has been blocked by the webmaster under the Affiliate Center -> Manage Members section, an error message will be returned starting with "status":"-1","error":"This IP address has been banned".
  • url. Required. The URL of the media to be returned – this should match the value of the pathToMedia parameter that was included when the external media was added to the database.
  • incrementView. Optional. Either set to true or false, and tells KickApps whether to increment the view count for that item (Default: false).

Payload

On success, a response that begins with "status":"1","error":"" will be returned with the comment objects and media object.

  • comments. The comments object contains a list of all comments that were left on the article.
    • body. Body of the comment.
    • createdAt. The date on which the comment was added.
    • fromUserId. The id for the user who added the comment.
    • isDefaultUserIconUploaded. true or false. True is the webmaster has uploaded a default icon for members.
    • isDisabled. true or false. true if the comment is disabled by the webmaster.
    • isVisible. true or false. true if the comment is visible to the community members.
    • messageId. The id for the comment.
    • pathToPhoto. The path to photo of the commentors profile image.
    • reviewed. true or false. True if the comment has been reviewed by the webmaster.
    • updatedAt. The date on which the comment was last updated.
    • username. Username of the commentor.
  • media. The media object contains all the information about the external media that is being requested.
    • isPublicTaggingAllowed. true or false. true if other users can tag this media.
    • categories. Categories that the emedia belongs too.
    • pathToMedia. This is the original pathToMedia value provided when Add External Media was called.
    • adminTags. The admin tags assigned to this media by the webmaster.
    • views. The number of times the media has been viewed.
    • uploadedByName. The username of the member who uploaded this media.
    • isAdultContent. true or false. true if the media is flagged as adult content.This parameter is no longer in use now.
    • updatedAt. The date on which the media was last updated.
    • country. The name of the country that the media is tagged with.
    • pathToPreview48X48. The profile photo of the user who added the external media.
    • inappropriateFlagCount. The number of times the media was flagged as in appropriate.
    • isRatedByMe. T or F. T if the user making this call has already rated the media.
    • tags. Comma separated list of tags assigned to the media.
    • originalFileFormat. The original file format of the media. This parameter will always be return blank for external media.
    • isFavorite. T or F. T if the user making this call as favorited the media being called.
    • userId. The id of the user who added the media.
    • name. The title of the external media. This parameter is the same as the "title" parameter below.
    • description. The description of the media.
    • createdAt. The date on which the media was created.
    • isVisible. true or false. true if the media is visible to the community members.
    • postalCode. The postal code the media is tagged with.
    • title. The title of the external media.
    • isPublicCommentingAllowed. true or false. true if other members can comment on the media.
    • stateOrProvinceName. The U.S. state or Canadian province of the member who uploaded this media.
    • author. The name of the author of the external media specified when the media was first added.
    • reviewed. true or false. True if the comment has been reviewed by the webmaster.
    • city. The name of the city that the media is tagged with.
    • updatedBy. The id of the member who last updated the media.
    • pathToPreview. This parameter is reserved for future use and will always be returned blank.
    • type. This parameter will always return "externalMedia".
    • uploadToLimelight. This parameter is no longer in use.
    • votes. The number of times the media has been rated.
    • averageRating. The average rating calculated by taking the average of all the ratings assigned to the media.
    • isPrivacyEnabled. True if media is private. false if media is public.

List of KickApps API Calls


Note: Occasionally (and without advanced warning) we modify our API calls by adding new parameters in the response payload. Please keep this in mind when designing your strategy for parsing our responses.