How to speak the language of Facebook
Facebook is a database.
Every person that you search and every post, photo, or detail on their About page has a unique Facebook ID (FBID). These ID numbers are what distinguish Facebook Graph Search from the other search techniques available on Facebook.
Facebook launched Graph in March 2013 and killed it just over a year and a half later. And that actually makes sense. Facebook’s native Search Bar tends to shepherd users to results that will help them expand their local, personal networks. There are a lot of things that you can’t query via Search Bar and these limitations can feel like stumbling blocks to researchers.
For a very short time Facebook Graph allowed anyone to search outside of these results. You could steer the direction of search by selecting a broad characteristic on the Facebook Graph widget. For example, you could look for people who shared a connection with a place, a page, a school, employer, or job title. But, in the background, what you were actually doing was helping this widget find and select the Facebook page assigned to that place, school, employer, or job title. These pages serve as placeholders for their respective Facebook IDs. The widget built your queries using these IDs and the URL of your search results would reference the IDs like this:
Photos taken in Dodger Stadium and the photo upload date was last month
Facebook Graph never went away
The Graph widget disappeared in December 2014, but this change was fairly cosmetic. Everything that made Graph Search possible still exists. Profiles, Places, Employers, and Job Titles still have unique IDs. The search engine still processes these IDs and the query language that you can see in Search URLs like the one shown above. and the query strings that connected them are still in use. Many of these query strings can be observed in the HTML source of Facebook.com like the ones shown below.
The language of Facebook is relatively straight forward. For example, the query /photos-in/tasks the search engine to probe the Photo Index for images that were tagged to a specific place. This Place has an ID. So, we can search for /photos-in/ a place or /photos-by/ a person that were taken in the place. The /photos-by/ query probes for images uploaded by a specific Profile based on the ID we attach to it.
When you take a closer look at our Search URL example, you’ll see that it reads like a question , but these queries read from right to left like this:
Photos taken in Dodger Stadium (130938320283723) and the photo date was last month
Once you see the structure, you can easily modify the question through the URL. For example, you could change the time frame for these photos from /last-month/ to this month by using the query /recent/. Facebook’s search engine responds to this change by delivering photos uploaded this month. You could continue to modify the question by altering the time from again, such as /last-month/ or /2015/, or specifying the Profile that uploaded the images.
Facebook Graph always ended Search URLs containing multiple queries with an /intersect/. This, too, is a query. It directs Facebook to only deliver results where all of the conditions exist, such as the Photos at Dodger Stadium and the Photos Dated Last Month. We’ll use it to sort and refine our results.
The Zen of Venn
When it comes to Facebook Graph, think Venn Diagram. When you’re using Graph you’re usually looking for connections or things that share something in common. There is some mindfulness to selecting these connections.
Facebook is a database of connections and there are three Objects in this diagram that we’re connecting: a Profile, Photos, and a Place. This diagram illustrates how we’re refining these connections to a specific subset of data: Photos by a Profile at a Place Last Month.
Photos can be attached to both a Person and a Place, though the Person who uploaded it owns it.
We explained how to find the IDs for our search in a previous post. The easiest way to find an ID is through the URL of a Profile or Cover image. Each image has its own ID which normally follows the term “fbid=.” This PhotoID is often followed by the AlbumID where it is located. This album follows the letter “a” in the URL. The Profile or Page that owns the album and uploaded the photo will be the last set of numbers following this AlbumID.
For some uploads, the Profile ID is found in the URL next “pb” for photos or “vb” for videos.
Verifying the ID is also easy. Simply place the ID in the URL next to Facebook.com/ or FB.com/ and the browser will redirect to the Profile or Page.
Facebook Graph never went away. The queries and the IDs that made it possible are still in place.
My book series Facebook Search explains the nuts and bolts of how Facebook Search works. It contains hundreds of search examples and multiple techniques for finding IDs and People. The practical exercises and flowcharts make it a an excellent desk reference as well.
Facebook Graph can still deliver the results you want with hundreds of options once you understand the language of Facebook.