Problem with offline conversions and CM360 API

63 views
Skip to first unread message

Polina Familnova

unread,
Jun 6, 2024, 9:37:50 AMJun 6
to Google's Campaign Manager 360 API Forum
Hi Team,

I would appreciate your help in troubleshooting the below issue.

We encountered a problem when downloading/uploading offline conversions via the CM360 API.

The system gives the following error:
{
  "error": {
    "code": 403,
    "message": "The caller does not have permission",
    "errors": [
      {
        "message": "The caller does not have permission",
        "domain": "global",
        "reason": "forbidden"
      }
    ],
    "status": "PERMISSION_DENIED"
  }
}
```

Conversions are sent via a Batch request:
$batchInsertRequest = new ConversionsBatchInsertRequest();
$batchInsertRequest->setConversions([ $conversion ]);
$response = $gcmService->conversions->batchinsert($userProfileId, $batchInsertRequest);

We checked that the partner and the account from which the request was made have the “Enable account for API access” setting enabled.

Could you help uw resolve the problem? What else could be the problem? What other accesses and settings are worth checking?

Thanks,
Polina

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 6, 2024, 2:03:09 PMJun 6
to p.fam...@data-stories.tech, google-doubleclick-...@googlegroups.com
Hi,

Thank you for reaching out to the CM360 API support team.

Can you confirm which email address you are using while creating credentials in the GCP and authenticating with the DCM Account. Also, please share the following details to investigate further:
  • DCM Account ID.
  • User profile ID or the user email / service account email used for authenticating the API query.
  • Error screenshots (if any).
  • Complete API response showing the issue/error

 
This message is in relation to case "ref:!00D1U01174p.!5004Q02tJEbo:ref" (ADR-00238731)

Thanks,
 
Google Logo DCM API Team

 

Polina Familnova

unread,
Jun 14, 2024, 4:07:11 AMJun 14
to Google's Campaign Manager 360 API Forum
Hi, 

DCM Account: 2210785
User profile ID: 9408147

We use PHP language and Google\Client libraries for authorization and Google\Service\Dfareporting with scope [DFAREPORTING, DDMCONVERSIONS] for sending conversions.

The conversion generation code looks like this:
```
$conversion = new Conversion();
$conversion->setFloodlightActivityId($floodlightActivityId);
$conversion->setFloodlightConfigurationId($floodlightConfigurationId);
$conversion->setTimestampMicros($timestampMicros);
$conversion->setOrdinal($ordinal);
$conversion->setMatchId($vbbHash);

```
 

Conversions are sent via a Batch request:
```
$batchInsertRequest = new ConversionsBatchInsertRequest();
$batchInsertRequest->setConversions([ $conversion ]);
$response = $gcmService->conversions->batchinsert($userProfileId, $batchInsertRequest);
```

When I request I receive the following response:
```

