No data returned though I'm in Deezer country - deezer

I'm building a wepp app from Sweden. And I want to access the Deezer api to search for music. I have registered an app and I am a premium user.
But still when I run my queries from my server on GoDaddy it doesn't work. But the server in Sweden works with the same code.
Is there any way I could get the data on the Godaddy server or do I need to move everything to the server in Sweden?

If your server is located in the US or another country where Deezer's not live yet, you won't get results.
You can work around that issue by passing an access_token parameter with the request. If the access_token is associated with a Premium+ user who registered in a Deezer live country (e.g. Italy for example), the request will take the user country associated with the token into account. Therefore, it will return results.
That above workaround isn't working for free users.

Related

User data in event for Facebook server to server

I plan to generate Facebook events (Conversion API) on server side when the user completes registration process. These events will be used for advertising my solution in Facebook and tuning target audience on registration events.
I use POST request to https://graph.facebook.com/v9.0/289777498957502/events to send events. I have to pass user_data entity inside a body of this request. This user data can be email address, click id, user IP address or something else.
I don't have any of these on server side but I can get it.
The problem is that I don't understand why Facebook needs user data and what exactly it needs as data. I can send everything to Facebook but I need to understand mandatory information it requires.
Do you know what should be sent as user data?
As an option I can send internal ID in my system of each user inside user data but I'm not sure Facebook will be happy with that.
Facebook manuals are a pure joke. Literally all are outdated and no information on user data content and why it's required.
The problem is that I don't understand why Facebook needs user data
Because your conversion is (ideally) supposed to get connected to an actual user account. Facebook knows, who the user is, as long as we are on the client side, and their pixel is embedded somewhere - they can make the cross-domain requests in the background, to see who is currently logged-in to Facebook on the device. But if you send conversion data later, from your server - how would they be supposed to associate that with a specific user then, if you don’t send them any data that could identify one?
and what exactly it needs as data.
If you have anything that can uniquely identify the Facebook user, then send that.
Otherwise, send as much data as you can – to increase the posibility, that Facebook will be able to match this to a specific individual.
Check the list they provide under https://developers.facebook.com/docs/marketing-api/conversions-api/parameters/customer-information-parameters
If the user is logged in to your Facebook app while they are on your site, then send the fb_login_id – that is as unique and specific, as can be.
If you don’t use Facebook login on your site, or the user can also perform the action in question without being logged into your Facebook app - then send whatever you have, that identifies them on your end.
In case no unique match is possible, then send as much as possible - first & last name, phone number, date of birth - all those help to narrow down who the user might be on Facebook’s side.
The same data, or at least as much of it as is available at this time, should also be send with the pixel tracking code on the client side already. https://developers.facebook.com/docs/facebook-pixel/advanced/advanced-matching/ has details on that.

signature request API wrong url

When I do a Paypal API signature request under business profile, the generated api is using my old website ---whateverAPI.my-old-website.com
I've updated all of my business information and see no instances of the old url in my paypal account or the developer or sandbox accounts.
I do not have the old login information for developer area where I created the original API information as it was changed to my new login/business.
I need to change the URL associated with my account so the api generated has the apicode.new-website.com
I know this is a low level expertise for most of you compared to what you are coding but I am completely stuck and have tried everything I can think of.
Thanks for taking the time to read!
When the API is first requested on an account, it is generated based on the email address associated with the account at the time. Even if you remove the email address and request new API credentials, it will still use that original email address. There is no need for concern, you only set this in your API call or in your shopping cart to use. Buyers are not going to see it or anything, and it's not something you would regularly share or have to use all that often. Once you set it in your code, you don't really mess with it again unless you need to set up the API credentials again.

Country Restrictions - How does Facebook determine a user's location when filtering gated content?

