Photos¶
Manage photos on your Ning Network
Properties¶
- id (id) [Read only]
- The unique ID for a photo
- author (screenname) [Read only]
- The screen name of the member who created the photo
- createdDate (date) [Read only]
- The time stamp from the creation date
- updatedDate (date) [Read only]
- The time stamp from the last modification
- featuredDate (date) [Read only]
- When the photo was featured
- title (string) [Read/Write]
- The title of the photo
- description (string) [Read/Write]
- The content of the photo
- visibility (visibility) [Read/Write]
- Can friends see or all members see the photo
- approved (boolean) [Read/Write]
- True if the administer has approved the photo
- commentCount (int) [Read only]
- The number of comments on the photo
- url (url) [Read only]
- URL of the photo’s detail page
- topTags (string) [Read only]
- A array of the most popular tags: [ "food", "apple" ]
- tag (string) [Write only]
- Used during create and update requests to set tags on the photo. Reading from this field is depreciated, instead use the topTags attribute.
Sub-Properties¶
- author.fullName (string) [Read only]
- The full name of the author
- author.iconUrl (url) [Read only]
- The author’s profile photo
- author.url (url) [Read only]
- The author’s profile page on the Ning Network
- image.url (url) [Read only]
- The URL of for the photo
- image.width (int) [Read only]
- The width of the photo
- image.height (int) [Read only]
- The height of the photo
HTTP GET¶
/xn/rest/apiexample/1.0/Photo ¶
Retrieve a specific photo or a specific set of photos, up to 100
/xn/rest/apiexample/1.0/Photo/recent ¶
Retrieve photos sorted by createdDate
Optional Query Parameters:¶
- author (screenname)
- Retrieve photos for a specific user
- private (boolean)
- If true, only retrieve private photos. If you are not the Network Creator, using this parameter will result in a 403 Forbidden error.
- approved (boolean)
- If true, only retrieve approved photos
- tag (string)
- Only include photos with the specified tag
- fields (field)
- Comma-separated list of desired properties, this is only a hint to the server
- anchor (string)
- An opaque token encodes the page of results returned, used in conjunction with count to page through a result set
- count (int)
- Returns one photo by default and supports a maximum of 100. Also supports negative values down to -100 for retrieving photos before the anchor.
/xn/rest/apiexample/1.0/Photo/featured ¶
Retrieve photos sorted by featuredDate
Optional Query Parameters:¶
- author (screenname)
- Retrieve photos for a specific user
- approved (boolean)
- If true, only retrieve approved photos
- fields (field)
- Comma-separated list of desired properties, this is only a hint to the server
- anchor (string)
- An opaque token encodes the page of results returned, used in conjunction with count to page through a result set
- count (int)
- Returns one photo by default and supports a maximum of 100. Also supports negative values down to -100 for retrieving photos before the anchor.
/xn/rest/apiexample/1.0/Photo/count ¶
Retrieve the number of photos created after the given date
Required Query Parameters:¶
- createdAfter (date)
- The ISO-8601 date to start counting after. If the date is more than a week old, a 400 response will be returned
Optional Query Parameters:¶
- author (screenname)
- Retrieve the number of photos for a specific user
- private (boolean)
- If true, only retrieve the number of private photos. If you are not the Network Creator, using this parameter will result in a 403 Forbidden error.
- approved (boolean)
- If true, only retrieve the number of approved photos
- tag (string)
- Only count photos with the specified tag
HTTP POST¶
/xn/rest/apiexample/1.0/Photo ¶
Create a new photo. The request must be sent as multipart/form-data, where the image data is sent as under a part nammed file.