Discussion Forums  >  Uncategorized

Replies: 53    Views: 1279

TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
04/25/11 11:49 AM (13 years ago)

Trouble setting up Flickr image gallery

Hello! I can't seem to wrap my head around the JSON url. The problem is, when googling how to set this up (and looking at buzztouch docs), none of them seem to mesh. Buzztouch provides an example about how to pull from a search query. However, I just want to pull from my own photostream. Most JSON examples look nothing like the url, but rather have the url embedded in a lot of html? code. I found one example that seemed to fit my needs, and using my own Flickr ID (not API) I came up with http://api.flickr.com/services/feeds/photos_public.gne?id=50465793@N05&lang=en-us&format=json&jsoncallback=? - - - - however, this gives me an Error (parsing config data, make well-formed). I could not for the life of me find any example of a JSON url that used the API key like Buzztouch showed. I feel a little stupid, but what am I missing? I just want an image gallery that shows my photostream (that way I can use the new email uploader to automatically add to it). Thanks in advance
 
erichopf
buzztouch Evangelist
Profile
Posts: 316
Reg: Mar 14, 2011
NY, NY
3,460
like
04/25/11 12:00 PM (13 years ago)
Hoogler, The url isn't in a JSON format. You must use a PHP script that translates the input values into a logical system for the app to read. What you have is an RSS feed. Use this in the URL field- http://api.flickr.com/services/feeds/photos_public.gne?id=50465793@N05&lang=en-us Connect this feed with a left button that leads to the image upload screen. You should use the RSS type of screen. Let me know if you have any more questions.
 
TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
like
04/25/11 12:24 PM (13 years ago)
Please bear with me, I'm fairly illiterate when it comes to scripts. Lets focus on making the image gallery work. The Buzztouch documentation says: Flickr™ photo feeds are very flexible. When using Flickr™ feeds, you must set the output to JSON. A sample feed that pulls 25 public images associated with the keyword “Golf, Tennis, Bowling” looks like this: http: //api.flickr.com/services/rest/?&method=flickr.photos.search&api_key=API-KEY-GOES-HERE&format=json&tags=Golf, Tennis, Bowling&privacy_filter=1&content_type=1&per_page=25 So, when I was trying to put together a url that would lead to an image gallery, I tried finding a model that was similar to this sample url. How would I go about making a url like this that directs to my photostream, rather than a search query? (When browsing the internet, i couldn't even find a single example of a url like the one Buzztouch shows, which is what is puzzling)
 
erichopf
buzztouch Evangelist
Profile
Posts: 316
Reg: Mar 14, 2011
NY, NY
3,460
like
04/25/11 12:46 PM (13 years ago)
Hoogler, I don't use Flickr on my apps, so I had to review the file again in reference to that Yahoo service. This is a complicated issue, the URL is in the RSS formt, or Really Simple Syndication syntax. It's best if you follow the directions. They worked for me after getting the API key. You should try that route, it's a but of work bit it is very functional.
 
TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
like
04/25/11 01:01 PM (13 years ago)
What directions? - - - full document (http://www.buzztouch.com/docs/v1.5-imageGalleryData.pdf) I can easily set up an RSS feed using the RSS page, but I want a full screen image gallery. I'll resort to the RSS feed if I can't find an answer. I already have an API key, but I can't find how to utilize that in developing a URL that leads to my photostream, not a search query. The Buzztouch docs say build a URL for the feed (Which is apparently an RSS URL but told to output to JSON?), and it gives an example of one using a search query. It doesn't actually tell you how to construct the URL. Having spent a couple of hours on google, I can't find any example similar to BT's, except the one I mentioned in my first post (which apparently is an RSS url, even though the source says its referring to JSON). I know the URL string will have to change in order to point to my own photostream, and that's what I can't find. David, what am I missing? Am I really looking for a JSON output, or an RSS output? Thanks.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
04/25/11 01:40 PM (13 years ago)
To start, you'll need to set up a Flickr app to get an API key of your own. After that, you'll need to get a URL like this one: http://api.flickr.com/services/rest/?method=flickr.groups.pools.getPhotos&api_key=PUT_KEY_HERE&group_id=PUT_GROUP_HERE&per_page=25&format=json Put that URL into the ADVANCED GALLERY PROPERTIES under SCREEN DATA URL. Leave the IMAGE FILENAME and IMAGE URL blank to draw images from Flickr. Hope that helps!
 
erichopf
buzztouch Evangelist
Profile
Posts: 316
Reg: Mar 14, 2011
NY, NY
3,460
like
04/25/11 01:51 PM (13 years ago)
Sorry, I forget that other people her are coming from other fields and that a few bits and pieces are not enough to explain some processes that are not straight forward. I'll give it a go and see what I come up with. I am sure David will chime in when he gets free time. If he doesn't, I'll do my best to point you in the right direction. Check out this thread to see what one user used for his source URL.
 
TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
like
04/25/11 02:04 PM (13 years ago)
@phaques I have an API key of my own. It was the first thing I did. But, where did you get that URL? That's the question I've been asking. The URL you just posted refers to a group post, and not an individual photostream. If you can tell me how you found that URL (or made it) we might be able to solve this. I'm looking to create a URL just like that, except in reference to an individual photostream. Thanks.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
04/25/11 03:15 PM (13 years ago)
http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=PUT_API_KEY_HERE&user_id=50465793@N05&per_page=25&page=1 Try that out with your API key inserted into it. You can modify the per page and page numbers at the end of that string or just omit them entirely. For any other API calls you'd like to look into, check here http://www.flickr.com/services/api/ Anything listed on the right is a function you can use with your API key. Once you've found something you like, click on it and then click the link at the bottom of that page to help you set up all of the required information. Then, copy, paste and edit the API key in the URL that is displayed at the bottom of that resulting page. Good luck!
 
TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
like
04/25/11 03:45 PM (13 years ago)
@phaques There was a problem parsing some configuration data. Please make sure that it is well-formed. By the way, I really appreciate the help. I got this error though, is there someplace I need to put the secret number as well? I had seen the API page with all the modifications you could make, but I didn't see how to add those to the URL. I'll take a closer look at the bottom of the page to look into setting it up. Thanks again! I'll keep trying to fix this. Edit: I found that bottom of the page link. Its like a URL builder! I just have to find the right one. Thanks again!
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
04/25/11 03:55 PM (13 years ago)
You should not need the secret key. Just want to make sure that: - You've put your API key into the URL where I currently have PUT_API_KEY_HERE. - You've put that entire URL into the SCREEN DATA URL under ADVANCED GALLERY PROPERTIES. - You have NO photos in the list at the top of your screen page. Also, try putting the URL with your API key into the browser. Does it return a list of 9 photos?
 
TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
like
04/25/11 04:19 PM (13 years ago)
I tried putting the URL into the browser, and it wouldn't load anything. Here's the completed URL with API http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=6c66f50ccbe8efb1b3df0352e2518579&user_id=50465793@N05&per_page=25&page=1 I have the red box confirming my gallery has no images and I put this URL in the Data URL spot. What stupid thing am doing wrong? :P
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
04/25/11 04:24 PM (13 years ago)
 
TheHoogler
I hate code!
Profile
Posts: 152
Reg: Feb 10, 2011
Anchorage, AK
1,520
like
04/25/11 04:29 PM (13 years ago)
I will now compose an epic tale in your honor, good sir! (it worked)
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/21/11 08:29 PM (12 years ago)
I'm trying to do this in my app and I've used the example above but I get the There was a problem parsing some configuration data. Please make sure that it is well-formed. What am I missing?
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
09/22/11 07:34 AM (12 years ago)
Can you post the URL that you are using?
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 08:50 AM (12 years ago)
This what I was trying to use.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
09/22/11 08:57 AM (12 years ago)
That user id is not valid. That's why you're getting the format error. Are you trying to display an individuals photos or a groups photos? You can always check the JSON output by putting the URL into your browser and seeing what is displayed.
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 08:58 AM (12 years ago)
I am trying to use an individual's photostream
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 08:59 AM (12 years ago)
Maybe I have the wrong user id. When I plug it into the browser it says user not found
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
09/22/11 08:59 AM (12 years ago)
What's the URL to their photostream?
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 09:00 AM (12 years ago)
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
09/22/11 09:03 AM (12 years ago)
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 09:05 AM (12 years ago)
Awesome. I'll give it try when I get home. I appreciate it!
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 09:09 AM (12 years ago)
Where do I get the full user ID, if I choose to use another gallery in the future. Sorry for the stupid questions!
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
09/22/11 09:09 AM (12 years ago)
After you try it and if it works, go back and edit out your API key from the previous posts. You don't want others to use that.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
09/22/11 09:11 AM (12 years ago)
The most consistent method for finding it is to click on the email icon in their page and extract the id which will always have the @ symbol in it from the URL.
 
mitchellapps
Aspiring developer
Profile
Posts: 170
Reg: Aug 15, 2011
St. Louis
4,300
like
09/22/11 09:11 AM (12 years ago)
Ok, thanks!
 
stoneypointe
Apple Fan
Profile
Posts: 162
Reg: Jul 30, 2011
Miami, Florida
1,620
like
10/14/11 11:32 AM (12 years ago)
Hi there I am able to display images from my flickr account by using the url format below: http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=API_KEY_HERE&user_id=USER_ID_HERE&per_page=25&format=json Now I have a question due to the fact that I don't have a great understanding of how flickr works. This is what I did: I created an app and added 6 photos to the screen and these are the only photos that I see on my BT photogallery. But I don't want those images there, I want to display the images from my photo stream. What am I missing? Thanks lot A.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
10/14/11 01:01 PM (12 years ago)
You can't have it both ways in that screen, you either use the images you include or from your flickr photostream. Go back into that screen and remove all other images and put that entire URL into the SCREEN DATA URL under ADVANCED GALLERY PROPERTIES.
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/20/11 02:41 PM (12 years ago)
Is it possible to pull an private Flickr images stream into BT image gallery? I had tried and it does not work. I am currently pulling my public gallery.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
10/20/11 03:06 PM (12 years ago)
It may be possible but it would probably require authorization in the API setup.
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/20/11 03:07 PM (12 years ago)
What kind of authorization?
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
10/20/11 03:10 PM (12 years ago)
Basically depending on what method you are trying to use for getting photos, you build the API call with authorization and it authenticates that API call as if you were logged in. The photos have to be visible but doesn't seem to matter if they are public or private. They just need to be not hidden. Start here: http://www.flickr.com/services/api/flickr.people.getPhotos.html
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/20/11 03:12 PM (12 years ago)
Thank you. I will check that. M.
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/22/11 05:46 PM (12 years ago)
@got fox? I followed what you suggested. I have 4 images in my photostream that are set to private only visible to friends and I can't get any images. This is the format that I am using: http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=mykey&user_id=myuserid&isfriend=1&per_page=25&format=json Do you see anything wrong here? Thanks in advance
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
10/22/11 05:58 PM (12 years ago)
You can't get private photos from the getPublicPhotos call. Go here and fill out the form with the user ID you want to pull from, use privacy filter 2 for private visible to friend, output to JSON, sign call as you with full permissions. Then click on CALL METHOD. If the output looks good, use the URL under that output box. It contains all of that data in the proper string and has your authorization token required to get those private photos. http://www.flickr.com/services/api/explore/flickr.people.getPhotos
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/23/11 01:09 PM (12 years ago)
@got fox? It worked really well. Thank you!
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/24/11 12:51 PM (12 years ago)
Ok, I am back. @gotfox?: Yesterday the gallery was working great.. The output was set to JSONP. This morning when I checked the app it was not working and when I tested in the browser I got a incorrect token error So i changed the output to JSON and still does not work. The interesting thing is that it does work on the browser. I know that I am not suppossed to display the string here but I will create a new app later. Here it is: http://api.flickr.com/services/rest/?method=flickr.people.getPhotos&api_key=a700e897062c479d11b14ad1ebf45c6b&user_id=68946289%40N05&privacy_filter=2&format=json&nojsoncallback=1&auth_token=72157627967578030-b1c6c2338883aeba&api_sig=3f4e5bae6d8e6c7c5c7c4d07878aa880 Any thoughts Thanks Alejandra
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
10/26/11 05:48 PM (12 years ago)
Go through the process again but in the URL, change the %40 in the user ID back to @. Your browser definitely knows how to translate that but the app may not. See if that works.
 
Alejandra
Apple Fan
Profile
Posts: 71
Reg: Oct 05, 2011
Miami
710
like
10/26/11 06:21 PM (12 years ago)
Hi gotfox Thank you for getting back. Tried that but it did not work. Alejandra
 
Bellossom
Lost but trying
Profile
Posts: 3
Reg: Oct 20, 2011
Adelaide
30
like
10/28/11 04:26 AM (12 years ago)
Hi guys, This might be a silly question, but is there a little snippet bit like &per_page=25 that I can add to my flickr api calling web link JSON thingy-ma-bob that calls only commercially available for use images? I can do an advanced search on the site to look for such things, so I'm hoping there's something available in the api :) Thanking you for your time, Jaimee
 
