RE: The endpoint and JSON data when making a POST request using curl

2019-06-04 Thread Google Ads API Forum Advisor Prod
Hello,

Glad you were able to create the campaign. The end point for Google Ads API is 
googleads.googleapis.com and the code sample for CURL operations is not yet 
available. I will update my team regarding your interest. Also, we see most of 
the advertisers using the client libraries that are provided in various 
languages which has more example and client library support is also available 
via GitHub.

I have attached my result log to create campaigns using Java client library for 
your reference.

Regarding,
Sai Teja, Google Ads API Team
ref:_00D1U1174p._5001UBe6ec:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/-5UdT0PSKYLI009tBTGzcQSI2nMHjyuGc1kA%40sfdc.net.
2019-06-04 10:57:48,572 INFO  [Gax-3] logging.RequestLogger 
(RequestLogger.java:157) - SUCCESS REQUEST SUMMARY. Method: 
google.ads.googleads.v1.services.CampaignBudgetService/MutateCampaignBudgets, 
Endpoint: googleads.googleapis.com:443, CustomerID: 8760527478, RequestID: 
UI1gmg0yXhJtvvlWZhX29Q, ResponseCode: OK, Fault: null.
2019-06-04 10:57:48,653 DEBUG [Gax-3] logging.RequestLogger 
(RequestLogger.java:161) - SUCCESS REQUEST DETAIL.
Request
---
MethodName: 
google.ads.googleads.v1.services.CampaignBudgetService/MutateCampaignBudgets
Endpoint: googleads.googleapis.com:443
Headers: {developer-token=REDACTED, login-customer-id=1898404517, 
x-goog-api-client=gl-java/1.8.0_181-google-v7 gapic/ gax/1.35.0 grpc/1.16.1}
Body: customer_id: "8760527478"
operations {
  create {
name {
  value: "Interplanetary Cruise Budget #1559660266658"
}
amount_micros {
  value: 50
}
delivery_method: STANDARD
  }
}


Response

Headers: 
Metadata(content-disposition=attachment,content-type=application/grpc,request-id=UI1gmg0yXhJtvvlWZhX29Q,x-google-esf-cloud-client-params=client_project_number:
 272094737371 backend_service_name: "googleads.googleapis.com" 
backend_fully_qualified_method: 
"google.ads.googleads.v1.services.CampaignBudgetService.MutateCampaignBudgets" 
,x-google-session-info=CLG4_INhGgQYECgLOmsSGGdvb2dsZWFkcy5nb29nbGVhcGlzLmNvbRjb5_DQ9QciSDI3MjA5NDczNzM3MS1sbHMwcW9pZHFwbHA0N2dqNmp2Y3JrNWljdGtiYWlpZy5hcHBzLmdvb2dsZXVzZXJjb250ZW50LmNvbUoPOg0xL2FVSTdsQWFPUWF-,date=Tue,
 04 Jun 2019 14:57:48 
GMT,x-google-gfe-request-trace=aclgan3-v6:443,qjia3:9850,/bns/ym/borg/ym/bns/adwords-simply/aw-webapi-esfproxy-prod.server/81,qjia3:9850,aclgan3-v6:443,x-google-gslb-service=adwords-frontend-webapi-esfproxy,x-google-backends=[2002:a17:509:3591::]:4277,/bns/ym/borg/ym/bns/adwords-simply/aw-webapi-esfproxy-prod.server/81,qjia3:9850,/bns/qj/borg/qj/bns/traffic-prod/shared-layer2-gfe/16,aclgan3-v6:443,x-google-dos-service-trace=main:adwords-frontend-webapi-esfproxy,main:shared-layer2-gfe,x-google-service=adwords-frontend-webapi-esfproxy,shared-layer2-grpc-aggregate,x-google-gfe-response-code-details-trace=response_code_set_by_backend,response_code_set_by_backend,x-google-gfe-response-body-transformations=chunked,chunked,x-google-shellfish-status=CA0gBEBG,alt-svc=quic=":443";
 ma=2592000; 
v="46,44,43,39",x-google-gfe-service-trace=adwords-frontend-webapi-esfproxy,shared-layer2-grpc-aggregate)
Body: results {
  resource_name: "customers/8760527478/campaignBudgets/2068944418"
}

