YM REST Services

<back to all web services

CommunityPhotos

Requires Authentication
Requires any of the roles:admin, oauthadmin
The following routes are available for this service:
GET/Ams/{ClientID}/CommunityPhotos/{PhotoId}Return the data for a photo including comments.
PUT/Ams/{ClientID}/CommunityPhotos/{PhotoId}Update a photo.
CommunityPhotos Parameters:
NameParameterData TypeRequiredDescription
PhotoIdpathintNo
CaptionbodystringNo
PostedBybodystringNo
BaseDto Parameters:
NameParameterData TypeRequiredDescription
UsingRedisformboolNo
AppInitTimeformDateTimeNo
ServerIDformstringNo
BaseSharedDto Parameters:
NameParameterData TypeRequiredDescription
ClientIDformintNo
ResponseStatusformResponseStatusNo
BypassCacheformboolNo
DateCachedformDateTimeNo
DeviceformDeviceNo
CommunityPhotosResponse Parameters:
NameParameterData TypeRequiredDescription
PostedUTCformDateTimeNo
PostedByMugshotformstringNo
ShareCountformintNo
LikeCountformintNo
CommentCountformintNo
PhotoCommentListformList<PhotoComment>No
PhotoComment Parameters:
NameParameterData TypeRequiredDescription
CommentIDformintNo
CdbIDformintNo
PostedformDateTimeNo
PostedUTCformDateTimeNo
GalleryItemIDformintNo
SchoolIDformintNo
CommentformstringNo
PostedByformstringNo
PostedByMugshotformstringNo
PostedDateformstringNo
GroupIDformintNo
IsOwnerformboolNo
LikeIDformintNo
LikedCommentformboolNo
LikeCountformintNo
SkipCrossPostformboolNo

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

PUT /Ams/{ClientID}/CommunityPhotos/{PhotoId} HTTP/1.1 
Host: ws.yourmembership.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"PhotoId":0,"Caption":"String","PostedBy":"String","UsingRedis":true,"AppInitTime":"2024-05-03T04:57:17.4939187-04:00","ServerID":"WS-5-59-079","ClientID":0,"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"BypassCache":false,"DateCached":"2024-05-03T05:32:03.2254839-04:00","Device":"Desktop"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"PostedUTC":"0001-01-01T00:00:00.0000000","PostedByMugshot":"String","ShareCount":0,"LikeCount":0,"CommentCount":0,"PhotoCommentList":[{"CommentID":0,"CdbID":0,"Posted":"0001-01-01T00:00:00.0000000","PostedUTC":"0001-01-01T00:00:00.0000000","GalleryItemID":0,"SchoolID":0,"Comment":"String","PostedBy":"String","PostedByMugshot":"String","PostedDate":"String","GroupID":0,"IsOwner":false,"LikeID":0,"LikedComment":false,"LikeCount":0,"SkipCrossPost":false}],"PhotoId":0,"Caption":"String","PostedBy":"String","UsingRedis":true,"AppInitTime":"2024-05-03T04:57:17.4939187-04:00","ServerID":"WS-5-59-079","ClientID":0,"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"BypassCache":false,"DateCached":"2024-05-03T05:32:03.2411175-04:00","Device":"Desktop"}