Bellossom
Lost but trying
Profile
Posts: 3
Reg: Oct 20, 2011
Adelaide
30
like
10/28/11 04:33 AM (12 years ago)
Oh, and to specify that I want the 'small' version of the image. I've looked at the api site but it leaves me a little confused :P
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
10/28/11 08:55 AM (12 years ago)
@Alejandra I'm not certain what more to try. Can you look in your console output and see the feedback there. Perhaps that can lead us to a resolution. Does the app give you an error on screen or just doesn't display? @Bellossom You're looking to search all available photos? And by commercial, do you mean photos that are covered by a Creative Commons License that allows you to use them?
 
sepala
Aspiring developer
Profile
Posts: 196
Reg: Nov 23, 2011
London
3,060
like
12/05/11 07:07 AM (12 years ago)
Thanks so much got fox?! I used your example here: http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=API_KEY_HERE&user_id=USER_ID_HERE&per_page=25&format=json to get my photo stream and it worked perfectly!
 
Beta Labs Develope...
Android Fan
Profile
Posts: 17
Reg: Nov 23, 2011
Singapore
170
like
12/11/11 11:45 PM (12 years ago)
I've got a problem here, I tried to add the my flickr url http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=238081144b414658cf725c064e098635&user_id=71792394@N08&per_page=25&format=json into the data URL under advanced blablabla, I tried to view it on my android application and it showed Look at the BT_Images.java file any fix? I need to prepare this app by 2 Jan
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
12/12/11 08:20 AM (12 years ago)
As far as I know, at this point, that screen is not complete in the Android package for 1.5. So, that means you'll have to wait for the Buzztouch gang to get back on the development phase.
 