Failure message: null
Status: Status{code=OK, description=null, cause=null}.
Added budget: customers/8760527478/campaignBudgets/2068944418
2019-06-04 10:57:49,269 INFO  [Gax-7] logging.RequestLogger 
(RequestLogger.java:157) - SUCCESS REQUEST SUMMARY. Method: 
google.ads.googleads.v1.services.CampaignService/MutateCampaigns, Endpoint: 
googleads.googleapis.com:443, CustomerID: 8760527478, RequestID: 
h2ZeIYqRKCM4dbmdOPXAgA, ResponseCode: OK, Fault: null.
2019-06-04 10:57:49,330 DEBUG [Gax-7] logging.RequestLogger 
(RequestLogger.java:161) - SUCCESS REQUEST DETAIL.
Request
---
MethodName: google.ads.googleads.v1.services.CampaignService/MutateCampaigns
Endpoint: googleads.googleapis.com:443
Headers: {developer-token=REDACTED, login-customer-id=1898404517, 
x-goog-api-client=gl-java/1.8.0_181-google-v7 gapic/ gax/1.35.0 grpc/1.16.1}
Body: customer_id: "8760527478"
operations {
  create {

Re: The endpoint and JSON data when making a POST request using curl

2019-06-04 Thread f s
Thank you so much, Sai. I was able to create an empty campaign. I've put 
the successful code below.

const rp = require('request-promise-native');


const customer_id = 1234567890;
const developerToken = '***';
const loginCustomerId = 9876543210;
const accessToken = '***';


const headers = {
 'developer-token': developerToken,
 'login-customer-id': loginCustomerId,
 'Accept-Charset': 'utf-8',
 'Content-Type': 'application/json',
 'Authorization': 'Bearer ' + accessToken
};


// create budget
const createBudget = async () => {
 try {
 const url = 
`https://googleads.googleapis.com/v1/customers/${customer_id}/campaignBudgets:mutate`
;


 const operations = {
 'operations': [
 {
 'create': {
 'name': 'new budget test 1',
 'amount_micros': 1,
 'status': 'ENABLED',
 'delivery_method': 'STANDARD',
 'type': 'STANDARD'
 }
 }
 ]
 };


 const options = {
 method: 'POST',
 headers: headers,
 body: operations, // not data:
 json: true,
 resolveWithFullResponse: true
 };


 const res = await rp(url, options);
 return res.body.results[0].resourceName;
 } catch (err) { console.log(err.message); }
};


// create campaign
const createCampaign = async (budgetResource) => {
 try {
 const url = 
`https://googleads.googleapis.com/v1/customers/${customer_id}/campaigns:mutate`
;


 const operations = {
 'operations': [
 {
 'create': {
 'name': 'new campaign test 1',
 'advertising_channel_type': 'SEARCH',
 'status': 'PAUSED',
 'campaign_budget': budgetResource,
 'start_date': '20190701',
 'end_date': '20190801',
 'network_settings': {
 'target_google_search': true,
 'target_search_network': false,
 'target_content_network': false,
 'target_partner_search_network': false
 },
 'manual_cpc': {
 'enhanced_cpc_enabled': false
 }
 }
 }
 ]
 };


 const options = {
 method: 'POST',
 headers: headers,
 body: operations,
 json: true,
 resolveWithFullResponse: true
 };


 const res = await rp(url, options);
 return res.body.results[0].resourceName;
 } catch (err) { console.log(err.message); }
};


const main = async () => {
 try {
 const budgetResource = await createBudget();
 const campaignResource = await createCampaign(budgetResource);
 console.log(campaignResource);
 } catch (err) { console.log(err); }
}


main();

We are still waiting for the endpoint and json sample code via curl.

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/5f11915a-79fa-4fc4-b737-33cf9d4f3150%40googlegroups.com.


Re: The endpoint and JSON data when making a POST request using curl

2019-06-03 Thread f s
Thanks a lot, and I'm sorry, but I deleted the previous question for a 
reason.
Even if you have sample code, it's hard work...


2019年6月4日火曜日 4時57分27秒 UTC+9 adsapiforumadvisor:
>
> Hello,
>
> I see that your request needed below corrections:
>
>1. The campaign_budget should be a resource name instead of the actual 
>budget, that says you have to create the budget before even creating the 
>campaign and use that resource name here in the campaign creation. 
>2. There is no labels field in the dynamic_search_ads_setting setting. 
>Once the campaign is created using the resource name of the campaign you 
>can create labels for it using CampaignLabel 
>
> .
>  
>Corresponding code sample in Java can be found here 
>
> 
>. 
>
> I recommend you to use OAuth2 Playground 
> 
>  
> to make these CURL operations before you are trying with Node JS. OAuth 2 
> playground is logging the error messages clearly and using which I can see 
> the mistakes I am doing while making the API call. Also, print the complete 
> response object that you got via API that might give you more insights 
> regarding the error. Please let me know if you have any further questions.
>
> Regards,
> Sai Teja, Google Ads API Team
>
>
> ref:_00D1U1174p._5001UBe6ec:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/096a4be2-a377-4323-94b9-cd79e2c5be20%40googlegroups.com.


RE: The endpoint and JSON data when making a POST request using curl

2019-06-03 Thread Google Ads API Forum Advisor Prod
Hello,

I see that your request needed below corrections:

The campaign_budget should be a resource name instead of the actual budget, 
that says you have to create the budget before even creating the campaign and 
use that resource name here in the campaign creation.
There is no labels field in the dynamic_search_ads_setting setting. Once the 
campaign is created using the resource name of the campaign you can create 
labels for it using CampaignLabel. Corresponding code sample in Java can be 
found here.

I recommend you to use OAuth2 Playground to make these CURL operations before 
you are trying with Node JS. OAuth 2 playground is logging the error messages 
clearly and using which I can see the mistakes I am doing while making the API 
call. Also, print the complete response object that you got via API that might 
give you more insights regarding the error. Please let me know if you have any 
further questions.

Regards,
Sai Teja, Google Ads API Team
ref:_00D1U1174p._5001UBe6ec:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/QJZHL0PSJGRH00Bno7J3xlSx-zHdY4baUkAA%40sfdc.net.


Re: The endpoint and JSON data when making a POST request using curl

2019-06-02 Thread f s
I'll show you all of the code.
'use strict';

const rp = require('request-promise-native');

const accessToken = ''; // replace correctly
const customer_id = 1234567890; // replace correctly

const putCampaign = async () => {
 try {
 const url = 
`https://googleads.googleapis.com/v1/customers/${customer_id}/campaigns:mutate`
;

 const operations = {
 'operations': [
 {
 'create': {
 'name': 'new Campaign 1',
 'advertising_channel_type': 'SEARCH',
 'status': 'PAUSED',
 'campaign_budget': 10,
 'start_date': '20190601',
 'end_date': '20190701',
 'network_settings': {
 'target_google_search': true,
 'target_search_network': false,
 'target_content_network': false,
 'target_partner_search_network': false
 },
 'dynamic_search_ads_setting': {
 'domain_name': 'fo.com',
 'language_code': 'jp',
 'use_supplied_urls_only': true,
 'labels': ['test']
 },
 'bidding_strategy_type': 'ENHANCED_CPC',
 'payment_mode': 'CLICKS'
 }
 }
 ]
 };

 const options = {
 method: 'POST',
 headers: {
 'Content-Type': 'application/json',
 'Authorization': 'Bearer ' + accessToken,
 'developer-token': '', // replace correctly
 'login-customer-id': 6789012345, // replace correctly
 },
 data: operations,
 json: true,
 resolveWithFullResponse: true
 };

 const res = await rp(url, options);
 if (res.statusCode === 200) console.log(res.statusCode, res.statusMessage, 
res.body);
 } catch (err) { console.log(err.message); }
};

const main = async () => {
 try {
 await putCampaign();
 } catch (err) { console.log(err); }
}

main();

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/643cf21c-c506-4e07-9c48-78e8d2a38e74%40googlegroups.com.


Re: The endpoint and JSON data when making a POST request using curl

2019-06-02 Thread f s
I'll show you all of the code.
'use strict';

const rp = require('request-promise-native');

const accessToken = ''; // replace correctly
const customer_id = 1234567890; // replace correctly

const putCampaign = async () => {
 try {
 const url = 
`https://googleads.googleapis.com/v1/customers/${customer_id}/campaigns:mutate`
;

 const operations = {
 'operations': [
 {
 'create': {
 'name': 'new Campaign 1',
 'advertising_channel_type': 'SEARCH',
 'status': 'PAUSED',
 'campaign_budget': 10,
 'start_date': '20190601',
 'end_date': '20190701',
 'network_settings': {
 'target_google_search': true,
 'target_search_network': false,
 'target_content_network': false,
 'target_partner_search_network': false
 },
 'dynamic_search_ads_setting': {
 'domain_name': 'www.singlehand.jp',
 'language_code': 'jp',
 'use_supplied_urls_only': true,
 'labels': ['test']
 },
 'bidding_strategy_type': 'ENHANCED_CPC',
 'payment_mode': 'CLICKS'
 }
 }
 ]
 };

 const options = {
 method: 'POST',
 headers: {
 'Content-Type': 'application/json',
 'Authorization': 'Bearer ' + accessToken,
 'developer-token': '', // replace correctly
 'login-customer-id': 6789012345, // replace correctly
 },
 data: operations,
 json: true,
 resolveWithFullResponse: true
 };

 const res = await rp(url, options);
 if (res.statusCode === 200) console.log(res.statusCode, res.statusMessage, 
res.body);
 } catch (err) { console.log(err.message); }
};

const main = async () => {
 try {
 await putCampaign();
 } catch (err) { console.log(err); }
}

main();

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/7655cf31-b326-4c72-a968-b821cd184033%40googlegroups.com.


Re: The endpoint and JSON data when making a POST request using curl

2019-06-02 Thread f s
I'll show you all of the code via node.js.
'use strict';

const rp = require('request-promise-native');

const accessToken = ''; // replace correctly
const customer_id = 1234567890; // replace correctly

const putCampaign = async () => {
 try {
   const url = `https://googleads.googleapis.com/v1/customers/${customer_id}
/campaigns:mutate`;

const operations = {
 'operations': [
   {
 'create': {
   'name': 'new Campaign 1',
   'advertising_channel_type': 'SEARCH',
   'status': 'PAUSED',
   'campaign_budget': 10,
   'start_date': '20190601',
   'end_date': '20190701',
   'network_settings': {
 'target_google_search': true,
 'target_search_network': false,
 'target_content_network': false,
 'target_partner_search_network': false
   },
   'dynamic_search_ads_setting': {
 'domain_name': 'www.singlehand.jp',
 'language_code': 'jp',
 'use_supplied_urls_only': true,
 'labels': ['test']
   },
   'bidding_strategy_type': 'ENHANCED_CPC',
   'payment_mode': 'CLICKS'
 }
   }
 ]
   };

const options = {
 method: 'POST',
 headers: {
   'Content-Type': 'application/json',
   'Authorization': 'Bearer ' + accessToken,
   'developer-token': '', // replace correctly
   'login-customer-id': 6789012345 // replace correctly
 },
 data: operations,
 json: true,
 resolveWithFullResponse: true
   };

const res = await rp(url, options);
   if (res.statusCode === 200) console.log(res.statusCode, res.statusMessage
, res.body);
 } catch (err) { console.log(err.message); }
};

const main = async () => {
 try {
   await putCampaign();
 } catch (err) { console.log(err); }
}

main();

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/a94b6d4f-9cb2-43c5-a937-e62c67f16134%40googlegroups.com.


Re: The endpoint and JSON data when making a POST request using curl

2019-06-02 Thread f s
I read the indicated document and tried the following code.

const url = 
`https://googleads.googleapis.com/v1/customers/${customer_id}/campaignBudgets:mutate`
;
const operations = {
 'operations': [
 {
 'create': {
 'name': 'new Budgets 1',
 'amount_micros': 10,
 'total_amount_micros': 10,
 'status': 'PAUSED',
 'delivery_method': 'STANDARD',
 'period': 'DAILY',
 'type': 'STANDARD'
 }
 }
 ]
 };

const url = 
`https://googleads.googleapis.com/v1/customers/${customer_id}/campaigns:mutate`
;
const operations = {
 'operations': [
 {
 'create': {
 'name': 'new Campaign 1',
 'advertising_channel_type': 'SEARCH',
 'status': 'PAUSED',
 'campaign_budget': 10,
 'start_date': '20190601',
 'end_date': '20190701',
 'network_settings': {
 'target_google_search': true,
 'target_search_network': false,
 'target_content_network': false,
 'target_partner_search_network': false
 },
 'dynamic_search_ads_setting': {
 'domain_name': 'www.singlehand.jp',
 'language_code': 'jp',
 'use_supplied_urls_only': true,
 'labels': ['test']
 },
 'bidding_strategy_type': 'ENHANCED_CPC',
 'payment_mode': 'CLICKS'
 }
 }
 ]
 };

Both of the responses I received were "200 'OK' {}". Why isn't it an error? 
I don't know the cause because it's not an error code and error message. 
Could you show me the correct JSON? I can get access token via curl, but 
can I really use curl with other requests?

I don't know what to do...


2019年5月31日金曜日 5時03分36秒 UTC+9 adsapiforumadvisor:
>
> Hello,
>
> Looks like you are missing the required parameters while creating the 
> campaigns. The date should be MMDD format, the status should be 
> PAUSED, campaign_budget and bidding_strategy_type fields also required to 
> create the campaign 
> .
>  
> The complete example to create campaigns via CURL is not yet available. I 
> will let my team know regarding your concern and update you once I have 
> more information. Meanwhile you could refer the code samples here 
>  
> and follow the patterns.
>
> Regards,
> Sai Teja, Google Ads API team
>
> ref:_00D1U1174p._5001UBe6ec:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/3c062c52-16e9-4e6e-a1af-8bf7bdcab0d2%40googlegroups.com.


RE: The endpoint and JSON data when making a POST request using curl

2019-05-30 Thread Google Ads API Forum Advisor Prod
Hello,

Looks like you are missing the required parameters while creating the 
campaigns. The date should be MMDD format, the status should be PAUSED, 
campaign_budget and bidding_strategy_type fields also required to create the 
campaign. The complete example to create campaigns via CURL is not yet 
available. I will let my team know regarding your concern and update you once I 
have more information. Meanwhile you could refer the code samples here and 
follow the patterns.

Regards,
Sai Teja, Google Ads API team
ref:_00D1U1174p._5001UBe6ec:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/RK-cE0PSC2DN00Bhj98CFSTtyM6Zz9LhjuKQ%40sfdc.net.


Re: The endpoint and JSON data when making a POST request using curl

2019-05-29 Thread revarasi Sofa
service korsi sopa dibandung

Pada tanggal Kam, 30 Mei 2019 10.25, f s  menulis:

> I must use Node.js, curl and JSON, NOT library. So, I need endpoint and
> JSON data.
> I'm coding with a test account and I'd like to make one campaign. Could
> you give me some examples of endpoint and JSON data?
>
> for examples:
> const endpoint = '
> https://googleads.googleapis.com/v1/customers/${customer_id}/campaigns:mutate
> ';
> const operations = {
>   "operations": [
> {
>   "create": {
> "name": "new API campaign 1",
> "status": "PAUSE",
> "start_date": "01/06/2019",
> "end_date": "01/09/2019"
>   }
> }
>   ]
> };
> Is it correct? Response is returned statusCode: 200 AND body: {}, but no
> campaign.
>
>
> Can I use Bulk Mutates? Can you give me an example of endpoint and JSON in
> that case?
> https://developers.google.com/google-ads/api/docs/mutating/bulk-mutate
>
>
> I think, Google Ads API team should announce endpoint and JSON examples
> for curl as soon. The official guide is very unfriendly.
>
> Thanks.
>
> --
> --
> =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
> Also find us on our blog:
> https://googleadsdeveloper.blogspot.com/
> =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
>
> You received this message because you are subscribed to the Google
> Groups "AdWords API and Google Ads API Forum" group.
> To post to this group, send email to adwords-api@googlegroups.com
> To unsubscribe from this group, send email to
> adwords-api+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/adwords-api?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "AdWords API and Google Ads API Forum" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to adwords-api+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/adwords-api/64091221-f563-4793-a70b-8eb91e2fe827%40googlegroups.com
> 
> .
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/CAHekckAC6KhU-j6gX84Hsk6kHC_V2%3DtU9_x_n8AA9RnWYNKGrg%40mail.gmail.com.


The endpoint and JSON data when making a POST request using curl

2019-05-29 Thread f s
I must use Node.js, curl and JSON, NOT library. So, I need endpoint and 
JSON data.
I'm coding with a test account and I'd like to make one campaign. Could you 
give me some examples of endpoint and JSON data?

for examples:
const endpoint = 
'https://googleads.googleapis.com/v1/customers/${customer_id}/campaigns:mutate'
;
const operations = {
  "operations": [
{
  "create": {
"name": "new API campaign 1",
"status": "PAUSE",
"start_date": "01/06/2019",
"end_date": "01/09/2019"
  }
}
  ]
};
Is it correct? Response is returned statusCode: 200 AND body: {}, but no 
campaign.


Can I use Bulk Mutates? Can you give me an example of endpoint and JSON in 
that case?
https://developers.google.com/google-ads/api/docs/mutating/bulk-mutate


I think, Google Ads API team should announce endpoint and JSON examples for 
curl as soon. The official guide is very unfriendly.

Thanks.

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/64091221-f563-4793-a70b-8eb91e2fe827%40googlegroups.com.