{
  "error": {
    "code": 403,
    "message": "The caller does not have permission",
    "errors": [
      {
        "message": "The caller does not have permission",
        "domain": "global",
        "reason": "forbidden"
      }
    ],
    "status": "PERMISSION_DENIED"
  }
}
```

четверг, 6 июня 2024 г. в 21:03:09 UTC+3, DCM API (DoubleClick Campaign Mgr):

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 14, 2024, 8:11:58 AMJun 14
to p.fam...@data-stories.tech, google-doubleclick-...@googlegroups.com
Hi,

I can confirm that user profile 9408147 has a user role as "1_Advanced Agency Admin" which has access to insert the offline conversions. You should be able to execute the conversions.batchinsert method without any issue.

The "1_Advanced Agency Admin" user role has received the source permissions from the "Advanced Agency Admin" user role and also it has additional permissions which include inserting the offline conversions. You should not be receiving the permission issue while using the conversions.batchinsert method. Kindly confirm whether you are using the user profile 9408147 (campaign-man...@pc-api-8602211479360775467-185.iam.gserviceaccount.com)
while authenticating with the DCM API so that we can investigate further. 

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 14, 2024, 11:50:23 AMJun 14
to p.fam...@data-stories.tech, google-doubleclick-...@googlegroups.com
Hi,

I have raised your concern with the rest of our team and one of my teammates will get back to you once we have an update.

Polina Familnova

unread,
Jun 17, 2024, 5:03:43 AMJun 17
to DCM API (DoubleClick Campaign Mgr), google-doubleclick-...@googlegroups.com
Hi, 

Yes, this is the main problem - we checked all accesses and in theory the error should not occur. We use this profile 9408147 to work with API


Полина Фамильнова
Старший менеджер AdOps,
 Олформанс

p.fam...@data-stories.tech



пт, 14 июн. 2024 г. в 15:11, DCM API (DoubleClick Campaign Mgr) <dcm...@forumsupport.google>:

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 18, 2024, 3:37:53 AMJun 18
to google-doubleclick-...@googlegroups.com, p.fam...@data-stories.tech
Hello,

Thank you for your patience.

Upon checking with our team, I would like to inform you that you are incorrectly using 2210785 as the profile ID. Can you please check which user email / service account is used while authenticating the API query. 

Polina Familnova

unread,
Jun 18, 2024, 8:23:10 AMJun 18
to DCM API (DoubleClick Campaign Mgr), google-doubleclick-...@googlegroups.com
Hello, 

I didn't understand your question a bit((
I wrote above that 2210785 is DCM Account, and User profile ID which is used for authenticating the API query - 9408147

Polina Familnova
Senior AdOps Manager,
 Allformance

p.fam...@data-stories.tech



вт, 18 июн. 2024 г. в 10:37, DCM API (DoubleClick Campaign Mgr) <dcm...@forumsupport.google>:

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 18, 2024, 1:16:27 PMJun 18
to p.fam...@data-stories.tech, google-doubleclick-...@googlegroups.com
Hi,

Upon checking the logs, it is clear that you are incorrectly using 2210785 as the profile ID. Hope this helps.

Polina Familnova

unread,
Jun 19, 2024, 3:49:29 AMJun 19
to DCM API (DoubleClick Campaign Mgr), google-doubleclick-...@googlegroups.com
Hi, 

Could you explain what this means? How to use it correctly? It is not yet very clear what exactly the error is and how to fix it. 


Polina Familnova
Senior AdOps Manager,
 Allformance

p.fam...@data-stories.tech



вт, 18 июн. 2024 г. в 20:16, DCM API (DoubleClick Campaign Mgr) <dcm...@forumsupport.google>:

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 19, 2024, 8:59:36 AMJun 19
to p.fam...@data-stories.tech, google-doubleclick-...@googlegroups.com
Hello,

Thank you for getting back to us.

After checking with our team, it was informed that you are using the 2210785 as a user profile where it should be DCM Account ID and User profile ID is something like 9408147. Can you please modify your request and try to execute again with the 2210785 as DCM Account ID.

Further, if you face the same issue then kindly share the latest JSON request and response logs to investigate further.

Polina Familnova

unread,
Jun 19, 2024, 10:47:40 AMJun 19
to DCM API (DoubleClick Campaign Mgr), google-doubleclick-...@googlegroups.com
Hi,

Honestly, I don’t understand((
I sent above a sample script and information on which IDs we use for what, namely:

DCM Account: 2210785
User profile ID: 9408147

That is, we use 9408147 as a user profile. Therefore, I don’t understand why you write that we don’t use it.
Can you clarify at what stage we are using ID incorrectly in requests?


Polina Familnova
Senior AdOps Manager,
 Allformance

p.fam...@data-stories.tech



ср, 19 июн. 2024 г. в 15:59, DCM API (DoubleClick Campaign Mgr) <dcm...@forumsupport.google>:

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 19, 2024, 2:11:38 PMJun 19
to p.fam...@data-stories.tech, google-doubleclick-...@googlegroups.com
Hi,

I would suggest to execute your query again with the 2210785 as DCM Account ID and please share JSON request and response logs if you get any error. Hope this helps. 

Yashwant Kapgate

unread,
Jun 25, 2024, 8:23:37 AM (11 days ago) Jun 25
to Google's Campaign Manager 360 API Forum
Can we add creative while creating new campaign using API added image for refAPI.png

DCM API (DoubleClick Campaign Mgr)

unread,
Jun 25, 2024, 1:33:49 PM (11 days ago) Jun 25
to google-doubleclick-...@googlegroups.com
Hi,

I would suggest you to refer to this list of creative types that are supported on DCM. You may utilize our Creatives and upload your creative assets using CreativeAssets. Hope this helps.
Reply all
Reply to author
Forward
0 new messages