How is a location determined when showing restricted posts from a page's wall?
Here is the configuration option I am talking about (on a page's settings page)
My scenario is: I have a sever based in the UK which is using the user's auth token to show posts which are gated. Obviously I would like US based users to see these posts.
Will it take into account
My server's IP address?
The location the user has specified on their profile?
The IP the user used to sign up with? --- or something else?
To clarify I have set my location in my profile to be a place in the US, but don't see the posts (when calling the API, or when just viewing the page)
Also, when I log into my UK based account from the US, I still don't see the posts (from API, or from just viewing the page)
Oddly enough, when logged in from the US server, Facebook asks me to validate my account and suggests a UK based mobile number (+44) - could be related to the fact I signed up from the UK?
I have no way of creating an account that is US based because I don't have a US based mobile I can verify with.
I've been doing some testing on this.
I'm in Spain but wanted to see a page I'd restricted to UK only.
I set my current location and home town to London: Did not work
I verified my UK phone (roaming): Did not work
Used a VPN service (hidemyass) to give me a UK IP: Did not work
With the account set like that, no other changes. I called a mate and got him to login to the account in the UK and the page became visible.
So can assume that settings of the account do not affect, and that FB are detecting VPN based traffic - maybe from database list of datacentre IP addresses.
And that it uses a (non-datacentre) IP address detection to determine if you are in this country. Also follows that if you travel abroad you won't be able to see content even if you do "live" in that country. I'm guess if you 'like' the page, then travel you would still be able to see it.

Facebook test users and auth

I have a project where I am using Selenium to test the Facebook auth. I created a Facebook app, created a test user inside this app and created some tests using Facebook login. Until now, it was working. But during the last two weeks something changed in Facebook and my tests are failing. It is due to interface changes in permissions dialog (I am targeting the button by his id). The second problem is that I don't get the email address from Facebook test user but a proxy email which is longer than 75 characters (my db field length is hardcoded in framework I am using).
If I log in as a regular user, it is working correctly and I get this permission box:
But when I log in as the test user I created (via 'switch to' in app's developer roles), I get this box:
I tested it ~2 weeks ago and this was yet working. Today it is changed. So my questions:
How to get back the old permissions box for test users?
How can I get the real email address and not the proxy?
Thanks!
I experienced the same problem with the Auth Dialog. I tried it with some old and new apps with various settings including March/Apr. 2013 Breaking Changes enabled/disabled, but it didn't help.
However, I guess I can help you with the email problem. When you login as a test user and go to account settings page, you will see the test user's primary email addres. By default this should be a really long one like the image I attached.
Facebook Platform returns this primary email address. If you pass the Auth Dialog with your test user account and see the privacy setting page, you will find the default primary email address is shared with the app. You have to provide a new email address for the test user and set the new one as primary email address via account setting page.
Why is the Login Dialog different with a test user?
With your test user, you can see the future of login dialogs. In fact, this isn't "not working" but this is an update which was unveiled on December 2012. Let me quote:
Our Login dialogs have undergone a redesign to make it easier to
understand permissions that apps request. We've simplified
presentation and have also updated our language for greater clarity.
“Basic info” has been renamed to “public profile and friend list,” to
reflect what what is being shared. Apps accessing your public profile
get your name, profile picture, age range, gender, language, country
and other public information.
Source: Providing People Greater Clarity and Control, developers.facebook.com/blog
The reason why you don't meet this update with a regular user, is that Facebook doesn't use to update everyone at the same time. They partially launch updates depending on the country, the type of account or some other parameters I ignore.
Example of a partial update (unified_message FQL table) dedicated to developer accounts:
We are providing early access to this API for registered developer
accounts only until the new messaging system is broadly available. You
should use the message table for production applications at the
current time.
In our case, we now know that test users can access to the update, but it is also said:
We have already launched many of these improvements as part of our
iOS6 integration and are now rolling them out more broadly.
About proxy emails
In fact, proxy emails are a way for any users to keep their real email anonymous. You have to consider proxy emails.
When joining an app, the user can choose between a real email and a proxy email:
Other thing you need to expect are users who didn't validate their account when connecting to your app, a case which is possible as described here and here.
Then, why do test users give back a proxy email? Because test users (being bots and having fake emails) didn't validate their emails.
You see that in at least 3 cases (and finally, test users are a good example), you need to handle these proxy emails. They are incidentally or accidentally met by developers and they can't be neglected. For your case, you can still try to disallow tests users who have a proxy email from accessing your app. But you should accept them and shouldn't force them to share their original e-mail addresses. A better solution is that you validate the test users emails:
Connect to the test user account that gives a proxy email
Add an email address (password needed here),
Go to the email mailbox and click on the validation link,
Set the new email address as primary,
The test user should now give his original email and not a proxy anymore!

Facebook Graph API returning numbers instead of email addresses

I'm using Facebook Connect along with the Facebook Graph API to fetch user's email addresses when they sign up to my site. This works perfectly over 99% of the time but sometimes when I query the Graph API for a user's data after they have given my site permission, including the email permission, Facebook returns a large number (eg. 14036774009) as the person's email address.
So far, the numbers are always different and are always 11 digits long and all the other user data from the Graph API is valid. I've never been able to replicate this problem with a Facebook account that I control.
In some ways, the large number reminds me of the random proxy email addresses that Facebook generates for people who opt to give 3rd party apps a forwarding address instead of their main address (the proxy addresses look something like this: apps+148742679521093.617890126.8a2b26037e1ccd06bb81aaec5925f4c7#proxymail.facebook.com)
Can anyone explain this behavior or a way to fix it (and always get valid email addresses)?
It's a bug. Has already been reported to Facebook:
https://developers.facebook.com/bugs/298946933534016
It seems to be happening even when using the graph explorer - https://developers.facebook.com/tools/explorer, but only for some users. In my case about 0.2% of the time.
So until it is fixed you have 2 options:
If Facebook gives you a bad email value, ask the user for his/her email manually.
Save the long lived access token and try again periodically to see if you get the correct email back.
Are you still using the old auth dialog somehow?
The ability to provide a proxy email address is only in the old auth dialog
This happens for people who sign up to Facebook with their mobile phone number and the number returned is just that.
There is no option to get at the users' email address because he may not have given it to Facebook yet.