title: Facebook Filtering New Page Experience
body: <p>As some of you may know Facebook is migrating its users pages progressively to what is called the &quot;New Page Experience&quot; (NPE), the thing is some previous endpoints and data such as &quot;locations&quot; are not available by the same means anymore, for NPE you need to use the page token.</p>
  <p>In my case, I used to do the following query on the facebook-graph-api with a facebook user token:</p>
  <pre><code>me/accounts?fields=access_token,category,tasks,name,is_published,locations.limit(100){access_token,category,name,is_published,parent_page}
  </code></pre>
  <p>This returned a JSON array with all the pages linked to the account of the user token, and the associated locations for each page.
  However since the New Page Experience partial migration, if at least one page has been migrated to New Experience by Facebook, the whole call returns an error</p>
  <pre><code>    {
        &quot;error&quot;: {
          &quot;message&quot;: &quot;Invalid OAuth 2.0 Access Token&quot;,
          &quot;type&quot;: &quot;OAuthException&quot;,
          &quot;code&quot;: 190,
          &quot;error_subcode&quot;: 2069032,
          &quot;is_transient&quot;: false,
          &quot;error_user_title&quot;: &quot;Token d’accès utilisateur non pris en charge&quot;,
          &quot;error_user_msg&quot;: &quot;Un token d’accès de Page est requis pour cet appel dans la nouvelle version des Pages.&quot;
      }
  </code></pre>
  <p>Facebook has added a boolean field on pages called <code>has_transitioned_to_new_page_experience</code>, which should allow us to filter the pages.</p>
  <p>However it doesn't seem to work, I've tried thing such as (true, 1, &quot;true&quot;...) which do work for other boolean parameters but not for <code>has_transitioned_to_new_page_experience</code> :</p>
  <pre><code>me/accounts?has_transitioned_to_new_page_experience=true // return all pages without filtering
  me/accounts?is_place=true // Filters properly based on if the page is a place
  </code></pre>
  <p>I'd like to be able to single out the NPE, or do a filtered query to avoid needless calls through loops and array management, as most of the pages are still not NPE yet, and this would allow me to keep my code for &quot;legacy pages&quot; untouched.</p>
  <p>Have any of you experienced this issue, or been able to solve it?
  Maybe talk with the Facebook dev support?
  Do you think this behavior is buggy?
  Thanks!</p>