erickgrau
Aspiring developer
Profile
Posts: 8
Reg: Dec 18, 2011
NYC
80
like
12/24/11 05:12 PM (12 years ago)
I can get the above example to work, however if I try to add another item for user gallery - I get a parsing error. http://api.flickr.com/services/rest/?method=flickr.galleries.getphotos&gallery_id=72157628555345423&api_key=6a107ea3afc76c7ef18691b820343d25&user_id=16941673@N08&format=json Anyone care to advise?? thanks!! Erick
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
12/26/11 09:37 PM (12 years ago)
@erick When I try to validate that url (by opening it in my browser window), I receive an error stating that the gallery ID doesn't exist. That's the reason you'll receive a parsing error. Get that fixed and you should have no issues.
 
thearist
Aspiring developer
Profile
Posts: 3
Reg: Oct 24, 2011
Denver
30
like
01/07/12 01:23 AM (12 years ago)
I've also attempted the fixes above only to be met with the parsing error. I don't get any errors in a browser or when Flicker creates the URL for me using their API tool. I've tried public photos, private photos, etc with no luck. Any advice on next steps?
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
01/07/12 01:03 PM (12 years ago)
@thearist Can you post the whole URL you are trying to use? Once I look at it to try and figure out errors, I'll post back and then you can remove the URL from the post. Without all of the information, I can't really help you out.
 
thearist
Aspiring developer
Profile
Posts: 3
Reg: Oct 24, 2011
Denver
30
like
01/09/12 10:42 PM (12 years ago)
@got fox? I tried a few variations of the flickr api, this is the latest version which is returning the parsing error. Thanks in advance for taking a look.
 
gotfox
buzztouch Evangelist
Profile
Posts: 146
Reg: Feb 05, 2011
Las Vegas
8,460
like
01/10/12 08:51 AM (12 years ago)
First, when I put that URL into my browser, it doesn't even authenticate. Second, you shouldn't have to do any sort of authorization token at all. Third, flickr claims that your API key is not valid. Go back through the setup here http://www.flickr.com/services/api/explore/flickr.people.getPublicPhotos and enter the user ID you want, output as JSON and select Do not sign call? with any other options you want. Click on the Call Method button and see what is output in the window at the bottom. If that validates, then copy and paste the URL string below all of that into your browser address bar. If that still displays properly, then paste it into your screen on BT. You shouldn't have any problems at that point.
 
thearist
Aspiring developer
Profile
Posts: 3
Reg: Oct 24, 2011
Denver
30
like
01/10/12 12:53 PM (12 years ago)
I copied the URL from the BT image gallery. You're right that's not my key so did BT alter the URL? This is what I get from Flickr. http://api.flickr.com/services/rest/?method=flickr.people.getPublicPhotos&api_key=e9919d630c8bdbf9e279e0cfad059af9&user_id=59810393%40N04&format=rest Do I change %40 back to @ for the user_id when pasting into BT?
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.