what is the correct way to get the conversation/messages on a Facebook page?
I am using:
https://graph.facebook.com/v13.0/{page-id}/conversations which returns
{
"data": [
{
"id": "t_XXXX",
"updated_time": "2022-05-25T12:37:30+0000"
}
}
Now trying to get the messages with https://graph.facebook.com/v13.0/{page-id}/conversations/t_XXXX/messages throws
{
"error": {
"message": "Unknown path components: /messages",
"type": "OAuthException",
"code": 2500,
"fbtrace_id": "asdf"
}
}
The new Google People APIs
batchCreateContacts - https://developers.google.com/people/api/rest/v1/people/batchCreateContacts and batchUpdateContacts - https://developers.google.com/people/api/rest/v1/people/batchUpdateContacts gives following response on making a request.
{
"error": {
"code": 500,
"message": "Internal error encountered.",
"status": "INTERNAL"
}
}
updateContact - https://developers.google.com/people/api/rest/v1/people/updateContact gives the following response when CalendarUrl is sent in the update contact request
{
"error": {
"code": 400,
"message": "Invalid updatePersonFields mask path: \"calendar_urls\". Valid paths are documented at https://developers.google.com/people/api/rest/v1/people/updateContact.",
"status": "INVALID_ARGUMENT"
}
}
Can someone help with these issues.
QuickBooksOnline API - Customer Balance is not working when other non reports API working with same access token
Request
https://sandbox-quickbooks.api.intuit.com/v3/company/123146076363264/reports/CustomerBalance?customer=1
Response
{
"Fault": {
"Error": [
{
"Message": "Permission Denied Error",
"Detail": "Permission Denied Error : You do not have the access rights to use this feature.",
"code": "5020",
"element": "ReportName"
}
],
"type": "ValidationFault"
},
"time": "2019-06-05T05:30:57.879-07:00"
}
I'm unable to get CPM data from my Youtube reports:
I'm getting:
{
"error": {
"code": 403,
"message": "Forbidden",
"errors": [
{
"message": "Forbidden",
"domain": "global",
"reason": "forbidden"
}
]
}
}
I don't even know where to begin to debug this, and I haven't found anything online.
I'm just trying to curl the endpoint, mirroring this: HERE
Notice that once you finish the oauth process, User will see
"You do not have permission to execute this method." and the 403
Also, Notice if you remove 'CPM' from the list of metrics, this will work.
Example:
curl --header "Authorization: Bearer _____access_token____" -e "https://developers.google.com" https://content-youtubeanalytics.googleapis.com/v2/reports\?endDate\=2014-06-30\&ids\=channel%3D%3DMINE\&metrics\=cpm\&startDate\=2014-05-01\&key\=_____api_key____
I'm getting the refresh token via:
<script>
var auth2;
var SCOPE = ['https://www.googleapis.com/auth/adwords',
'https://www.googleapis.com/auth/yt-analytics.readonly',
'https://www.googleapis.com/auth/youtube',
'https://www.googleapis.com/auth/yt-analytics-monetary.readonly',
'https://www.googleapis.com/auth/youtubepartner-channel-audit',
'https://www.googleapis.com/auth/youtubepartner',
'https://www.googleapis.com/auth/youtube.readonly',
] ;
function initClient() {
auth2 = gapi.auth2.init({
'clientId': 'my-client-id',
'scope': SCOPE.join(' '),
'prompt': 'consent',
})
}
function handleClientLoad() {
gapi.load('auth2', initClient);
}
</script>
<script async defer src="https://apis.google.com/js/api.js"
onload="this.onload=function(){};handleClientLoad()"
onreadystatechange="if (this.readyState === 'complete') this.onload()">
</script>
the access token I'm using is from the refresh token via:
https://www.googleapis.com/oauth2/v4/token?client_id={my_client_id}&client_secret={my_client_secret}&refresh_token={my_refresh_token}&grant_type=refresh_token
and I'm getting:
{
"access_token": "ya29.GlvyBZVPpC.....",
"token_type": "Bearer",
"expires_in": 3600,
"scope": "https://www.googleapis.com/auth/youtubepartner https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/adwords https://www.googleapis.com/auth/youtube https://www.googleapis.com/auth/plus.me https://www.googleapis.com/auth/youtube.readonly https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/yt-analytics.readonly https://www.googleapis.com/auth/yt-analytics-monetary.readonly",
"id_token": "eyJhbGciOiJSUz...."
}
I don't believe it's an issue with my scopes as I am not getting a 403 like:
{
"error": {
"code": 403,
"message": "Request had insufficient authentication scopes.",
"errors": [
{
"message": "Request had insufficient authentication scopes.",
"domain": "global",
"reason": "forbidden"
}
],
"status": "PERMISSION_DENIED"
}
}
According to the facebook documentation here Deleting a Lead Form
this is how you do it:
Send a delete http request to https://graph.facebook.com/v2.10/formId?access_token=the_access_token.
However I get the error below when I try the above:
{
"error": {
"message": "(#210) This call requires a Page access token.",
"type": "OAuthException",
"code": 210,
"fbtrace_id": "ABC123/xyz"
}
}
When I use a Page access token (as suggest by the error response) this is what I get:
{
"error": {
"message": "(#3) Subject must be on whitelist",
"type": "OAuthException",
"code": 3,
"fbtrace_id": "IJK123/uvw"
}
}
If it matters the accessToken initially used is the same token used to create the leadform.
How can I get this to work? What am I missing?