मांग बढ़ाने में मदद करने वाले कैंपेन के ऐसेट बनाने और उन्हें कॉन्फ़िगर करने के बाद, विज्ञापन दिखाने के लिए उनके entityStatus फ़ील्ड को ENTITY_STATUS_ACTIVE पर अपडेट किया जा सकता है. विज्ञापन दिखाने के लिए, तीनों संसाधनों का चालू होना ज़रूरी है.
LineItem रिसॉर्स, "ड्राफ़्ट" EntityStatus के साथ बनाए जाने चाहिए. साथ ही, इन्हें बाद के अनुरोध में चालू किया जाना चाहिए.
AdGroup और AdGroupAd संसाधनों को "चालू है" EntityStatus के साथ बनाया जा सकता है. हालांकि, हमारा सुझाव है कि आप इन संसाधनों को "रुका हुआ है" स्टेटस के साथ बनाएं. इस तरह, बाद के अनुरोधों में संसाधनों को चालू करने से पहले, टारगेटिंग असाइन की जा सकती है और सही कॉन्फ़िगरेशन की पुष्टि की जा सकती है.
लाइन आइटम चालू करना
लाइन आइटम चालू करने का तरीका यहां बताया गया है:
Python
# The ID of the line item's parent advertiser. advertiser_id = advertiser-id # The ID of the Demand Gen line item. line_item_id = line-item-id line_item_obj = { "entityStatus": "ENTITY_STATUS_ACTIVE", } # Build and execute request. response = ( service.advertisers() .lineItems() .patch( advertiserId=advertiser_id, lineItemId=line_item_id, updateMask="entityStatus", body=line_item_obj, ) .execute() ) # Display the line item's new entity status print( f"Line item {response['name']} now has entity status " f"{response['entityStatus']}." )
विज्ञापन ग्रुप चालू करना
विज्ञापन ग्रुप को चालू करने का तरीका यहां बताया गया है:
Python
# The ID of the ad group's parent advertiser. advertiser_id = advertiser-id # The ID of the Demand Gen ad group. ad_group_id = ad-group-id ad_group_obj = { "entityStatus": "ENTITY_STATUS_ACTIVE", } # Build and execute request. response = ( service.advertisers() .adGroups() .patch( advertiserId=advertiser_id, adGroupId=ad_group_id, updateMask="entityStatus", body=ad_group_obj, ) .execute() ) # Display the ad group's new entity status print( f"Ad group {response['name']} now has entity status " f"{response['entityStatus']}." )
विज्ञापन चालू करना
विज्ञापन चालू करने का तरीका यहां बताया गया है:
Python
# The ID of the ad's parent advertiser. advertiser_id = advertiser-id # The ID of the Demand Gen ad. ad_id = ad-group-ad-id ad_obj = { "entityStatus": "ENTITY_STATUS_ACTIVE", } # Build and execute request. response = ( service.advertisers() .adGroupAds() .patch( advertiserId=advertiser_id, adGroupAdId=ad_id, updateMask="entityStatus", body=ad_obj, ) .execute() ) # Display the ad's new entity status print( f"Ad {response['name']} now has entity status " f"{response['entityStatus']}." )